linux/include
Anton Blanchard 7e60d1b427 [POWERPC] Move ELF_ET_DYN_BASE up to 512MB point
I often test new versions of glibc by doing:

LD_LIBRARY_PATH=/XXX/lib /XXX/lib/ld.so.1 <binary>

One test case ended up SEGV'ing. Upon closer inspection ld.so was loaded
at 0x8000000 (128MB) with the heap right after it. Since we normally
link binaries at 0x10000000 (256MB) we only had about 128MB of space for
the heap:

00100000-00103000 r-xp 00100000 00:00 0           [vdso]
08000000-0801e000 r-xp 00000000 00:01 33079       /lib/ld-2.5.so
0802d000-0802f000 rwxp 0001d000 00:01 33079       /lib/ld-2.5.so
0802f000-08050000 rwxp 0802f000 00:00 0           [heap]
0fe91000-0ffd9000 r-xp 00000000 00:01 33082       /lib/libc-2.5.so
0ffd9000-0ffe8000 ---p 00148000 00:01 33082       /lib/libc-2.5.so
0ffe8000-0ffea000 r--p 00147000 00:01 33082       /lib/libc-2.5.so
0ffea000-0ffed000 rwxp 00149000 00:01 33082       /lib/libc-2.5.so
10000000-10004000 r-xp 00000000 00:01 76          /bin/sleep
10013000-10014000 rwxp 00003000 00:01 76          /bin/sleep
ffb41000-ffb56000 rw-p ffb41000 00:00 0           [stack]

One way to fix this is move ELF_ET_DYN_BASE from 0x08000000 to 0x20000000.
This allows 128MB for the binary (hopefully enough for even the most
crazy c++ apps), and with our current layout we will grow the heap up
and the stack down, allowing potentially gigabytes of heap:

00100000-00103000 r-xp 00100000 00:00 0           [vdso]
0fe8a000-0ffd3000 r-xp 00000000 00:01 3350        /lib/tls/libc-2.3.6.so
0ffd3000-0ffe3000 ---p 00149000 00:01 3350        /lib/tls/libc-2.3.6.so
0ffe3000-0ffea000 r--p 00149000 00:01 3350        /lib/tls/libc-2.3.6.so
0ffea000-0ffee000 rwxp 00150000 00:01 3350        /lib/tls/libc-2.3.6.so
10000000-10004000 r-xp 00000000 00:01 76          /bin/sleep
10013000-10014000 rwxp 00003000 00:01 76          /bin/sleep
20000000-20018000 r-xp 00000000 00:01 3478        /lib/ld-2.3.6.so
20028000-20029000 r--p 00018000 00:01 3478        /lib/ld-2.3.6.so
20029000-2002a000 rwxp 00019000 00:01 3478        /lib/ld-2.3.6.so
2002a000-2004b000 rwxp 2002a000 00:00 0           [heap]
ffd67000-ffd7c000 rw-p ffd67000 00:00 0           [stack]

Signed-off-by: Anton Blanchard <anton@samba.org>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-01-24 21:13:56 +11:00
..
acpi ACPI: increase ACPI_MAX_REFERENCE_COUNT for larger systems 2007-01-02 00:18:52 -05:00
asm-alpha [PATCH] FD_ZERO build fix 2007-01-11 18:18:22 -08:00
asm-arm [ARM] Resolve fuse and direct-IO failures due to missing cache flushes 2007-01-08 19:49:58 +00:00
asm-arm26 [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-avr32 [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-cris [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-frv [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-generic [PATCH] change WARN_ON back to "BUG: at ..." 2006-12-30 10:55:54 -08:00
asm-h8300 [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-i386 [PATCH] x86: fix PDA variables to work during boot 2007-01-22 19:39:36 -08:00
asm-ia64 [PATCH] FD_ZERO build fix 2007-01-11 18:18:22 -08:00
asm-m32r [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-m68k [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-m68knommu [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-mips [MIPS] SMTC build fix 2007-01-08 21:41:04 +00:00
asm-parisc [ARM] pass vma for flush_anon_page() 2007-01-08 19:49:54 +00:00
asm-powerpc [POWERPC] Move ELF_ET_DYN_BASE up to 512MB point 2007-01-24 21:13:56 +11:00
asm-ppc Merge branch 'for_paulus' of master.kernel.org:/pub/scm/linux/kernel/git/galak/powerpc 2006-12-11 16:31:42 +11:00
asm-s390 [PATCH] FD_ZERO build fix 2007-01-11 18:18:22 -08:00
asm-sh [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-sh64 [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-sparc [SPARC64]: Fix of_iounmap() region release. 2006-12-31 14:06:05 -08:00
asm-sparc64 [SPARC64]: Fix of_iounmap() region release. 2006-12-31 14:06:05 -08:00
asm-um
asm-v850 [PATCH] Optimize D-cache alias handling on fork 2006-12-13 09:27:08 -08:00
asm-x86_64 [PATCH] x86-64: Use different constraint for gcc < 4.1 in bitops.h 2007-01-11 01:52:44 +01:00
asm-xtensa [PATCH] FD_ZERO build fix 2007-01-11 18:18:22 -08:00
crypto
keys
linux Merge git://git.infradead.org/mtd-2.6 2007-01-22 19:32:13 -08:00
math-emu
media V4L/DVB (5001): Add two required headers on kernel 2.6.20-rc1 2006-12-27 14:20:46 -02:00
mtd
net Merge branch 'upstream-fixes' of master.kernel.org:/pub/scm/linux/kernel/git/linville/wireless-2.6 into upstream-fixes 2007-01-07 22:44:56 -05:00
pcmcia
rdma IB: Fix ib_dma_alloc_coherent() wrapper 2006-12-15 13:57:26 -08:00
rxrpc
scsi
sound [ALSA] version 1.0.14rc1 2007-01-09 10:57:25 +01:00
video [PATCH] sstfb: add sysfs interface 2006-12-13 09:05:55 -08:00
Kbuild