diff options
author | codeworkx <daniel.hillenbrand@codeworkx.de> | 2012-06-02 13:09:29 +0200 |
---|---|---|
committer | codeworkx <daniel.hillenbrand@codeworkx.de> | 2012-06-02 13:09:29 +0200 |
commit | c6da2cfeb05178a11c6d062a06f8078150ee492f (patch) | |
tree | f3b4021d252c52d6463a9b3c1bb7245e399b009c /include/crypto/compress.h | |
parent | c6d7c4dbff353eac7919342ae6b3299a378160a6 (diff) | |
download | kernel_samsung_smdk4412-c6da2cfeb05178a11c6d062a06f8078150ee492f.zip kernel_samsung_smdk4412-c6da2cfeb05178a11c6d062a06f8078150ee492f.tar.gz kernel_samsung_smdk4412-c6da2cfeb05178a11c6d062a06f8078150ee492f.tar.bz2 |
samsung update 1
Diffstat (limited to 'include/crypto/compress.h')
-rw-r--r-- | include/crypto/compress.h | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/include/crypto/compress.h b/include/crypto/compress.h index 86163ef..607ba7d 100644 --- a/include/crypto/compress.h +++ b/include/crypto/compress.h @@ -99,46 +99,86 @@ static inline struct pcomp_alg *crypto_pcomp_alg(struct crypto_pcomp *tfm) static inline int crypto_compress_setup(struct crypto_pcomp *tfm, void *params, unsigned int len) { +#ifdef CONFIG_CRYPTO_FIPS + if (unlikely(in_fips_err())) + return -EACCES; +#endif + return crypto_pcomp_alg(tfm)->compress_setup(tfm, params, len); } static inline int crypto_compress_init(struct crypto_pcomp *tfm) { +#ifdef CONFIG_CRYPTO_FIPS + if (unlikely(in_fips_err())) + return -EACCES; +#endif + return crypto_pcomp_alg(tfm)->compress_init(tfm); } static inline int crypto_compress_update(struct crypto_pcomp *tfm, struct comp_request *req) { +#ifdef CONFIG_CRYPTO_FIPS + if (unlikely(in_fips_err())) + return -EACCES; +#endif + return crypto_pcomp_alg(tfm)->compress_update(tfm, req); } static inline int crypto_compress_final(struct crypto_pcomp *tfm, struct comp_request *req) { +#ifdef CONFIG_CRYPTO_FIPS + if (unlikely(in_fips_err())) + return -EACCES; +#endif + return crypto_pcomp_alg(tfm)->compress_final(tfm, req); } static inline int crypto_decompress_setup(struct crypto_pcomp *tfm, void *params, unsigned int len) { +#ifdef CONFIG_CRYPTO_FIPS + if (unlikely(in_fips_err())) + return -EACCES; +#endif + return crypto_pcomp_alg(tfm)->decompress_setup(tfm, params, len); } static inline int crypto_decompress_init(struct crypto_pcomp *tfm) { +#ifdef CONFIG_CRYPTO_FIPS + if (unlikely(in_fips_err())) + return -EACCES; +#endif + return crypto_pcomp_alg(tfm)->decompress_init(tfm); } static inline int crypto_decompress_update(struct crypto_pcomp *tfm, struct comp_request *req) { +#ifdef CONFIG_CRYPTO_FIPS + if (unlikely(in_fips_err())) + return -EACCES; +#endif + return crypto_pcomp_alg(tfm)->decompress_update(tfm, req); } static inline int crypto_decompress_final(struct crypto_pcomp *tfm, struct comp_request *req) { +#ifdef CONFIG_CRYPTO_FIPS + if (unlikely(in_fips_err())) + return -EACCES; +#endif + return crypto_pcomp_alg(tfm)->decompress_final(tfm, req); } |