summaryrefslogtreecommitdiffstats
path: root/sys/compat/ia32
diff options
context:
space:
mode:
authorpeter <peter@FreeBSD.org>2003-12-11 01:05:09 +0000
committerpeter <peter@FreeBSD.org>2003-12-11 01:05:09 +0000
commit90628de204fdfb510d2d28daf316a7988cfad80f (patch)
tree8460e4b3ec26fedf10dceba243c3a153399e4f23 /sys/compat/ia32
parent6a3f22c92823e5d15a6c77347f8607f856e4f108 (diff)
downloadFreeBSD-src-90628de204fdfb510d2d28daf316a7988cfad80f.zip
FreeBSD-src-90628de204fdfb510d2d28daf316a7988cfad80f.tar.gz
Assimilate ia64 back into the fold with the common freebsd32/ia32 code.
The split-up code is derived from the ia64 code originally. Note that I have only compile-tested this, not actually run-tested it. The ia64 side of the force is missing some significant chunks of signal delivery code.
Diffstat (limited to 'sys/compat/ia32')
-rw-r--r--sys/compat/ia32/ia32_sysvec.c8
-rw-r--r--sys/compat/ia32/ia32_util.h7
2 files changed, 13 insertions, 2 deletions
diff --git a/sys/compat/ia32/ia32_sysvec.c b/sys/compat/ia32/ia32_sysvec.c
index 9c14fc4..67b7db3 100644
--- a/sys/compat/ia32/ia32_sysvec.c
+++ b/sys/compat/ia32/ia32_sysvec.c
@@ -68,9 +68,15 @@ __FBSDID("$FreeBSD$");
#include <compat/freebsd32/freebsd32_proto.h>
#include <compat/freebsd32/freebsd32_syscall.h>
#include <compat/ia32/ia32_signal.h>
+#ifdef __amd64__
#include <machine/psl.h>
#include <machine/segments.h>
#include <machine/specialreg.h>
+#else
+#include <i386/include/psl.h>
+#include <i386/include/segments.h>
+#include <i386/include/specialreg.h>
+#endif
#include <machine/frame.h>
#include <machine/md_var.h>
#include <machine/pcb.h>
@@ -111,7 +117,7 @@ struct sysentvec ia32_freebsd_sysvec = {
elf32_coredump,
NULL,
MINSIGSTKSZ,
- PAGE_SIZE,
+ IA32_PAGE_SIZE,
0,
FREEBSD32_USRSTACK,
FREEBSD32_USRSTACK,
diff --git a/sys/compat/ia32/ia32_util.h b/sys/compat/ia32/ia32_util.h
index f6de375..a2b88cb 100644
--- a/sys/compat/ia32/ia32_util.h
+++ b/sys/compat/ia32/ia32_util.h
@@ -37,8 +37,13 @@
#include <sys/sysent.h>
#include <sys/cdefs.h>
-#define FREEBSD32_USRSTACK ((1ul << 32) - PAGE_SIZE)
+#ifdef __ia64__
+#define FREEBSD32_USRSTACK ((1ul << 32) - IA32_PAGE_SIZE * 2)
+#else
+#define FREEBSD32_USRSTACK ((1ul << 32) - IA32_PAGE_SIZE)
+#endif
+#define IA32_PAGE_SIZE 4096
#define IA32_MAXDSIZ (512*1024*1024) /* 512MB */
#define IA32_MAXSSIZ (64*1024*1024) /* 64MB */
#define IA32_MAXVMEM 0 /* Unlimited */
OpenPOWER on IntegriCloud