diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-10-08 06:44:48 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-10-08 06:44:48 -0400 |
commit | 87d7bcee4f5973a593b0d50134364cfe5652ff33 (patch) | |
tree | 677125896b64de2f5acfa204955442f58e74cfa9 /crypto/ahash.c | |
parent | 0223f9aaef94a09ffc0b6abcba732e62a483b88c (diff) | |
parent | be34c4ef693ff5c10f55606dbd656ddf0b4a8340 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
Pull crypto update from Herbert Xu:
- add multibuffer infrastructure (single_task_running scheduler helper,
OKed by Peter on lkml.
- add SHA1 multibuffer implementation for AVX2.
- reenable "by8" AVX CTR optimisation after fixing counter overflow.
- add APM X-Gene SoC RNG support.
- SHA256/SHA512 now handles unaligned input correctly.
- set lz4 decompressed length correctly.
- fix algif socket buffer allocation failure for 64K page machines.
- misc fixes
* git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6: (47 commits)
crypto: sha - Handle unaligned input data in generic sha256 and sha512.
Revert "crypto: aesni - disable "by8" AVX CTR optimization"
crypto: aesni - remove unused defines in "by8" variant
crypto: aesni - fix counter overflow handling in "by8" variant
hwrng: printk replacement
crypto: qat - Removed unneeded partial state
crypto: qat - Fix typo in name of tasklet_struct
crypto: caam - Dynamic allocation of addresses for various memory blocks in CAAM.
crypto: mcryptd - Fix typos in CRYPTO_MCRYPTD description
crypto: algif - avoid excessive use of socket buffer in skcipher
arm64: dts: add random number generator dts node to APM X-Gene platform.
Documentation: rng: Add X-Gene SoC RNG driver documentation
hwrng: xgene - add support for APM X-Gene SoC RNG support
crypto: mv_cesa - Add missing #define
crypto: testmgr - add test for lz4 and lz4hc
crypto: lz4,lz4hc - fix decompression
crypto: qat - Use pci_enable_msix_exact() instead of pci_enable_msix()
crypto: drbg - fix maximum value checks on 32 bit systems
crypto: drbg - fix sparse warning for cpu_to_be[32|64]
crypto: sha-mb - sha1_mb_alg_state can be static
...
Diffstat (limited to 'crypto/ahash.c')
-rw-r--r-- | crypto/ahash.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/crypto/ahash.c b/crypto/ahash.c index f2a5d8f656ff..f6a36a52d738 100644 --- a/crypto/ahash.c +++ b/crypto/ahash.c | |||
@@ -131,8 +131,10 @@ int crypto_hash_walk_first(struct ahash_request *req, | |||
131 | { | 131 | { |
132 | walk->total = req->nbytes; | 132 | walk->total = req->nbytes; |
133 | 133 | ||
134 | if (!walk->total) | 134 | if (!walk->total) { |
135 | walk->entrylen = 0; | ||
135 | return 0; | 136 | return 0; |
137 | } | ||
136 | 138 | ||
137 | walk->alignmask = crypto_ahash_alignmask(crypto_ahash_reqtfm(req)); | 139 | walk->alignmask = crypto_ahash_alignmask(crypto_ahash_reqtfm(req)); |
138 | walk->sg = req->src; | 140 | walk->sg = req->src; |
@@ -147,8 +149,10 @@ int crypto_ahash_walk_first(struct ahash_request *req, | |||
147 | { | 149 | { |
148 | walk->total = req->nbytes; | 150 | walk->total = req->nbytes; |
149 | 151 | ||
150 | if (!walk->total) | 152 | if (!walk->total) { |
153 | walk->entrylen = 0; | ||
151 | return 0; | 154 | return 0; |
155 | } | ||
152 | 156 | ||
153 | walk->alignmask = crypto_ahash_alignmask(crypto_ahash_reqtfm(req)); | 157 | walk->alignmask = crypto_ahash_alignmask(crypto_ahash_reqtfm(req)); |
154 | walk->sg = req->src; | 158 | walk->sg = req->src; |
@@ -167,8 +171,10 @@ int crypto_hash_walk_first_compat(struct hash_desc *hdesc, | |||
167 | { | 171 | { |
168 | walk->total = len; | 172 | walk->total = len; |
169 | 173 | ||
170 | if (!walk->total) | 174 | if (!walk->total) { |
175 | walk->entrylen = 0; | ||
171 | return 0; | 176 | return 0; |
177 | } | ||
172 | 178 | ||
173 | walk->alignmask = crypto_hash_alignmask(hdesc->tfm); | 179 | walk->alignmask = crypto_hash_alignmask(hdesc->tfm); |
174 | walk->sg = sg; | 180 | walk->sg = sg; |