Revision d411cf02ed0260dacc4b2fd61dd5040fc2aa97e7 authored by Greentime Hu on 19 December 2019, 06:44:59 UTC, committed by Paul Walmsley on 20 December 2019, 11:32:24 UTC
This patch fixes that the sscratch register clearing in M-mode. It cleared
sscratch register in M-mode, but it should clear mscratch register. That will
cause kernel trap if the CPU core doesn't support S-mode when trying to access
sscratch.

Fixes: 9e80635619b5 ("riscv: clear the instruction cache and all registers when booting")
Signed-off-by: Greentime Hu <greentime.hu@sifive.com>
Reviewed-by: Anup Patel <anup@brainfault.org>
Signed-off-by: Paul Walmsley <paul.walmsley@sifive.com>
1 parent 0312a3d
History
File Mode Size
test
.gitignore -rw-r--r-- 66 bytes
Makefile -rw-r--r-- 3.2 KB
algos.c -rw-r--r-- 6.1 KB
altivec.uc -rw-r--r-- 3.3 KB
avx2.c -rw-r--r-- 16.8 KB
avx512.c -rw-r--r-- 17.7 KB
int.uc -rw-r--r-- 3.7 KB
mktables.c -rw-r--r-- 3.9 KB
mmx.c -rw-r--r-- 3.6 KB
neon.c -rw-r--r-- 2.0 KB
neon.uc -rw-r--r-- 3.8 KB
recov.c -rw-r--r-- 3.3 KB
recov_avx2.c -rw-r--r-- 8.8 KB
recov_avx512.c -rw-r--r-- 9.4 KB
recov_neon.c -rw-r--r-- 2.6 KB
recov_neon_inner.c -rw-r--r-- 2.3 KB
recov_s390xc.c -rw-r--r-- 2.7 KB
recov_ssse3.c -rw-r--r-- 9.1 KB
s390vx.uc -rw-r--r-- 3.8 KB
sse1.c -rw-r--r-- 4.6 KB
sse2.c -rw-r--r-- 15.8 KB
unroll.awk -rw-r--r-- 423 bytes
vpermxor.uc -rw-r--r-- 2.7 KB
x86.h -rw-r--r-- 2.1 KB

back to top