riscv: Decouple emulated unaligned accesses from access speed
authorCharlie Jenkins <charlie@rivosinc.com>
Fri, 8 Mar 2024 18:25:57 +0000 (10:25 -0800)
committerPalmer Dabbelt <palmer@rivosinc.com>
Wed, 13 Mar 2024 14:30:30 +0000 (07:30 -0700)
commit6e5ce7f2eae3c7c36dd1709efaac34820a34d538
tree025cf18ffc0770c06be95844f16b9eab34d8cf0e
parent313130c62cf1fc410ac8730b291fd4fde582d032
riscv: Decouple emulated unaligned accesses from access speed

Detecting if a system traps into the kernel on an unaligned access
can be performed separately from checking the speed of unaligned
accesses. This decoupling will make it possible to selectively enable
or disable each of these checks.

Signed-off-by: Charlie Jenkins <charlie@rivosinc.com>
Reviewed-by: Conor Dooley <conor.dooley@microchip.com>
Tested-by: Samuel Holland <samuel.holland@sifive.com>
Link: https://lore.kernel.org/r/20240308-disable_misaligned_probe_config-v9-3-a388770ba0ce@rivosinc.com
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
arch/riscv/include/asm/cpufeature.h
arch/riscv/kernel/cpufeature.c
arch/riscv/kernel/traps_misaligned.c