diff options
| author | Cheng-Yang Chou <yphbchou0911@gmail.com> | 2026-03-06 14:42:54 +0800 |
|---|---|---|
| committer | Eric Biggers <ebiggers@kernel.org> | 2026-03-09 13:46:11 -0700 |
| commit | 652a3017c485937cdb0706aa54f9dc74312c97a7 (patch) | |
| tree | 36877b4c3a23a5fe912ede5dd506af8b944e774e /include/uapi/linux/wimax/git@git.tavy.me:linux.git | |
| parent | 1f318b96cc84d7c2ab792fcc0bfd42a7ca890681 (diff) | |
crypto: arm64/aes-neonbs - Move key expansion off the stack
aesbs_setkey() and aesbs_cbc_ctr_setkey() allocate struct crypto_aes_ctx
on the stack. On arm64, the kernel-mode NEON context is also stored on
the stack, causing the combined frame size to exceed 1024 bytes and
triggering -Wframe-larger-than= warnings.
Allocate struct crypto_aes_ctx on the heap instead and use
kfree_sensitive() to ensure the key material is zeroed on free.
Use a goto-based cleanup path to ensure kfree_sensitive() is always
called.
Signed-off-by: Cheng-Yang Chou <yphbchou0911@gmail.com>
Fixes: 4fa617cc6851 ("arm64/fpsimd: Allocate kernel mode FP/SIMD buffers on the stack")
Link: https://lore.kernel.org/r/20260306064254.2079274-1-yphbchou0911@gmail.com
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
Diffstat (limited to 'include/uapi/linux/wimax/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions
