]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
riscv: avoid Imbalance in RAS
authorJisheng Zhang <jszhang@kernel.org>
Sat, 20 Jul 2024 17:06:59 +0000 (01:06 +0800)
committerPalmer Dabbelt <palmer@rivosinc.com>
Mon, 16 Sep 2024 03:58:25 +0000 (20:58 -0700)
commit8f1534e7440382d118c3d655d3a6014128b2086d
tree125343c989be1ae407db466d0e9ca5edd5f4eff9
parent7e340f4fad46b766705be96f5d1c764a397a7a36
riscv: avoid Imbalance in RAS

Inspired by[1], modify the code to remove the code of modifying ra to
avoid imbalance RAS (return address stack) which may lead to incorret
predictions on return.

Link: https://lore.kernel.org/linux-riscv/20240607061335.2197383-1-cyrilbur@tenstorrent.com/
Signed-off-by: Jisheng Zhang <jszhang@kernel.org>
Reviewed-by: Cyril Bur <cyrilbur@tenstorrent.com>
Link: https://lore.kernel.org/r/20240720170659.1522-1-jszhang@kernel.org
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
arch/riscv/kernel/entry.S