From: Richard Hartmann Date: Tue, 16 Feb 2010 12:27:20 +0000 (+0800) Subject: crypto: authenc - Fix checkpatch errors X-Git-Tag: v2.6.34-rc1~286^2~12 X-Git-Url: https://git.karo-electronics.de/?a=commitdiff_plain;h=f3542e6d7b246e88b038e608358606ddd1f09870;p=karo-tx-linux.git crypto: authenc - Fix checkpatch errors Signed-off-by: Richard Hartmann Signed-off-by: Herbert Xu --- diff --git a/crypto/authenc.c b/crypto/authenc.c index 4d6f49a5daeb..18870906ea06 100644 --- a/crypto/authenc.c +++ b/crypto/authenc.c @@ -194,7 +194,7 @@ static void authenc_verify_ahash_update_done(struct crypto_async_request *areq, scatterwalk_map_and_copy(ihash, areq_ctx->sg, areq_ctx->cryptlen, authsize, 0); - err = memcmp(ihash, ahreq->result, authsize) ? -EBADMSG: 0; + err = memcmp(ihash, ahreq->result, authsize) ? -EBADMSG : 0; if (err) goto out; @@ -231,7 +231,7 @@ static void authenc_verify_ahash_done(struct crypto_async_request *areq, scatterwalk_map_and_copy(ihash, areq_ctx->sg, areq_ctx->cryptlen, authsize, 0); - err = memcmp(ihash, ahreq->result, authsize) ? -EBADMSG: 0; + err = memcmp(ihash, ahreq->result, authsize) ? -EBADMSG : 0; if (err) goto out; @@ -464,7 +464,7 @@ static int crypto_authenc_verify(struct aead_request *req, ihash = ohash + authsize; scatterwalk_map_and_copy(ihash, areq_ctx->sg, areq_ctx->cryptlen, authsize, 0); - return memcmp(ihash, ohash, authsize) ? -EBADMSG: 0; + return memcmp(ihash, ohash, authsize) ? -EBADMSG : 0; } static int crypto_authenc_iverify(struct aead_request *req, u8 *iv, @@ -557,11 +557,11 @@ static int crypto_authenc_init_tfm(struct crypto_tfm *tfm) ctx->auth = auth; ctx->enc = enc; - + tfm->crt_aead.reqsize = max_t(unsigned int, crypto_ahash_reqsize(auth) + ctx->reqoff + sizeof(struct authenc_request_ctx) + - sizeof(struct ahash_request), + sizeof(struct ahash_request), sizeof(struct skcipher_givcrypt_request) + crypto_ablkcipher_reqsize(enc) + crypto_ablkcipher_ivsize(enc));