Re: [PATCH v6 09/15] arm64: reserve x18 from general allocation with SCS

From: Will Deacon
Date: Thu Jan 16 2020 - 13:10:41 EST


On Fri, Dec 06, 2019 at 02:13:45PM -0800, Sami Tolvanen wrote:
> Reserve the x18 register from general allocation when SCS is enabled,
> because the compiler uses the register to store the current task's
> shadow stack pointer. Note that all external kernel modules must also be
> compiled with -ffixed-x18 if the kernel has SCS enabled.
>
> Signed-off-by: Sami Tolvanen <samitolvanen@xxxxxxxxxx>
> Reviewed-by: Nick Desaulniers <ndesaulniers@xxxxxxxxxx>
> Reviewed-by: Kees Cook <keescook@xxxxxxxxxxxx>
> ---
> arch/arm64/Makefile | 4 ++++
> 1 file changed, 4 insertions(+)

Acked-by: Will Deacon <will@xxxxxxxxxx>

Will