lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1440861626-27008-7-git-send-email-brgerst@gmail.com>
Date:	Sat, 29 Aug 2015 11:20:25 -0400
From:	Brian Gerst <brgerst@...il.com>
To:	x86@...nel.org, linux-kernel@...r.kernel.org
Cc:	Ingo Molnar <mingo@...nel.org>, "H. Peter Anvin" <hpa@...or.com>,
	Denys Vlasenko <dvlasenk@...hat.com>,
	Andy Lutomirski <luto@...capital.net>,
	Linus Torvalds <torvalds@...ux-foundation.org>
Subject: [PATCH 6/7] x86/vdso32/xen: Move VDSO_NOTE_NONEGSEG_BIT define

Xen had its own vdso.h just to define VDSO_NOTE_NONEGSEG_BIT.  Move it to the
main vdso.h.

Signed-off-by: Brian Gerst <brgerst@...il.com>
---
 arch/x86/entry/vdso/vdso-note.S | 4 +---
 arch/x86/include/asm/vdso.h     | 9 +++++++++
 arch/x86/xen/setup.c            | 1 -
 arch/x86/xen/vdso.h             | 4 ----
 4 files changed, 10 insertions(+), 8 deletions(-)
 delete mode 100644 arch/x86/xen/vdso.h

diff --git a/arch/x86/entry/vdso/vdso-note.S b/arch/x86/entry/vdso/vdso-note.S
index eb8a6c7..34aa574 100644
--- a/arch/x86/entry/vdso/vdso-note.S
+++ b/arch/x86/entry/vdso/vdso-note.S
@@ -5,6 +5,7 @@
 
 #include <linux/version.h>
 #include <linux/elfnote.h>
+#include <asm/vdso.h>
 
 /* Ideally this would use UTS_NAME, but using a quoted string here
    doesn't work. Remember to change this when changing the
@@ -32,9 +33,6 @@ ELFNOTE_END
  * if its bit is set in the mask word.  So, we start with the mask 0, and
  * at boot time we set VDSO_NOTE_NONEGSEG_BIT if running under Xen.
  */
-
-#include "../../xen/vdso.h"	/* Defines VDSO_NOTE_NONEGSEG_BIT.  */
-
 ELFNOTE_START(GNU, 2, "a")
 	.long 1			/* ncaps */
 VDSO32_NOTE_MASK:		/* Symbol used by arch/x86/xen/setup.c */
diff --git a/arch/x86/include/asm/vdso.h b/arch/x86/include/asm/vdso.h
index 16d5c18..8d9a961 100644
--- a/arch/x86/include/asm/vdso.h
+++ b/arch/x86/include/asm/vdso.h
@@ -48,4 +48,13 @@ extern void __init init_vdso_image(const struct vdso_image *image);
 
 #endif /* __ASSEMBLER__ */
 
+#if defined(CONFIG_X86_32) || defined(CONFIG_IA32_EMULATION)
+/*
+ * Bit used for the pseudo-hwcap for non-negative segments.  We use
+ *    bit 1 to avoid bugs in some versions of glibc when bit 0 is
+ *       used; the choice is otherwise arbitrary.
+ */
+#define VDSO_NOTE_NONEGSEG_BIT  1
+#endif
+
 #endif /* _ASM_X86_VDSO_H */
diff --git a/arch/x86/xen/setup.c b/arch/x86/xen/setup.c
index b166ffd..79f9ed7 100644
--- a/arch/x86/xen/setup.c
+++ b/arch/x86/xen/setup.c
@@ -28,7 +28,6 @@
 #include <xen/interface/physdev.h>
 #include <xen/features.h>
 #include "xen-ops.h"
-#include "vdso.h"
 #include "p2m.h"
 #include "mmu.h"
 
diff --git a/arch/x86/xen/vdso.h b/arch/x86/xen/vdso.h
deleted file mode 100644
index 861fedf..0000000
--- a/arch/x86/xen/vdso.h
+++ /dev/null
@@ -1,4 +0,0 @@
-/* Bit used for the pseudo-hwcap for non-negative segments.  We use
-   bit 1 to avoid bugs in some versions of glibc when bit 0 is
-   used; the choice is otherwise arbitrary. */
-#define VDSO_NOTE_NONEGSEG_BIT	1
-- 
2.4.3

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ