riscv: add icache flush for nommu sigreturn trampoline
stable inclusion from stable-v5.10.178 commit 2a4835b8ede001ce88a34f6f0295f4ece2212174 category: bugfix bugzilla: https://gitee.com/openeuler/kernel/issues/I8D927 Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=2a4835b8ede001ce88a34f6f0295f4ece2212174 -------------------------------- commit 8d736482 upstream. In a NOMMU kernel, sigreturn trampolines are generated on the user stack by setup_rt_frame. Currently, these trampolines are not instruction fenced, thus their visibility to ifetch is not guaranteed. This patch adds a flush_icache_range in setup_rt_frame to fix this problem. Signed-off-by:Mathis Salmen <mathis.salmen@matsal.de> Fixes: 6bd33e1e ("riscv: add nommu support") Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/20230406101130.82304-1-mathis.salmen@matsal.de Signed-off-by:
Palmer Dabbelt <palmer@rivosinc.com> Signed-off-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by:
sanglipeng <sanglipeng1@jd.com>
Loading
Please sign in to comment