Skip to contentSkip to conversation

generic syscalls: kill cruft from removed pkey syscalls

PATCH In review Dave Hansen 2 participants 2 messages Oct 17, 2016

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 generic syscalls: kill cruft from removed pkey syscalls

From: Dave Hansen <[email protected]>

pkey_set() and pkey_get() were syscalls present in older versions of the protection keys patches. They were fully excised from the x86 code, but some cruft was left in the generic syscall code. The C++ comments were intended to help to make it more glaring to me to fix them before actually submitting them. That technique worked, but later than I would have liked.

I test-compiled this for arm64.

Cc Thomas Gleixner <[email protected]>
Cc Arnd Bergmann <[email protected]>
Fixes a60f7b69d92c0 ("generic syscalls: Wire up memory protection keys syscalls")

---

 b/include/linux/syscalls.h          |    3 ---
 b/include/uapi/asm-generic/unistd.h |    4 ----
 2 files changed, 7 deletions(-)
include/uapi/asm-generic/unistd.h renamed from include/uapi/asm-generic/unistd.h~kill-kpkey-syscall-nr-cruft +0 -4
diff -puN include/uapi/asm-generic/unistd.h~kill-kpkey-syscall-nr-cruft include/uapi/asm-generic/unistd.h
@@ -730,10 +730,6 @@ __SYSCALL(__NR_pkey_mprotect, sys_pkey_m
 __SYSCALL(__NR_pkey_alloc,    sys_pkey_alloc)
 #define __NR_pkey_free 290
 __SYSCALL(__NR_pkey_free,     sys_pkey_free)
-#define __NR_pkey_get 291
-//__SYSCALL(__NR_pkey_get,      sys_pkey_get)
-#define __NR_pkey_set 292
-//__SYSCALL(__NR_pkey_set,      sys_pkey_set)
 
 #undef __NR_syscalls
 #define __NR_syscalls 291
include/linux/syscalls.h renamed from include/linux/syscalls.h~kill-kpkey-syscall-nr-cruft +0 -3
diff -puN include/linux/syscalls.h~kill-kpkey-syscall-nr-cruft include/linux/syscalls.h
@@ -902,8 +902,5 @@ asmlinkage long sys_pkey_mprotect(unsign
 				  unsigned long prot, int pkey);
 asmlinkage long sys_pkey_alloc(unsigned long flags, unsigned long init_val);
 asmlinkage long sys_pkey_free(int pkey);
-//asmlinkage long sys_pkey_get(int pkey, unsigned long flags);
-//asmlinkage long sys_pkey_set(int pkey, unsigned long access_rights,
-//			     unsigned long flags);
 
 #endif

_

maintainer Acked-by on v1 1/1
#1 lore raw
Quoted 10 lines · CEST Dave Hansen

pkey_set() and pkey_get() were syscalls present in older versions of the protection keys patches. They were fully excised from the x86 code, but some cruft was left in the generic syscall code. The C++ comments were intended to help to make it more glaring to me to fix them before actually submitting them. That technique worked, but later than I would have liked.

I test-compiled this for arm64.

Quoted 12 lines
Cc Thomas Gleixner <[email protected]>
Cc Arnd Bergmann <[email protected]>
Cc torvalds-de/[email protected]
Fixes a60f7b69d92c0 ("generic syscalls: Wire up memory protection keys syscalls")