[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20161027141516.28447-2-dsafonov@virtuozzo.com>
Date: Thu, 27 Oct 2016 17:15:15 +0300
From: Dmitry Safonov <dsafonov@...tuozzo.com>
To: <linux-kernel@...r.kernel.org>
CC: Dmitry Safonov <dsafonov@...tuozzo.com>, <0x7f454c46@...il.com>,
"Cyrill Gorcunov" <gorcunov@...nvz.org>,
Paul Bolle <pebolle@...cali.nl>,
"Andy Lutomirski" <luto@...nel.org>, <oleg@...hat.com>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>,
"H. Peter Anvin" <hpa@...or.com>, <linux-mm@...ck.org>,
<x86@...nel.org>
Subject: [PATCH 1/2] x86/prctl/uapi: remove ifdef for CHECKPOINT_RESTORE
As userspace knows nothing about kernel config, this ifdefs
will make prctl constants invisible to userspace.
Let it be clean'n'simple: remove ifdefs.
If kernel has CONFIG_CHECKPOINT_RESTORE disabled, sys_prctl()
will return -EINVAL for those prctls.
Fixes: 2eefd8789698 ("x86/arch_prctl/vdso: Add ARCH_MAP_VDSO_*")
Cc: 0x7f454c46@...il.com
Cc: Cyrill Gorcunov <gorcunov@...nvz.org>
Cc: Paul Bolle <pebolle@...cali.nl>
Cc: Andy Lutomirski <luto@...nel.org>
Cc: oleg@...hat.com
Cc: Thomas Gleixner <tglx@...utronix.de>
Cc: Ingo Molnar <mingo@...hat.com>
Cc: "H. Peter Anvin" <hpa@...or.com>
Cc: linux-mm@...ck.org
Cc: x86@...nel.org
Reported-by: Paul Bolle <pebolle@...cali.nl>
Signed-off-by: Dmitry Safonov <dsafonov@...tuozzo.com>
---
arch/x86/include/uapi/asm/prctl.h | 8 +++-----
1 file changed, 3 insertions(+), 5 deletions(-)
diff --git a/arch/x86/include/uapi/asm/prctl.h b/arch/x86/include/uapi/asm/prctl.h
index ae135de547f5..835aa51c7f6e 100644
--- a/arch/x86/include/uapi/asm/prctl.h
+++ b/arch/x86/include/uapi/asm/prctl.h
@@ -6,10 +6,8 @@
#define ARCH_GET_FS 0x1003
#define ARCH_GET_GS 0x1004
-#ifdef CONFIG_CHECKPOINT_RESTORE
-# define ARCH_MAP_VDSO_X32 0x2001
-# define ARCH_MAP_VDSO_32 0x2002
-# define ARCH_MAP_VDSO_64 0x2003
-#endif
+#define ARCH_MAP_VDSO_X32 0x2001
+#define ARCH_MAP_VDSO_32 0x2002
+#define ARCH_MAP_VDSO_64 0x2003
#endif /* _ASM_X86_PRCTL_H */
--
2.10.1
Powered by blists - more mailing lists