diff options
author | David Woodhouse <dwmw2@infradead.org> | 2008-06-16 07:11:54 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-06-16 13:20:57 -0400 |
commit | 702773b16e83fcddc41e0019b8214d3c3cecedbe (patch) | |
tree | be9fa9552f6583249b61fee0373c11e1cfab1562 | |
parent | b052beb0432616aa4dac2b167e7809feae993991 (diff) |
Include <asm/a.out.h> in fs/exec.c only for Alpha.
We only need it for the /sbin/loader hack for OSF/1 executables, and we
don't want to include it otherwise.
While we're at it, remove the redundant '&& CONFIG_ARCH_SUPPORTS_AOUT'
in the ifdef around that code. It's already dependent on __alpha__, and
CONFIG_ARCH_SUPPORTS_AOUT is hard-coded to 'y' there.
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Acked-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r-- | fs/exec.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -26,7 +26,6 @@ | |||
26 | #include <linux/file.h> | 26 | #include <linux/file.h> |
27 | #include <linux/fdtable.h> | 27 | #include <linux/fdtable.h> |
28 | #include <linux/mman.h> | 28 | #include <linux/mman.h> |
29 | #include <linux/a.out.h> | ||
30 | #include <linux/stat.h> | 29 | #include <linux/stat.h> |
31 | #include <linux/fcntl.h> | 30 | #include <linux/fcntl.h> |
32 | #include <linux/smp_lock.h> | 31 | #include <linux/smp_lock.h> |
@@ -61,6 +60,11 @@ | |||
61 | #include <linux/kmod.h> | 60 | #include <linux/kmod.h> |
62 | #endif | 61 | #endif |
63 | 62 | ||
63 | #ifdef __alpha__ | ||
64 | /* for /sbin/loader handling in search_binary_handler() */ | ||
65 | #include <linux/a.out.h> | ||
66 | #endif | ||
67 | |||
64 | int core_uses_pid; | 68 | int core_uses_pid; |
65 | char core_pattern[CORENAME_MAX_SIZE] = "core"; | 69 | char core_pattern[CORENAME_MAX_SIZE] = "core"; |
66 | int suid_dumpable = 0; | 70 | int suid_dumpable = 0; |
@@ -1155,7 +1159,7 @@ int search_binary_handler(struct linux_binprm *bprm,struct pt_regs *regs) | |||
1155 | { | 1159 | { |
1156 | int try,retval; | 1160 | int try,retval; |
1157 | struct linux_binfmt *fmt; | 1161 | struct linux_binfmt *fmt; |
1158 | #if defined(__alpha__) && defined(CONFIG_ARCH_SUPPORTS_AOUT) | 1162 | #ifdef __alpha__ |
1159 | /* handle /sbin/loader.. */ | 1163 | /* handle /sbin/loader.. */ |
1160 | { | 1164 | { |
1161 | struct exec * eh = (struct exec *) bprm->buf; | 1165 | struct exec * eh = (struct exec *) bprm->buf; |