]> err.no Git - linux-2.6/blobdiff - include/asm-ppc64/elf.h
Automatic merge of rsync://rsync.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6
[linux-2.6] / include / asm-ppc64 / elf.h
index 8457d90244fbef006f7042ad3e8f325334e99f17..6c42d61bedd13447e219150362a0dbc7e058734a 100644 (file)
@@ -229,9 +229,13 @@ do {                                                               \
 
 /*
  * An executable for which elf_read_implies_exec() returns TRUE will
- * have the READ_IMPLIES_EXEC personality flag set automatically.
+ * have the READ_IMPLIES_EXEC personality flag set automatically. This
+ * is only required to work around bugs in old 32bit toolchains. Since
+ * the 64bit ABI has never had these issues dont enable the workaround
+ * even if we have an executable stack.
  */
-#define elf_read_implies_exec(ex, exec_stk)    (exec_stk != EXSTACK_DISABLE_X)
+#define elf_read_implies_exec(ex, exec_stk) (test_thread_flag(TIF_32BIT) ? \
+               (exec_stk != EXSTACK_DISABLE_X) : 0)
 
 #endif