From: Michael Ellerman Date: Fri, 13 Apr 2018 13:54:52 +0000 (+1000) Subject: mm/pkeys: Add an empty arch_pkeys_enabled() X-Git-Tag: v4.18-rc1~108^2~114^2~2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=4414ef9536c398ebc4e1443d59fbae8fea53732b;p=thirdparty%2Fkernel%2Flinux.git 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 . Signed-off-by: Michael Ellerman Reviewed-by: Dave Hansen --- diff --git a/include/linux/pkeys.h b/include/linux/pkeys.h index 946cb773b79f1..2955ba9760489 100644 --- a/include/linux/pkeys.h +++ b/include/linux/pkeys.h @@ -39,6 +39,11 @@ static inline int arch_set_user_pkey_access(struct task_struct *tsk, int pkey, return 0; } +static inline bool arch_pkeys_enabled(void) +{ + return false; +} + static inline void copy_init_pkru_to_fpregs(void) { }