diff options
author | James Hogan <james.hogan@imgtec.com> | 2011-05-09 05:58:40 -0400 |
---|---|---|
committer | James Hogan <james.hogan@imgtec.com> | 2013-03-02 15:09:15 -0500 |
commit | c07380beafabee343a7f298bacd22598d72c7c87 (patch) | |
tree | 73afc02a5249b56bd8f31ebd5c15756bcf7ce21b /fs | |
parent | 4dd3c95940b836bc4073e8827973362e78f5e204 (diff) |
Revert some of "binfmt_elf: cleanups"
The commit "binfmt_elf: cleanups"
(f670d0ecda73b7438eec9ed108680bc5f5362ad8) removed an ifndef elf_map but
this breaks compilation for metag which does define elf_map.
This adds the ifndef back in as it was before, but does not affect the
other cleanups made by that patch.
Signed-off-by: James Hogan <james.hogan@imgtec.com>
Cc: Alexander Viro <viro@zeniv.linux.org.uk>
Cc: linux-fsdevel@vger.kernel.org
Acked-by: Mikael Pettersson <mikpe@it.uu.se>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/binfmt_elf.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/fs/binfmt_elf.c b/fs/binfmt_elf.c index 0c42cdbabecf..cfc22c9d75bc 100644 --- a/fs/binfmt_elf.c +++ b/fs/binfmt_elf.c | |||
@@ -321,6 +321,8 @@ create_elf_tables(struct linux_binprm *bprm, struct elfhdr *exec, | |||
321 | return 0; | 321 | return 0; |
322 | } | 322 | } |
323 | 323 | ||
324 | #ifndef elf_map | ||
325 | |||
324 | static unsigned long elf_map(struct file *filep, unsigned long addr, | 326 | static unsigned long elf_map(struct file *filep, unsigned long addr, |
325 | struct elf_phdr *eppnt, int prot, int type, | 327 | struct elf_phdr *eppnt, int prot, int type, |
326 | unsigned long total_size) | 328 | unsigned long total_size) |
@@ -355,6 +357,8 @@ static unsigned long elf_map(struct file *filep, unsigned long addr, | |||
355 | return(map_addr); | 357 | return(map_addr); |
356 | } | 358 | } |
357 | 359 | ||
360 | #endif /* !elf_map */ | ||
361 | |||
358 | static unsigned long total_mapping_size(struct elf_phdr *cmds, int nr) | 362 | static unsigned long total_mapping_size(struct elf_phdr *cmds, int nr) |
359 | { | 363 | { |
360 | int i, first_idx = -1, last_idx = -1; | 364 | int i, first_idx = -1, last_idx = -1; |