summaryrefslogtreecommitdiffstats
path: root/sys/alpha/linux/linux_sysvec.c
diff options
context:
space:
mode:
authorjulian <julian@FreeBSD.org>1999-01-06 23:05:42 +0000
committerjulian <julian@FreeBSD.org>1999-01-06 23:05:42 +0000
commit4666ac50272776168d29d2c4142de771daa30381 (patch)
tree132bbd3c7ed8de9adf36dcd6258013de903e583a /sys/alpha/linux/linux_sysvec.c
parent6b0a11c013bb11bbed19aea0a563ebb393a899ef (diff)
downloadFreeBSD-src-4666ac50272776168d29d2c4142de771daa30381.zip
FreeBSD-src-4666ac50272776168d29d2c4142de771daa30381.tar.gz
Add (but don't activate) code for a special VM option to make
downward growing stacks more general. Add (but don't activate) code to use the new stack facility when running threads, (specifically the linux threads support). This allows people to use both linux compiled linuxthreads, and also the native FreeBSD linux-threads port. The code is conditional on VM_STACK. Not using this will produce the old heavily tested system. Submitted by: Richard Seaman <dick@tar.com>
Diffstat (limited to 'sys/alpha/linux/linux_sysvec.c')
-rw-r--r--sys/alpha/linux/linux_sysvec.c23
1 files changed, 3 insertions, 20 deletions
diff --git a/sys/alpha/linux/linux_sysvec.c b/sys/alpha/linux/linux_sysvec.c
index 611899c..da1d78f 100644
--- a/sys/alpha/linux/linux_sysvec.c
+++ b/sys/alpha/linux/linux_sysvec.c
@@ -25,7 +25,7 @@
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
* THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
- * $Id: linux_sysvec.c,v 1.41 1998/12/19 02:55:33 julian Exp $
+ * $Id: linux_sysvec.c,v 1.42 1998/12/19 19:05:57 sos Exp $
*/
/* XXX we use functions that might not exist. */
@@ -50,10 +50,6 @@
#include <vm/vm_prot.h>
#include <vm/vm_page.h>
#include <vm/vm_extern.h>
-#ifdef COMPAT_LINUX_THREADS
-#include <sys/lock.h> /* needed, for now, by vm_map.h */
-#include <vm/vm_map.h> /* needed, for now, for VM_STACK defines */
-#endif /* COMPAT_LINUX_THREADS */
#include <sys/exec.h>
#include <sys/kernel.h>
#include <sys/module.h>
@@ -221,24 +217,11 @@ linux_sendsig(sig_t catcher, int sig, int mask, u_long code)
* and the stack can not be grown. useracc will return FALSE
* if access is denied.
*/
-#ifdef COMPAT_LINUX_THREADS
-#ifdef USE_VM_STACK
-#ifndef USE_VM_STACK_FOR_EXEC
- if ((((caddr_t)fp > p->p_vmspace->vm_maxsaddr &&
- (caddr_t)fp < (caddr_t)USRSTACK &&
- grow(p, (int)fp) == FALSE) ||
- (((caddr_t)fp <= p->p_vmspace->vm_maxsaddr ||
- (caddr_t)fp >= (caddr_t)USRSTACK) &&
- grow_stack (p, (int)fp) == FALSE)) ||
-#else
+#ifdef VM_STACK
if ((grow_stack (p, (int)fp) == FALSE) ||
-#endif /* USE_VM_STACK_FOR_EXEC */
-#else
- if ((grow(p, (int)fp) == FALSE) ||
-#endif /* USE_VM_STACK */
#else
if ((grow(p, (int)fp) == FALSE) ||
-#endif /* COMPAT_LINUX_THREADS */
+#endif
(useracc((caddr_t)fp, sizeof (struct linux_sigframe), B_WRITE) == FALSE)) {
/*
* Process has trashed its stack; give it an illegal
OpenPOWER on IntegriCloud