瀏覽代碼

mm/pkeys: Add an empty arch_pkeys_enabled()

Add an empty arch_pkeys_enabled() in linux/pkeys.h for the
CONFIG_ARCH_HAS_PKEYS=n case.

Split out of a patch by Ram Pai <linuxram@us.ibm.com>.

Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Reviewed-by: Dave Hansen <dave.hansen@intel.com>
Michael Ellerman 7 年之前
父節點
當前提交
4414ef9536
共有 1 個文件被更改,包括 5 次插入0 次删除
  1. 5 0
      include/linux/pkeys.h

+ 5 - 0
include/linux/pkeys.h

@@ -39,6 +39,11 @@ static inline int arch_set_user_pkey_access(struct task_struct *tsk, int pkey,
 	return 0;
 	return 0;
 }
 }
 
 
+static inline bool arch_pkeys_enabled(void)
+{
+	return false;
+}
+
 static inline void copy_init_pkru_to_fpregs(void)
 static inline void copy_init_pkru_to_fpregs(void)
 {
 {
 }
 }