diff options
author | tjr <tjr@FreeBSD.org> | 2004-08-15 11:52:45 +0000 |
---|---|---|
committer | tjr <tjr@FreeBSD.org> | 2004-08-15 11:52:45 +0000 |
commit | f85b6dc63e16d9af195105647f4b165a627bf4a2 (patch) | |
tree | f7fb8c2abeda1cf8e705bff05208610214ecc03a /sys | |
parent | 2457adaca5389376180a98d2520a201e578f1d6c (diff) | |
download | FreeBSD-src-f85b6dc63e16d9af195105647f4b165a627bf4a2.zip FreeBSD-src-f85b6dc63e16d9af195105647f4b165a627bf4a2.tar.gz |
Use sv_psstrings from the current process's sysentvec structure instead
of PS_STRINGS. This is a no-op at present, but it will be needed when
running 32-bit Linux binaries on amd64 to ensure PS_STRINGS is in
addressable memory.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/compat/linux/linux_util.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/compat/linux/linux_util.h b/sys/compat/linux/linux_util.h index 72fe437..4801453 100644 --- a/sys/compat/linux/linux_util.h +++ b/sys/compat/linux/linux_util.h @@ -53,11 +53,12 @@ static __inline caddr_t stackgap_init(void); static __inline void *stackgap_alloc(caddr_t *, size_t); #define szsigcode (*(curthread->td_proc->p_sysent->sv_szsigcode)) +#define psstrings (curthread->td_proc->p_sysent->sv_psstrings) static __inline caddr_t stackgap_init() { - return (caddr_t)(PS_STRINGS - szsigcode - SPARE_USRSPACE); + return (caddr_t)(psstrings - szsigcode - SPARE_USRSPACE); } static __inline void * @@ -68,7 +69,7 @@ stackgap_alloc(sgp, sz) void *p = (void *) *sgp; sz = ALIGN(sz); - if (*sgp + sz > (caddr_t)(PS_STRINGS - szsigcode)) + if (*sgp + sz > (caddr_t)(psstrings - szsigcode)) return NULL; *sgp += sz; return p; |