diff options
author | Kees Cook <keescook@chromium.org> | 2022-02-24 09:04:11 +0300 |
---|---|---|
committer | Palmer Dabbelt <palmer@rivosinc.com> | 2022-03-31 01:15:27 +0300 |
commit | fdecfea09328b33fd08a4d418237cce9fd176d69 (patch) | |
tree | 10f3a86dd6726298feee560234f98db3dfb6273f /arch/riscv/include | |
parent | 60210a3d86dc57ce4a76a366e7841dda746a33f7 (diff) | |
download | linux-fdecfea09328b33fd08a4d418237cce9fd176d69.tar.xz |
riscv: Rename "sp_in_global" to "current_stack_pointer"
To follow the existing per-arch conventions, rename "sp_in_global" to
"current_stack_pointer". This will let it be used in non-arch places
(like HARDENED_USERCOPY).
Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Palmer Dabbelt <palmer@rivosinc.com>
Diffstat (limited to 'arch/riscv/include')
-rw-r--r-- | arch/riscv/include/asm/current.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/riscv/include/asm/current.h b/arch/riscv/include/asm/current.h index 1de233d8e8de..21774d868c65 100644 --- a/arch/riscv/include/asm/current.h +++ b/arch/riscv/include/asm/current.h @@ -33,6 +33,8 @@ static __always_inline struct task_struct *get_current(void) #define current get_current() +register unsigned long current_stack_pointer __asm__("sp"); + #endif /* __ASSEMBLY__ */ #endif /* _ASM_RISCV_CURRENT_H */ |