Skip to contentSkip to conversation

Remove redundant check for CONFIG_MMU

PATCH New David Howells 1 participant 1 message Apr 26, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Remove redundant check for CONFIG_MMU

From: Christoph Egger <[email protected]>

The checks for CONFIG_MMU at this location are duplicated as all the code is located inside a #ifndef CONFIG_MMU block. So the first conditional block will always be included while the second never will.

---

 fs/binfmt_elf_fdpic.c |    7 -------
 1 files changed, 0 insertions(+), 7 deletions(-)
fs/binfmt_elf_fdpic.c +0 -7
index 7ab23e0..2c5f9a0 100644
@@ -1005,15 +1005,8 @@ static int elf_fdpic_map_file_constdisp_on_uclinux(
 				}
 			} else if (!mm->start_data) {
 				mm->start_data = seg->addr;
-#ifndef CONFIG_MMU
 				mm->end_data = seg->addr + phdr->p_memsz;
-#endif
 			}
-
-#ifdef CONFIG_MMU
-			if (seg->addr + phdr->p_memsz > mm->end_data)
-				mm->end_data = seg->addr + phdr->p_memsz;
-#endif
 		}
 
 		seg++;