aboutsummaryrefslogtreecommitdiff
path: root/sys/sparc64/include/elf.h
diff options
context:
space:
mode:
authorPeter Wemm <peter@FreeBSD.org>2003-09-25 01:10:26 +0000
committerPeter Wemm <peter@FreeBSD.org>2003-09-25 01:10:26 +0000
commitc460ac3a008c69755d500c83b58893f66b43c012 (patch)
treef89d7e04e53ed33050987a5b51945ab490d9ba4d /sys/sparc64/include/elf.h
parent26824d8c47b0f24204a2371113ff44333b51d29f (diff)
downloadsrc-c460ac3a008c69755d500c83b58893f66b43c012.tar.gz
src-c460ac3a008c69755d500c83b58893f66b43c012.zip
Add sysentvec->sv_fixlimits() hook so that we can catch cases on 64 bit
systems where the data/stack/etc limits are too big for a 32 bit process. Move the 5 or so identical instances of ELF_RTLD_ADDR() into imgact_elf.c. Supply an ia32_fixlimits function. Export the clip/default values to sysctl under the compat.ia32 heirarchy. Have mmap(0, ...) respect the current p->p_limits[RLIMIT_DATA].rlim_max value rather than the sysctl tweakable variable. This allows mmap to place mappings at sensible locations when limits have been reduced. Have the imgact_elf.c ld-elf.so.1 placement algorithm use the same method as mmap(0, ...) now does. Note that we cannot remove all references to the sysctl tweakable maxdsiz etc variables because /etc/login.conf specifies a datasize of 'unlimited'. And that causes exec etc to fail since it can no longer find space to mmap things.
Notes
Notes: svn path=/head/; revision=120422
Diffstat (limited to 'sys/sparc64/include/elf.h')
-rw-r--r--sys/sparc64/include/elf.h12
1 files changed, 0 insertions, 12 deletions
diff --git a/sys/sparc64/include/elf.h b/sys/sparc64/include/elf.h
index 5532bc912582..d4f1824fce79 100644
--- a/sys/sparc64/include/elf.h
+++ b/sys/sparc64/include/elf.h
@@ -171,16 +171,4 @@ __ElfType(Auxinfo);
#define ELF_TARG_MACH ELF_ARCH
#define ELF_TARG_VER 1
-#ifdef _KERNEL
-
-/*
- * On the Sparc64 we load the dynamic linker where a userland call
- * to mmap(0, ...) would put it. The rationale behind this
- * calculation is that it leaves room for the heap to grow to
- * its maximum allowed size.
- */
-#define ELF_RTLD_ADDR(vmspace) \
- (round_page((vm_offset_t)(vmspace)->vm_daddr + maxdsiz))
-
-#endif /* _KERNEL */
#endif /* !_MACHINE_ELF_H_ */