x86/fpu: Add a pkru argument to copy_uabi_to_xstate()
authorKyle Huey <me@kylehuey.com>
Mon, 9 Jan 2023 21:02:11 +0000 (13:02 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 14 Jan 2023 09:23:27 +0000 (10:23 +0100)
commitb29773d6b0bb8e4eaab2195dce873fb32a5d4731
treea97d6b4701ee8bdd52a5c033a7874ab339830702
parent9813c5fc22bcc3c7923226137a108b94da9305ee
x86/fpu: Add a pkru argument to copy_uabi_to_xstate()

commit 2c87767c35ee9744f666ccec869d5fe742c3de0a upstream

In preparation for adding PKRU handling code into copy_uabi_to_xstate(),
add an argument that copy_uabi_from_kernel_to_xstate() can use to pass the
canonical location of the PKRU value. For
copy_sigframe_from_user_to_xstate() the kernel will actually restore the
PKRU value from the fpstate, but pass in the thread_struct's pkru location
anyways for consistency.

Signed-off-by: Kyle Huey <me@kylehuey.com>
Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com>
Link: https://lore.kernel.org/all/20221115230932.7126-4-khuey%40kylehuey.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
arch/x86/kernel/fpu/xstate.c