[RFC PATCH v2 0/1] x86/pkeys: update PKRU to enable pkey 0

From: Aruna Ramakrishna
Date: Thu Mar 21 2024 - 17:56:55 EST


v2 updates:
- PKRU is passed as a parameter from handle_signal() all the way to
copy_fpregs_to_sigframe(), where it actually updates PKRU in the
sigframe

I'm working on adding a test case in
tools/testing/selftests/mm/protection_keys.c.

Aruna Ramakrishna (1):
x86/pkeys: update PKRU to enable pkey 0 before XSAVE

arch/x86/include/asm/fpu/signal.h | 3 +-
arch/x86/include/asm/sighandling.h | 10 +++----
arch/x86/kernel/fpu/signal.c | 44 ++++++++++++++++++++++++++----
arch/x86/kernel/fpu/xstate.c | 13 +++++++++
arch/x86/kernel/fpu/xstate.h | 1 +
arch/x86/kernel/signal.c | 40 +++++++++++++++++++++------
arch/x86/kernel/signal_32.c | 8 +++---
arch/x86/kernel/signal_64.c | 9 +++---
8 files changed, 101 insertions(+), 27 deletions(-)

--
2.39.3