summaryrefslogtreecommitdiff
path: root/arch/x86/crypto/sha1_avx2_x86_64_asm.S
diff options
context:
space:
mode:
authorKees Cook <keescook@chromium.org>2020-01-14 19:57:29 -0800
committerHerbert Xu <herbert@gondor.apana.org.au>2020-01-22 16:21:08 +0800
commit41419a289010836bd759bf7e254fe041a3dc52d2 (patch)
tree0de2610ef1b1c74cac134047b470a18d36853b20 /arch/x86/crypto/sha1_avx2_x86_64_asm.S
parente0437dc6470c46a116aeb65769698dbc1487ed16 (diff)
crypto: x86/sha - Eliminate casts on asm implementations
In order to avoid CFI function prototype mismatches, this removes the casts on assembly implementations of sha1/256/512 accelerators. The safety checks from BUILD_BUG_ON() remain. Additionally, this renames various arguments for clarity, as suggested by Eric Biggers. Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'arch/x86/crypto/sha1_avx2_x86_64_asm.S')
-rw-r--r--arch/x86/crypto/sha1_avx2_x86_64_asm.S6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/x86/crypto/sha1_avx2_x86_64_asm.S b/arch/x86/crypto/sha1_avx2_x86_64_asm.S
index 6decc85ef7b7..1e594d60afa5 100644
--- a/arch/x86/crypto/sha1_avx2_x86_64_asm.S
+++ b/arch/x86/crypto/sha1_avx2_x86_64_asm.S
@@ -62,11 +62,11 @@
*Visit http://software.intel.com/en-us/articles/
*and refer to improving-the-performance-of-the-secure-hash-algorithm-1/
*
- *Updates 20-byte SHA-1 record in 'hash' for even number of
- *'num_blocks' consecutive 64-byte blocks
+ *Updates 20-byte SHA-1 record at start of 'state', from 'input', for
+ *even number of 'blocks' consecutive 64-byte blocks.
*
*extern "C" void sha1_transform_avx2(
- * int *hash, const char* input, size_t num_blocks );
+ * struct sha1_state *state, const u8* input, int blocks );
*/
#include <linux/linkage.h>