mirror-linux/lib/crypto/riscv
Vivian Wang 43169328c7 lib/crypto: riscv/chacha: Avoid s0/fp register
In chacha_zvkb, avoid using the s0 register, which is the frame pointer,
by reallocating KEY0 to t5. This makes stack traces available if e.g. a
crash happens in chacha_zvkb.

No frame pointer maintenance is otherwise required since this is a leaf
function.

Signed-off-by: Vivian Wang <wangruikang@iscas.ac.cn>
Fixes: bb54668837 ("crypto: riscv - add vector crypto accelerated ChaCha20")
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20251202-riscv-chacha_zvkb-fp-v2-1-7bd00098c9dc@iscas.ac.cn
Signed-off-by: Eric Biggers <ebiggers@kernel.org>
2025-12-09 15:10:20 -08:00
..
chacha-riscv64-zvkb.S lib/crypto: riscv/chacha: Avoid s0/fp register 2025-12-09 15:10:20 -08:00
chacha.h lib/crypto: chacha: Consolidate into single module 2025-08-29 09:50:19 -07:00
poly1305-riscv.pl lib/crypto: riscv/poly1305: Import OpenSSL/CRYPTOGAMS implementation 2025-08-29 09:49:18 -07:00
poly1305.h lib/crypto: riscv/poly1305: Import OpenSSL/CRYPTOGAMS implementation 2025-08-29 09:49:18 -07:00
sha256-riscv64-zvknha_or_zvknhb-zvkb.S lib/crypto: sha256: Propagate sha256_block_state type to implementations 2025-07-04 10:22:57 -07:00
sha256.h lib/crypto: Drop inline from all *_mod_init_arch() functions 2025-08-27 08:15:35 -07:00
sha512-riscv64-zvknhb-zvkb.S
sha512.h lib/crypto: Drop inline from all *_mod_init_arch() functions 2025-08-27 08:15:35 -07:00