riscv: Fix EFI stub usage of KASAN instrumented strcmp function
authorAlexandre Ghiti <alexghiti@rivosinc.com>
Fri, 3 Feb 2023 07:52:30 +0000 (08:52 +0100)
committerPalmer Dabbelt <palmer@rivosinc.com>
Wed, 19 Apr 2023 14:24:52 +0000 (07:24 -0700)
commit617955ca6e275c4dd0dcf5316fca7fc04a8f2fe6
treeacc58db405d96463aa2e8f898d07961b1efec68b
parent401e84488800d05e8ed6db2a687eaa94415f4ec8
riscv: Fix EFI stub usage of KASAN instrumented strcmp function

The EFI stub must not use any KASAN instrumented code as the kernel
proper did not initialize the thread pointer and the mapping for the
KASAN shadow region.

Avoid using the generic strcmp function, instead use the one in
drivers/firmware/efi/libstub/string.c.

Signed-off-by: Alexandre Ghiti <alexghiti@rivosinc.com>
Acked-by: Ard Biesheuvel <ardb@kernel.org>
Reviewed-by: Atish Patra <atishp@rivosinc.com>
Link: https://lore.kernel.org/r/20230203075232.274282-5-alexghiti@rivosinc.com
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
arch/riscv/kernel/image-vars.h