Re: [PATCH v29 23/32] x86/cet/shstk: Add user-mode shadow stack support

From
Borislav Petkov <bp@alien8.de>
Date
2021-08-27 18:46:01
Also in
linux-api, linux-arch, linux-doc, lkml
Reply to
Yu, Yu-cheng, 2021-08-27
On Fri, Aug 27, 2021 at 11:37:34AM -0700, Yu, Yu-cheng wrote:
Right now, the kernel does lazy restore, and it waits until right before a
task goes back to ring-3 to restore xstates.  If a task needs to write to
any xstate registers before that (e.g. for signals), it restores the whole
xstates first and clears TIF_NEED_FPU_LOAD, which will prevent xstates being
restored again later.
shstk_setup() allocates a shadow stack for the task and puts its pointer
in MSR_IA32_PL3_SSP.

What does that have to do with a task having to write any xstate
registers?

-- 
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette
Thread (51 messages) 51 messages, 5 authors, last reply 2021-09-01
Keyboard shortcuts
hback out one level
jnext message in thread / next series-diff position
kprevious message in thread / previous series-diff position
ldrill in
Escclose help / fold thread tree
?toggle this help