summaryrefslogtreecommitdiff
path: root/arch/x86/kernel/Makefile
diff options
context:
space:
mode:
authorRick Edgecombe <rick.p.edgecombe@intel.com>2023-06-12 17:10:52 -0700
committerDave Hansen <dave.hansen@linux.intel.com>2023-08-02 15:01:50 -0700
commit98cfa4630912a80a575277d1bf193376ba66116a (patch)
tree1d861154e8be4b5e1c6adb37bafd95f30ddabbc1 /arch/x86/kernel/Makefile
parent6ee836687a3f39f92da790d33fa9694fe0143410 (diff)
downloadlinux-98cfa4630912a80a575277d1bf193376ba66116a.tar.gz
linux-98cfa4630912a80a575277d1bf193376ba66116a.tar.bz2
linux-98cfa4630912a80a575277d1bf193376ba66116a.zip
x86: Introduce userspace API for shadow stack
Add three new arch_prctl() handles: - ARCH_SHSTK_ENABLE/DISABLE enables or disables the specified feature. Returns 0 on success or a negative value on error. - ARCH_SHSTK_LOCK prevents future disabling or enabling of the specified feature. Returns 0 on success or a negative value on error. The features are handled per-thread and inherited over fork(2)/clone(2), but reset on exec(). Co-developed-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Signed-off-by: Rick Edgecombe <rick.p.edgecombe@intel.com> Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com> Reviewed-by: Borislav Petkov (AMD) <bp@alien8.de> Reviewed-by: Kees Cook <keescook@chromium.org> Acked-by: Mike Rapoport (IBM) <rppt@kernel.org> Tested-by: Pengfei Xu <pengfei.xu@intel.com> Tested-by: John Allen <john.allen@amd.com> Tested-by: Kees Cook <keescook@chromium.org> Link: https://lore.kernel.org/all/20230613001108.3040476-27-rick.p.edgecombe%40intel.com
Diffstat (limited to 'arch/x86/kernel/Makefile')
-rw-r--r--arch/x86/kernel/Makefile2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/kernel/Makefile b/arch/x86/kernel/Makefile
index abee0564b750..6b6bf47652ee 100644
--- a/arch/x86/kernel/Makefile
+++ b/arch/x86/kernel/Makefile
@@ -147,6 +147,8 @@ obj-$(CONFIG_CALL_THUNKS) += callthunks.o
obj-$(CONFIG_X86_CET) += cet.o
+obj-$(CONFIG_X86_USER_SHADOW_STACK) += shstk.o
+
###
# 64 bit specific files
ifeq ($(CONFIG_X86_64),y)