Module Name: src
Committed By: matt
Date: Mon Dec 14 00:47:12 UTC 2009
Modified Files:
src/sys/compat/common: Makefile.inc
src/sys/compat/irix: files.irix irix_exec.c irix_exec.h
irix_exec_elf32.c irix_fcntl.c irix_prctl.c irix_signal.c
irix_sysmp.c irix_syssgi.c irix_types.h
src/sys/compat/linux/arch/mips: linux_machdep.c
src/sys/compat/netbsd32: netbsd32.h netbsd32_exec_elf32.c netbsd32_fs.c
netbsd32_netbsd.c netbsd32_syscall.h netbsd32_syscallargs.h
netbsd32_syscalls.c netbsd32_sysent.c syscalls.master
src/sys/compat/ultrix: ultrix_flock.h ultrix_fs.c ultrix_ioctl.c
ultrix_pathname.c ultrix_tty.h
Added Files:
src/sys/compat/irix: irix_exec_elf64.c
Log Message:
Merge from matt-nb5-mips64
To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 src/sys/compat/common/Makefile.inc
cvs rdiff -u -r1.26 -r1.27 src/sys/compat/irix/files.irix
cvs rdiff -u -r1.55 -r1.56 src/sys/compat/irix/irix_exec.c
cvs rdiff -u -r1.27 -r1.28 src/sys/compat/irix/irix_exec.h \
src/sys/compat/irix/irix_fcntl.c
cvs rdiff -u -r1.15 -r1.16 src/sys/compat/irix/irix_exec_elf32.c
cvs rdiff -u -r0 -r1.2 src/sys/compat/irix/irix_exec_elf64.c
cvs rdiff -u -r1.49 -r1.50 src/sys/compat/irix/irix_prctl.c \
src/sys/compat/irix/irix_syssgi.c
cvs rdiff -u -r1.52 -r1.53 src/sys/compat/irix/irix_signal.c
cvs rdiff -u -r1.22 -r1.23 src/sys/compat/irix/irix_sysmp.c
cvs rdiff -u -r1.18 -r1.19 src/sys/compat/irix/irix_types.h
cvs rdiff -u -r1.39 -r1.40 src/sys/compat/linux/arch/mips/linux_machdep.c
cvs rdiff -u -r1.83 -r1.84 src/sys/compat/netbsd32/netbsd32.h
cvs rdiff -u -r1.30 -r1.31 src/sys/compat/netbsd32/netbsd32_exec_elf32.c
cvs rdiff -u -r1.57 -r1.58 src/sys/compat/netbsd32/netbsd32_fs.c
cvs rdiff -u -r1.162 -r1.163 src/sys/compat/netbsd32/netbsd32_netbsd.c
cvs rdiff -u -r1.88 -r1.89 src/sys/compat/netbsd32/netbsd32_syscall.h \
src/sys/compat/netbsd32/netbsd32_syscallargs.h
cvs rdiff -u -r1.87 -r1.88 src/sys/compat/netbsd32/netbsd32_syscalls.c \
src/sys/compat/netbsd32/netbsd32_sysent.c
cvs rdiff -u -r1.80 -r1.81 src/sys/compat/netbsd32/syscalls.master
cvs rdiff -u -r1.1 -r1.2 src/sys/compat/ultrix/ultrix_flock.h
cvs rdiff -u -r1.50 -r1.51 src/sys/compat/ultrix/ultrix_fs.c
cvs rdiff -u -r1.35 -r1.36 src/sys/compat/ultrix/ultrix_ioctl.c
cvs rdiff -u -r1.37 -r1.38 src/sys/compat/ultrix/ultrix_pathname.c
cvs rdiff -u -r1.2 -r1.3 src/sys/compat/ultrix/ultrix_tty.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/compat/common/Makefile.inc
diff -u src/sys/compat/common/Makefile.inc:1.19 src/sys/compat/common/Makefile.inc:1.20
--- src/sys/compat/common/Makefile.inc:1.19 Sat Nov 2 07:49:57 2002
+++ src/sys/compat/common/Makefile.inc Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile.inc,v 1.19 2002/11/02 07:49:57 perry Exp $
+# $NetBSD: Makefile.inc,v 1.20 2009/12/14 00:47:10 matt Exp $
#
# Configuration variables (default values are below):
#
@@ -41,7 +41,8 @@
LORDER=${LORDER:Q} \
TSORT=${TSORT:Q} \
RANLIB=${RANLIB:Q} \
- LD=${LD:Q} STRIP=${STRIP:Q} \
+ LD=${LD:Q} LDFLAGS=${LDFLAGS:Q} \
+ STRIP=${STRIP:Q} \
MACHINE=${MACHINE} MACHINE_ARCH=${MACHINE_ARCH:Q} \
COMPATCPPFLAGS=${CPPFLAGS:s...@^-i.@-i${compatdotd...@g:Q} \
LINTFLAGS=${KERNLINTFLAGS:Q} \
Index: src/sys/compat/irix/files.irix
diff -u src/sys/compat/irix/files.irix:1.26 src/sys/compat/irix/files.irix:1.27
--- src/sys/compat/irix/files.irix:1.26 Wed Nov 19 18:36:03 2008
+++ src/sys/compat/irix/files.irix Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-# $NetBSD: files.irix,v 1.26 2008/11/19 18:36:03 ad Exp $
+# $NetBSD: files.irix,v 1.27 2009/12/14 00:47:10 matt Exp $
#
file arch/mips/mips/irix_syscall.c compat_irix
@@ -7,6 +7,7 @@
file compat/irix/irix_errno.c compat_irix
file compat/irix/irix_exec.c compat_irix
file compat/irix/irix_exec_elf32.c compat_irix & exec_elf32
+file compat/irix/irix_exec_elf64.c compat_irix & exec_elf64
file compat/irix/irix_fcntl.c compat_irix
file compat/irix/irix_ioctl.c compat_irix
file compat/irix/irix_kmem.c compat_irix
Index: src/sys/compat/irix/irix_exec.c
diff -u src/sys/compat/irix/irix_exec.c:1.55 src/sys/compat/irix/irix_exec.c:1.56
--- src/sys/compat/irix/irix_exec.c:1.55 Thu Dec 10 14:13:53 2009
+++ src/sys/compat/irix/irix_exec.c Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: irix_exec.c,v 1.55 2009/12/10 14:13:53 matt Exp $ */
+/* $NetBSD: irix_exec.c,v 1.56 2009/12/14 00:47:10 matt Exp $ */
/*-
* Copyright (c) 2001-2002 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: irix_exec.c,v 1.55 2009/12/10 14:13:53 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: irix_exec.c,v 1.56 2009/12/14 00:47:10 matt Exp $");
#ifdef _KERNEL_OPT
#include "opt_syscall_debug.h"
@@ -124,10 +124,13 @@
void
irix_n32_setregs(struct lwp *l, struct exec_package *pack, vaddr_t stack)
{
- struct frame *f = (struct frame *)l->l_md.md_regs;
+ struct frame *f = l->l_md.md_regs;
/* Enable 64 bit instructions (eg: sd) */
- f->f_regs[_R_SR] |= MIPS3_SR_UX;
+ f->f_regs[_R_SR] |= MIPS3_SR_UX | MIPS3_SR_FR;
+#ifdef _LP64
+ f->f_regs[_R_SR] |= MIPS3_SR_KX;
+#endif
}
/*
Index: src/sys/compat/irix/irix_exec.h
diff -u src/sys/compat/irix/irix_exec.h:1.27 src/sys/compat/irix/irix_exec.h:1.28
--- src/sys/compat/irix/irix_exec.h:1.27 Thu Dec 10 14:13:53 2009
+++ src/sys/compat/irix/irix_exec.h Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: irix_exec.h,v 1.27 2009/12/10 14:13:53 matt Exp $ */
+/* $NetBSD: irix_exec.h,v 1.28 2009/12/14 00:47:10 matt Exp $ */
/*-
* Copyright (c) 2001-2002 The NetBSD Foundation, Inc.
@@ -93,7 +93,7 @@
int irix_elf64_copyargs(struct lwp *, struct exec_package *,
struct ps_strings *, char **, void *);
-int irix_elf64_probe(struct lwp *, struct exec_package *, void *,
+int irix_elf64_probe_n64(struct lwp *, struct exec_package *, void *,
char *, vaddr_t *);
#endif
Index: src/sys/compat/irix/irix_fcntl.c
diff -u src/sys/compat/irix/irix_fcntl.c:1.27 src/sys/compat/irix/irix_fcntl.c:1.28
--- src/sys/compat/irix/irix_fcntl.c:1.27 Mon Aug 31 05:34:16 2009
+++ src/sys/compat/irix/irix_fcntl.c Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: irix_fcntl.c,v 1.27 2009/08/31 05:34:16 dholland Exp $ */
+/* $NetBSD: irix_fcntl.c,v 1.28 2009/12/14 00:47:10 matt Exp $ */
/*-
* Copyright (c) 2001-2002 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: irix_fcntl.c,v 1.27 2009/08/31 05:34:16 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: irix_fcntl.c,v 1.28 2009/12/14 00:47:10 matt Exp $");
#include <sys/types.h>
#include <sys/signal.h>
Index: src/sys/compat/irix/irix_exec_elf32.c
diff -u src/sys/compat/irix/irix_exec_elf32.c:1.15 src/sys/compat/irix/irix_exec_elf32.c:1.16
--- src/sys/compat/irix/irix_exec_elf32.c:1.15 Mon Apr 28 20:23:41 2008
+++ src/sys/compat/irix/irix_exec_elf32.c Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: irix_exec_elf32.c,v 1.15 2008/04/28 20:23:41 martin Exp $ */
+/* $NetBSD: irix_exec_elf32.c,v 1.16 2009/12/14 00:47:10 matt Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -30,12 +30,14 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: irix_exec_elf32.c,v 1.15 2008/04/28 20:23:41 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: irix_exec_elf32.c,v 1.16 2009/12/14 00:47:10 matt Exp $");
#ifndef ELFSIZE
#define ELFSIZE 32 /* XXX should die */
#endif
+#include "opt_execfmt.h"
+
#include <sys/param.h>
#include <sys/types.h>
#include <sys/systm.h>
@@ -56,16 +58,13 @@
#include <compat/irix/irix_exec.h>
+#if ELFSIZE == 32
/*
* IRIX o32 ABI probe function
*/
int
-ELFNAME2(irix,probe_o32)(l, epp, eh, itp, pos)
- struct lwp *l;
- struct exec_package *epp;
- void *eh;
- char *itp;
- vaddr_t *pos;
+ELFNAME2(irix,probe_o32)(struct lwp *l, struct exec_package *epp, void *eh,
+ char *itp, vaddr_t *pos)
{
int error = 0;
@@ -90,6 +89,7 @@
printf("epp->ep_vm_minaddr = 0x%lx\n", epp->ep_vm_minaddr);
#endif
epp->ep_vm_minaddr = epp->ep_vm_minaddr & ~0xfUL;
+ l->l_proc->p_md.md_abi = _MIPS_BSD_API_O32;
return 0;
}
@@ -97,12 +97,8 @@
* IRIX n32 ABI probe function
*/
int
-ELFNAME2(irix,probe_n32)(l, epp, eh, itp, pos)
- struct lwp *l;
- struct exec_package *epp;
- void *eh;
- char *itp;
- vaddr_t *pos;
+ELFNAME2(irix,probe_n32)(struct lwp *l, struct exec_package *epp, void *eh,
+ char *itp, vaddr_t *pos)
{
int error = 0;
@@ -126,8 +122,45 @@
printf("epp->ep_vm_minaddr = 0x%lx\n", epp->ep_vm_minaddr);
#endif
epp->ep_vm_minaddr = epp->ep_vm_minaddr & ~0xfUL;
+ l->l_proc->p_md.md_abi = _MIPS_BSD_API_N32;
+ return 0;
+}
+#endif /* ELFSIZE == 32 */
+
+#if ELFSIZE == 64
+/*
+ * IRIX n64 ABI probe function
+ */
+int
+irix_elf64_probe_n64(struct lwp *l, struct exec_package *epp, void *eh,
+ char *itp, vaddr_t *pos)
+{
+ int error = 0;
+
+#ifdef DEBUG_IRIX
+ printf("irix_probe_n64()\n");
+#endif
+ if ((((Elf_Ehdr *)epp->ep_hdr)->e_flags & IRIX_EF_IRIX_ABI_MASK) !=
+ IRIX_EF_IRIX_ABI64)
+ return error;
+
+ if (itp) {
+ /* n32 binaries use /lib64/libc.so.1 */
+ if (strncmp(itp, "/lib64/libc.so", 14) &&
+ strncmp(itp, "/usr/lib64/libc.so", 18))
+ return ENOEXEC;
+ if ((error = emul_find_interp(l, epp, itp)))
+ return error;
+ }
+#ifdef DEBUG_IRIX
+ printf("irix_probe_n32: returning 0\n");
+ printf("epp->ep_vm_minaddr = 0x%lx\n", epp->ep_vm_minaddr);
+#endif
+ epp->ep_vm_minaddr = epp->ep_vm_minaddr & ~0xfUL;
+ l->l_proc->p_md.md_abi = _MIPS_BSD_API_N32;
return 0;
}
+#endif /* ELFSIZE == 64 */
int
ELFNAME2(irix,copyargs)(l, pack, arginfo, stackp, argp)
@@ -152,7 +185,7 @@
* the code that sets up the stack in copyargs():
*/
#ifdef DEBUG_IRIX
- printf("irix_elf32_copyargs(): *stackp = %p\n", *stackp);
+ printf("%s(): *stackp = %p\n", __func__, *stackp);
#endif
/*
* This is borrowed from sys/kern/kern_exec.c:copyargs()
Index: src/sys/compat/irix/irix_prctl.c
diff -u src/sys/compat/irix/irix_prctl.c:1.49 src/sys/compat/irix/irix_prctl.c:1.50
--- src/sys/compat/irix/irix_prctl.c:1.49 Wed Mar 18 16:00:16 2009
+++ src/sys/compat/irix/irix_prctl.c Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: irix_prctl.c,v 1.49 2009/03/18 16:00:16 cegger Exp $ */
+/* $NetBSD: irix_prctl.c,v 1.50 2009/12/14 00:47:10 matt Exp $ */
/*-
* Copyright (c) 2001-2002 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: irix_prctl.c,v 1.49 2009/03/18 16:00:16 cegger Exp $");
+__KERNEL_RCSID(0, "$NetBSD: irix_prctl.c,v 1.50 2009/12/14 00:47:10 matt Exp $");
#include <sys/errno.h>
#include <sys/types.h>
@@ -101,9 +101,9 @@
int shmask = 0;
struct irix_emuldata *ied;
- p2 = pfind((pid_t)SCARG(uap, arg1));
+ p2 = pfind((pid_t)(uintptr_t)SCARG(uap, arg1));
- if (p2 == p || SCARG(uap, arg1) == 0) {
+ if (p2 == p || SCARG(uap, arg1) == NULL) {
/* XXX return our own shmask */
return 0;
}
@@ -160,7 +160,7 @@
}
case IRIX_PR_ISBLOCKED: { /* Is process blocked? */
- pid_t pid = (pid_t)SCARG(uap, arg1);
+ pid_t pid = (pid_t)(uintptr_t)SCARG(uap, arg1);
struct irix_emuldata *ied;
struct proc *target;
Index: src/sys/compat/irix/irix_syssgi.c
diff -u src/sys/compat/irix/irix_syssgi.c:1.49 src/sys/compat/irix/irix_syssgi.c:1.50
--- src/sys/compat/irix/irix_syssgi.c:1.49 Sun Jan 11 20:00:06 2009
+++ src/sys/compat/irix/irix_syssgi.c Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: irix_syssgi.c,v 1.49 2009/01/11 20:00:06 rumble Exp $ */
+/* $NetBSD: irix_syssgi.c,v 1.50 2009/12/14 00:47:10 matt Exp $ */
/*-
* Copyright (c) 2001, 2002, 2008 The NetBSD Foundation, Inc.
@@ -30,15 +30,19 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: irix_syssgi.c,v 1.49 2009/01/11 20:00:06 rumble Exp $");
+__KERNEL_RCSID(0, "$NetBSD: irix_syssgi.c,v 1.50 2009/12/14 00:47:10 matt Exp $");
#if defined(_KERNEL_OPT)
#include "opt_ddb.h"
#endif
#ifndef ELFSIZE
+#ifdef _LP64
+#define ELFSIZE 64
+#else
#define ELFSIZE 32
#endif
+#endif
/* round up and down to page boundaries. Borrowed from sys/kern/exec_elf32.c */
#define ELF_ROUND(a, b) (((a) + (b) - 1) & ~((b) - 1))
@@ -109,7 +113,7 @@
case IRIX_SGI_SETGROUPS: { /* setgroups(2) */
struct sys_setgroups_args cup;
- SCARG(&cup, gidsetsize) = (int)SCARG(uap, arg1);
+ SCARG(&cup, gidsetsize) = (intptr_t)SCARG(uap, arg1);
SCARG(&cup, gidset) = (gid_t *)SCARG(uap, arg2);
return (sys_setgroups(l, &cup, retval));
break;
@@ -118,7 +122,7 @@
case IRIX_SGI_GETGROUPS: { /* getgroups(2) */
struct sys_getgroups_args cup;
- SCARG(&cup, gidsetsize) = (int)SCARG(uap, arg1);
+ SCARG(&cup, gidsetsize) = (intptr_t)SCARG(uap, arg1);
SCARG(&cup, gidset) = (gid_t *)SCARG(uap, arg2);
return (sys_getgroups(l, &cup, retval));
break;
@@ -131,7 +135,7 @@
case IRIX_SGI_GETSID: { /* Get session ID: getsid(2) */
struct sys_getsid_args cup;
- SCARG(&cup, pid) = (pid_t)SCARG(uap, arg1);
+ SCARG(&cup, pid) = (pid_t)(intptr_t)SCARG(uap, arg1);
return (sys_getsid(l, &cup, retval));
break;
}
@@ -139,7 +143,7 @@
case IRIX_SGI_GETPGID: {/* Get parent process GID: getpgid(2) */
struct sys_getpgid_args cup;
- SCARG(&cup, pid) = (pid_t)SCARG(uap, arg1);
+ SCARG(&cup, pid) = (pid_t)(intptr_t)SCARG(uap, arg1);
return (sys_getpgid(l, &cup, retval));
break;
}
@@ -147,24 +151,23 @@
case IRIX_SGI_SETPGID: {/* Get parent process GID: setpgid(2) */
struct sys_setpgid_args cup;
- SCARG(&cup, pid) = (pid_t)SCARG(uap, arg1);
- SCARG(&cup, pgid) = (pid_t)SCARG(uap, arg2);
+ SCARG(&cup, pid) = (pid_t)(intptr_t)SCARG(uap, arg1);
+ SCARG(&cup, pgid) = (pid_t)(intptr_t)SCARG(uap, arg2);
return (sys_setpgid(l, &cup, retval));
break;
}
case IRIX_SGI_PATHCONF: /* Get file limits: pathconf(3) */
return irix_syssgi_pathconf((char *)SCARG(uap, arg1),
- (int)SCARG(uap, arg2), l, retval);
+ (intptr_t)SCARG(uap, arg2), l, retval);
break;
case IRIX_SGI_RUSAGE: { /* BSD getrusage(2) */
struct compat_50_sys_getrusage_args cup;
- SCARG(&cup, who) = (int)SCARG(uap, arg1);
+ SCARG(&cup, who) = (intptr_t)SCARG(uap, arg1);
SCARG(&cup, rusage) = (struct rusage50 *)SCARG(uap, arg2);
return compat_50_sys_getrusage(l, &cup, retval);
- break;
}
case IRIX_SGI_NUM_MODULES: /* <sys/systeminfo.h> get_num_modules() */
@@ -173,9 +176,9 @@
break;
case IRIX_SGI_MODULE_INFO: { /* <sys/systeminfo.h> get_module_info() */
- int module_num = (int)SCARG(uap, arg1);
+ int module_num = (intptr_t)SCARG(uap, arg1);
struct irix_module_info_s *imip = SCARG(uap, arg2);
- int mss = (int)SCARG(uap, arg3);
+ int mss = (intptr_t)SCARG(uap, arg3);
struct irix_module_info_s imi;
char *idx;
@@ -206,7 +209,7 @@
arg1 = SCARG(uap, arg1); /* PID of the process */
arg2 = SCARG(uap, arg2); /* Address of user buffer */
arg3 = SCARG(uap, arg3); /* Length of user buffer */
- tp = pfind((pid_t)arg1);
+ tp = pfind((pid_t)(intptr_t)arg1);
if (tp == NULL || \
tp->p_psstr == NULL || \
tp->p_psstr->ps_argvstr == NULL || \
@@ -231,8 +234,8 @@
arg1 = SCARG(uap, arg1); /* file descriptor */
arg2 = SCARG(uap, arg2); /* ptr to ELF program header array */
arg3 = SCARG(uap, arg3); /* array's length */
- return irix_syssgi_mapelf((int)arg1, (Elf_Phdr *)arg2,
- (int)arg3, l, retval);
+ return irix_syssgi_mapelf((intptr_t)arg1, (Elf_Phdr *)arg2,
+ (intptr_t)arg3, l, retval);
break;
case IRIX_SGI_USE_FP_BCOPY: /* bcopy and bzero can use FPU or not */
@@ -250,7 +253,7 @@
case IRIX_SGI_SYSCONF: /* POSIX sysconf */
arg1 = SCARG(uap, arg1); /* system variable name */
- return irix_syssgi_sysconf((int)arg1, l, retval);
+ return irix_syssgi_sysconf((intptr_t)arg1, l, retval);
break;
case IRIX_SGI_SATCTL: /* control audit stream */
Index: src/sys/compat/irix/irix_signal.c
diff -u src/sys/compat/irix/irix_signal.c:1.52 src/sys/compat/irix/irix_signal.c:1.53
--- src/sys/compat/irix/irix_signal.c:1.52 Mon Nov 23 00:46:06 2009
+++ src/sys/compat/irix/irix_signal.c Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: irix_signal.c,v 1.52 2009/11/23 00:46:06 rmind Exp $ */
+/* $NetBSD: irix_signal.c,v 1.53 2009/12/14 00:47:10 matt Exp $ */
/*-
* Copyright (c) 1994, 2001-2002 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: irix_signal.c,v 1.52 2009/11/23 00:46:06 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: irix_signal.c,v 1.53 2009/12/14 00:47:10 matt Exp $");
#include <sys/types.h>
#include <sys/signal.h>
@@ -140,7 +140,7 @@
}
isi->isi_signo = native_to_svr4_signo[sig];
isi->isi_errno = 0;
- isi->isi_addr = (irix_app32_ptr_t)addr;
+ isi->isi_addr = (intptr_t)addr;
switch (code) {
case T_TLB_MOD:
@@ -244,20 +244,19 @@
struct lwp *l = curlwp;
struct proc *p = l->l_proc;
void *sp;
- struct frame *f;
+ struct frame *f = l->l_md.md_regs;
int onstack;
int error;
sig_t catcher = SIGACTION(p, ksi->ksi_signo).sa_handler;
struct irix_sigframe sf;
- f = (struct frame *)l->l_md.md_regs;
#ifdef DEBUG_IRIX
printf("irix_sendsig()\n");
printf("catcher = %p, sig = %d, code = 0x%x\n",
(void *)catcher, ksi->ksi_signo, ksi->ksi_trap);
- printf("irix_sendsig(): starting [PC=%p SP=%p SR=0x%08lx]\n",
- (void *)f->f_regs[_R_PC], (void *)f->f_regs[_R_SP],
- f->f_regs[_R_SR]);
+ printf("irix_sendsig(): starting [PC=0x%#"PRIxREGISTER
+ " SP=%#"PRIxREGISTER" SR=0x%08lx]\n",
+ f->f_regs[_R_PC], f->f_regs[_R_SP], f->f_regs[_R_SR]);
#endif /* DEBUG_IRIX */
/*
@@ -277,8 +276,8 @@
sp = (void *)((char *)l->l_sigstk.ss_sp
+ l->l_sigstk.ss_size);
else
- /* cast for _MIPS_BSD_API == _MIPS_BSD_API_LP32_64CLEAN case */
- sp = (void *)(u_int32_t)f->f_regs[_R_SP];
+ /* cast for O64 case */
+ sp = (void *)(intptr_t)f->f_regs[_R_SP];
/*
* Build the signal frame
@@ -295,8 +294,8 @@
/*
* Compute the new stack address after copying sigframe
*/
- sp = (void *)((unsigned long)sp - sizeof(sf.isf_ctx));
- sp = (void *)((unsigned long)sp & ~0xfUL); /* 16 bytes alignement */
+ sp = (void *)((intptr_t)sp - sizeof(sf.isf_ctx));
+ sp = (void *)((intptr_t)sp & ~0xfUL); /* 16 bytes alignement */
/*
* Install the sigframe onto the stack
@@ -324,8 +323,8 @@
*/
f->f_regs[_R_A0] = native_to_svr4_signo[ksi->ksi_signo];/* signo */
f->f_regs[_R_A1] = 0; /* NULL */
- f->f_regs[_R_A2] = (unsigned long)sp; /* ucontext/sigcontext */
- f->f_regs[_R_A3] = (unsigned long)catcher;/* signal handler address */
+ f->f_regs[_R_A2] = (intptr_t)sp; /* ucontext/sigcontext */
+ f->f_regs[_R_A3] = (intptr_t)catcher; /* signal handler address */
/*
* When siginfo is selected, the higher bit of A0 is set
@@ -335,14 +334,14 @@
*/
if (SIGACTION(p, ksi->ksi_signo).sa_flags & SA_SIGINFO) {
f->f_regs[_R_A0] |= 0x80000000;
- f->f_regs[_R_A1] = (u_long)sp +
- ((u_long)&sf.isf_ctx.iss.iis - (u_long)&sf);
+ f->f_regs[_R_A1] = (intptr_t)sp +
+ ((intptr_t)&sf.isf_ctx.iss.iis - (intptr_t)&sf);
}
/*
* Set up the new stack pointer
*/
- f->f_regs[_R_SP] = (unsigned long)sp;
+ f->f_regs[_R_SP] = (intptr_t)sp;
#ifdef DEBUG_IRIX
printf("stack pointer at %p, A1 = %p\n", sp, (void *)f->f_regs[_R_A1]);
#endif /* DEBUG_IRIX */
@@ -353,7 +352,7 @@
* see irix_sys_sigaction for details about how we get
* the signal trampoline address.
*/
- f->f_regs[_R_PC] = (unsigned long)
+ f->f_regs[_R_PC] = (intptr_t)
(((struct irix_emuldata *)(p->p_emuldata))->ied_sigtramp[ksi->ksi_signo]);
/*
@@ -365,7 +364,6 @@
#ifdef DEBUG_IRIX
printf("returning from irix_sendsig()\n");
#endif
- return;
}
static void
@@ -391,7 +389,7 @@
}
scp->isc_regs[0] = 0;
scp->isc_fp_rounded_result = 0;
- scp->isc_regmask = ~0x1UL;
+ scp->isc_regmask = -2;
scp->isc_mdhi = f->f_regs[_R_MULHI];
scp->isc_mdlo = f->f_regs[_R_MULLO];
scp->isc_pc = f->f_regs[_R_PC];
Index: src/sys/compat/irix/irix_sysmp.c
diff -u src/sys/compat/irix/irix_sysmp.c:1.22 src/sys/compat/irix/irix_sysmp.c:1.23
--- src/sys/compat/irix/irix_sysmp.c:1.22 Sat Nov 28 20:09:56 2009
+++ src/sys/compat/irix/irix_sysmp.c Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: irix_sysmp.c,v 1.22 2009/11/28 20:09:56 dsl Exp $ */
+/* $NetBSD: irix_sysmp.c,v 1.23 2009/12/14 00:47:10 matt Exp $ */
/*-
* Copyright (c) 2001-2002 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: irix_sysmp.c,v 1.22 2009/11/28 20:09:56 dsl Exp $");
+__KERNEL_RCSID(0, "$NetBSD: irix_sysmp.c,v 1.23 2009/12/14 00:47:10 matt Exp $");
#include <sys/errno.h>
#include <sys/param.h>
@@ -89,16 +89,16 @@
break;
case IRIX_MP_KERNADDR: /* Kernel structure addresses */
- return irix_sysmp_kernaddr((int)SCARG(uap, arg1), retval);
+ return irix_sysmp_kernaddr((intptr_t)SCARG(uap, arg1), retval);
break;
case IRIX_MP_SASZ: /* System accounting structure size */
- return irix_sysmp_sasz((int)SCARG(uap, arg1), retval);
+ return irix_sysmp_sasz((intptr_t)SCARG(uap, arg1), retval);
break;
case IRIX_MP_SAGET1: /* Get system accounting structure for one CPU */
case IRIX_MP_SAGET: /* Get system accounting structure for all CPU */
- return irix_sysmp_saget((int)SCARG(uap, arg1),
+ return irix_sysmp_saget((intptr_t)SCARG(uap, arg1),
(char *)SCARG(uap, arg2), (size_t)SCARG(uap, arg3));
break;
Index: src/sys/compat/irix/irix_types.h
diff -u src/sys/compat/irix/irix_types.h:1.18 src/sys/compat/irix/irix_types.h:1.19
--- src/sys/compat/irix/irix_types.h:1.18 Mon Apr 28 20:23:42 2008
+++ src/sys/compat/irix/irix_types.h Mon Dec 14 00:47:10 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: irix_types.h,v 1.18 2008/04/28 20:23:42 martin Exp $ */
+/* $NetBSD: irix_types.h,v 1.19 2009/12/14 00:47:10 matt Exp $ */
/*-
* Copyright (c) 2001 The NetBSD Foundation, Inc.
@@ -57,7 +57,7 @@
typedef __uint32_t irix_app32_ptr_t;
typedef __uint64_t irix_k_sigset_t;
-#if 1 /* _MIPS_SZLONG == 32 */
+#if _MIPS_SZLONG == 32
typedef unsigned long irix_mode_t;
typedef unsigned long irix_dev_t;
typedef long irix_uid_t;
@@ -65,17 +65,17 @@
typedef unsigned long irix_nlink_t;
typedef long irix_pid_t;
typedef long irix_time_t;
-typedef unsigned int irix_size_t;
+typedef unsigned long irix_size_t;
#endif
-#if 0 /* _MIPS_SZLONG == 64 */
+#if _MIPS_SZLONG == 64
typedef __uint32_t irix_dev_t;
typedef __uint32_t irix_mode_t;
typedef __int32_t irix_uid_t;
typedef __int32_t irix_gid_t;
typedef __uint32_t irix_nlink_t;
typedef __int32_t irix_pid_t;
-typedef int irix_time_t;
-typedef unsigned long irix_size_t;
+typedef __int32_t irix_time_t;
+typedef __uint32_t irix_size_t;
#endif
typedef __int32_t irix_blkcnt_t;
typedef __uint64_t irix_ino64_t;
@@ -107,46 +107,46 @@
#define IRIX__STAT64_VER 3
struct irix_stat {
irix_dev_t ist_dev;
- long ist_pad1[3];
+ __uint32_t ist_pad1[3];
irix_ino_t ist_ino;
irix_mode_t ist_mode;
irix_nlink_t ist_nlink;
irix_uid_t ist_uid;
irix_gid_t ist_gid;
irix_dev_t ist_rdev;
- long ist_pad2[2];
+ __uint32_t ist_pad2[2];
irix_off_t ist_size;
- long ist_pad3;
+ __uint32_t ist_pad3;
irix_timespec_t ist_atim;
irix_timespec_t ist_mtim;
irix_timespec_t ist_ctim;
- long ist_blksize;
+ __int32_t ist_blksize;
irix_blkcnt_t ist_blocks;
char ist_fstype[16];
- long ist_projid;
- long ist_pad4[7];
+ __int32_t ist_projid;
+ __uint32_t ist_pad4[7];
};
struct irix_stat64 {
irix_dev_t ist_dev;
- long ist_pad1[3];
+ __uint32_t ist_pad1[3];
irix_ino64_t ist_ino;
irix_mode_t ist_mode;
irix_nlink_t ist_nlink;
irix_uid_t ist_uid;
irix_gid_t ist_gid;
irix_dev_t ist_rdev;
- long ist_pad2[2];
+ __uint32_t ist_pad2[2];
irix_off64_t ist_size;
- long ist_pad3;
+ __uint32_t ist_pad3;
irix_timespec_t ist_atim;
irix_timespec_t ist_mtim;
irix_timespec_t ist_ctim;
- long ist_blksize;
+ __int32_t ist_blksize;
irix_blkcnt64_t ist_blocks;
char ist_fstype[16];
- long ist_projid;
- long ist_pad4[7];
+ __int32_t ist_projid;
+ __uint32_t ist_pad4[7];
};
/* From IRIX's <sys/mount.h> */
Index: src/sys/compat/linux/arch/mips/linux_machdep.c
diff -u src/sys/compat/linux/arch/mips/linux_machdep.c:1.39 src/sys/compat/linux/arch/mips/linux_machdep.c:1.40
--- src/sys/compat/linux/arch/mips/linux_machdep.c:1.39 Mon Nov 23 00:46:07 2009
+++ src/sys/compat/linux/arch/mips/linux_machdep.c Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: linux_machdep.c,v 1.39 2009/11/23 00:46:07 rmind Exp $ */
+/* $NetBSD: linux_machdep.c,v 1.40 2009/12/14 00:47:11 matt Exp $ */
/*-
* Copyright (c) 1995, 2000, 2001 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_machdep.c,v 1.39 2009/11/23 00:46:07 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_machdep.c,v 1.40 2009/12/14 00:47:11 matt Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -144,11 +144,11 @@
*/
if (onstack)
fp = (struct linux_sigframe *)
- ((uint8_t *)l->l_sigstk.ss_sp
+ ((uintptr_t)l->l_sigstk.ss_sp
+ l->l_sigstk.ss_size);
else
- /* cast for _MIPS_BSD_API == _MIPS_BSD_API_LP32_64CLEAN case */
- fp = (struct linux_sigframe *)(u_int32_t)f->f_regs[_R_SP];
+ /* cast for O64 ABI case */
+ fp = (struct linux_sigframe *)(uintptr_t)f->f_regs[_R_SP];
/*
* Build stack frame for signal trampoline.
Index: src/sys/compat/netbsd32/netbsd32.h
diff -u src/sys/compat/netbsd32/netbsd32.h:1.83 src/sys/compat/netbsd32/netbsd32.h:1.84
--- src/sys/compat/netbsd32/netbsd32.h:1.83 Sat Dec 12 10:32:26 2009
+++ src/sys/compat/netbsd32/netbsd32.h Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: netbsd32.h,v 1.83 2009/12/12 10:32:26 njoly Exp $ */
+/* $NetBSD: netbsd32.h,v 1.84 2009/12/14 00:47:11 matt Exp $ */
/*
* Copyright (c) 1998, 2001, 2008 Matthew R. Green
@@ -44,6 +44,7 @@
#include <sys/ipc.h>
#include <sys/shm.h>
#include <sys/ucontext.h>
+#include <sys/ucred.h>
#include <compat/sys/ucontext.h>
#include <compat/sys/mount.h>
@@ -252,6 +253,17 @@
char f_mntfromname[MNAMELEN]; /* mounted file system */
};
+struct netbsd32_export_args30 {
+ int ex_flags; /* export related flags */
+ uid_t ex_root; /* mapping for root uid */
+ struct uucred ex_anon; /* mapping for anonymous user */
+ netbsd32_pointer_t ex_addr; /* net address to which exported */
+ int ex_addrlen; /* and the net address length */
+ netbsd32_pointer_t ex_mask; /* mask of valid bits in saddr */
+ int ex_masklen; /* and the smask length */
+ netbsd32_charp ex_indexfile; /* index file for WebNFS URLs */
+};
+
/* from <sys/poll.h> */
typedef netbsd32_pointer_t netbsd32_pollfdp_t;
@@ -813,6 +825,25 @@
typedef netbsd32_pointer_t netbsd32_sched_paramp_t;
typedef netbsd32_pointer_t netbsd32_cpusetp_t;
+/* from <fs/cd9660/cd9660_mount.h> */
+struct netbsd32_iso_args {
+ netbsd32_charp fspec;
+ struct export_args30 _pad1;
+ int flags;
+};
+
+/* from <ufs/ufs/ufs_mount.h> */
+struct netbsd32_ufs_args {
+ netbsd32_charp fspec;
+};
+
+struct netbsd32_mfs_args {
+ netbsd32_charp fspec;
+ struct netbsd32_export_args30 _pad1;
+ netbsd32_voidp base;
+ netbsd32_u_long size;
+};
+
#if 0
int netbsd32_kevent(struct lwp *, void *, register_t *);
#endif
Index: src/sys/compat/netbsd32/netbsd32_exec_elf32.c
diff -u src/sys/compat/netbsd32/netbsd32_exec_elf32.c:1.30 src/sys/compat/netbsd32/netbsd32_exec_elf32.c:1.31
--- src/sys/compat/netbsd32/netbsd32_exec_elf32.c:1.30 Mon Jun 29 05:08:16 2009
+++ src/sys/compat/netbsd32/netbsd32_exec_elf32.c Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: netbsd32_exec_elf32.c,v 1.30 2009/06/29 05:08:16 dholland Exp $ */
+/* $NetBSD: netbsd32_exec_elf32.c,v 1.31 2009/12/14 00:47:11 matt Exp $ */
/* from: NetBSD: exec_aout.c,v 1.15 1996/09/26 23:34:46 cgd Exp */
/*
@@ -57,7 +57,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: netbsd32_exec_elf32.c,v 1.30 2009/06/29 05:08:16 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: netbsd32_exec_elf32.c,v 1.31 2009/12/14 00:47:11 matt Exp $");
#define ELFSIZE 32
@@ -77,7 +77,6 @@
#include <compat/netbsd32/netbsd32.h>
#include <compat/netbsd32/netbsd32_exec.h>
-#include <machine/frame.h>
#include <machine/netbsd32_machdep.h>
int netbsd32_copyinargs(struct exec_package *, struct ps_strings *,
@@ -96,6 +95,13 @@
if ((error = ELFNAME2(netbsd,signature)(l, epp, eh)) != 0)
return error;
+#ifdef ELF_MD_PROBE_FUNC
+ if ((error = ELF_MD_PROBE_FUNC(l, epp, eh, itp, pos)) != 0)
+ return error;
+#elif defined(ELF_INTERP_NON_RELOCATABLE)
+ *pos = ELF_LINK_ADDR;
+#endif
+
return ELFNAME2(netbsd32,probe_noteless)(l, epp, eh, itp, pos);
}
Index: src/sys/compat/netbsd32/netbsd32_fs.c
diff -u src/sys/compat/netbsd32/netbsd32_fs.c:1.57 src/sys/compat/netbsd32/netbsd32_fs.c:1.58
--- src/sys/compat/netbsd32/netbsd32_fs.c:1.57 Mon Jan 26 13:00:05 2009
+++ src/sys/compat/netbsd32/netbsd32_fs.c Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: netbsd32_fs.c,v 1.57 2009/01/26 13:00:05 njoly Exp $ */
+/* $NetBSD: netbsd32_fs.c,v 1.58 2009/12/14 00:47:11 matt Exp $ */
/*
* Copyright (c) 1998, 2001 Matthew R. Green
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: netbsd32_fs.c,v 1.57 2009/01/26 13:00:05 njoly Exp $");
+__KERNEL_RCSID(0, "$NetBSD: netbsd32_fs.c,v 1.58 2009/12/14 00:47:11 matt Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -50,6 +50,9 @@
#include <sys/kauth.h>
#include <sys/vfs_syscalls.h>
+#include <fs/cd9660/cd9660_mount.h>
+#include <ufs/ufs/ufsmount.h>
+
#include <compat/netbsd32/netbsd32.h>
#include <compat/netbsd32/netbsd32_syscallargs.h>
#include <compat/netbsd32/netbsd32_conv.h>
@@ -751,3 +754,130 @@
free(path, M_TEMP);
return error;
}
+
+int
+netbsd32___mount50(struct lwp *l, const struct netbsd32___mount50_args *uap,
+ register_t *retval)
+{
+ /* {
+ syscallarg(netbsd32_charp) type;
+ syscallarg(netbsd32_charp) path;
+ syscallarg(int) flags;
+ syscallarg(netbsd32_voidp) data;
+ syscallarg(netbsd32_size_t) data_len;
+ } */
+ char mtype[MNAMELEN];
+ union {
+ struct netbsd32_ufs_args ufs_args;
+ struct netbsd32_mfs_args mfs_args;
+ struct netbsd32_iso_args iso_args;
+ } fs_args32;
+ union {
+ struct ufs_args ufs_args;
+ struct mfs_args mfs_args;
+ struct iso_args iso_args;
+ } fs_args;
+ const char *type = SCARG_P32(uap, type);
+ const char *path = SCARG_P32(uap, path);
+ int flags = SCARG(uap, flags);
+ void *data = SCARG_P32(uap, data);
+ size_t data_len = SCARG(uap, data_len);
+ enum uio_seg data_seg;
+ size_t len;
+ int error;
+
+ error = copyinstr(type, mtype, sizeof(mtype), &len);
+ if (error)
+ return error;
+ if (strcmp(mtype, MOUNT_MFS) == 0) {
+ if (data_len != sizeof(fs_args32.mfs_args))
+ return EINVAL;
+ if ((flags & MNT_GETARGS) == 0) {
+ error = copyin(data, &fs_args32.mfs_args,
+ sizeof(fs_args32.mfs_args));
+ if (error)
+ return error;
+ fs_args.mfs_args.fspec =
+ NETBSD32PTR64(fs_args32.mfs_args.fspec);
+ memset(&fs_args.mfs_args._pad1, 0,
+ sizeof(fs_args.mfs_args._pad1));
+ fs_args.mfs_args.base =
+ NETBSD32PTR64(fs_args32.mfs_args.base);
+ fs_args.mfs_args.size = fs_args32.mfs_args.size;
+ }
+ data_seg = UIO_SYSSPACE;
+ data = &fs_args.mfs_args;
+ data_len = sizeof(fs_args.mfs_args);
+ } else if (strcmp(mtype, MOUNT_UFS) == 0) {
+ if (data_len > sizeof(fs_args32.ufs_args))
+ return EINVAL;
+ if ((flags & MNT_GETARGS) == 0) {
+ error = copyin(data, &fs_args32.ufs_args,
+ sizeof(fs_args32.ufs_args));
+ if (error)
+ return error;
+ fs_args.ufs_args.fspec =
+ NETBSD32PTR64(fs_args32.ufs_args.fspec);
+ }
+ data_seg = UIO_SYSSPACE;
+ data = &fs_args.ufs_args;
+ data_len = sizeof(fs_args.ufs_args);
+ } else if (strcmp(mtype, MOUNT_CD9660) == 0) {
+ if (data_len != sizeof(fs_args32.iso_args))
+ return EINVAL;
+ if ((flags & MNT_GETARGS) == 0) {
+ error = copyin(data, &fs_args32.iso_args,
+ sizeof(fs_args32.iso_args));
+ if (error)
+ return error;
+ fs_args.iso_args.fspec =
+ NETBSD32PTR64(fs_args32.iso_args.fspec);
+ memset(&fs_args.iso_args._pad1, 0,
+ sizeof(fs_args.iso_args._pad1));
+ fs_args.iso_args.flags = fs_args32.iso_args.flags;
+ }
+ data_seg = UIO_SYSSPACE;
+ data = &fs_args.iso_args;
+ data_len = sizeof(fs_args.iso_args);
+ } else {
+ data_seg = UIO_USERSPACE;
+ }
+ error = do_sys_mount(l, NULL, type, path, flags, data, data_seg,
+ data_len, retval);
+ if (error)
+ return error;
+ if (flags & MNT_GETARGS) {
+ data_len = *retval;
+ if (strcmp(mtype, MOUNT_MFS) == 0) {
+ if (data_len != sizeof(fs_args.mfs_args))
+ return EINVAL;
+ NETBSD32PTR32(fs_args32.mfs_args.fspec,
+ fs_args.mfs_args.fspec);
+ memset(&fs_args32.mfs_args._pad1, 0,
+ sizeof(fs_args32.mfs_args._pad1));
+ NETBSD32PTR32(fs_args32.mfs_args.base,
+ fs_args.mfs_args.base);
+ fs_args32.mfs_args.size = fs_args.mfs_args.size;
+ error = copyout(&fs_args32.mfs_args, data,
+ sizeof(fs_args32.mfs_args));
+ } else if (strcmp(mtype, MOUNT_UFS) == 0) {
+ if (data_len != sizeof(fs_args.ufs_args))
+ return EINVAL;
+ NETBSD32PTR32(fs_args32.ufs_args.fspec,
+ fs_args.ufs_args.fspec);
+ error = copyout(&fs_args32.ufs_args, data,
+ sizeof(fs_args32.ufs_args));
+ } else if (strcmp(mtype, MOUNT_CD9660) == 0) {
+ if (data_len != sizeof(fs_args.iso_args))
+ return EINVAL;
+ NETBSD32PTR32(fs_args32.iso_args.fspec,
+ fs_args.iso_args.fspec);
+ memset(&fs_args32.iso_args._pad1, 0,
+ sizeof(fs_args32.iso_args._pad1));
+ fs_args32.iso_args.flags = fs_args.iso_args.flags;
+ error = copyout(&fs_args32.iso_args, data,
+ sizeof(fs_args32.iso_args));
+ }
+ }
+ return error;
+}
Index: src/sys/compat/netbsd32/netbsd32_netbsd.c
diff -u src/sys/compat/netbsd32/netbsd32_netbsd.c:1.162 src/sys/compat/netbsd32/netbsd32_netbsd.c:1.163
--- src/sys/compat/netbsd32/netbsd32_netbsd.c:1.162 Sat Dec 12 10:30:09 2009
+++ src/sys/compat/netbsd32/netbsd32_netbsd.c Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: netbsd32_netbsd.c,v 1.162 2009/12/12 10:30:09 njoly Exp $ */
+/* $NetBSD: netbsd32_netbsd.c,v 1.163 2009/12/14 00:47:11 matt Exp $ */
/*
* Copyright (c) 1998, 2001, 2008 Matthew R. Green
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: netbsd32_netbsd.c,v 1.162 2009/12/12 10:30:09 njoly Exp $");
+__KERNEL_RCSID(0, "$NetBSD: netbsd32_netbsd.c,v 1.163 2009/12/14 00:47:11 matt Exp $");
#if defined(_KERNEL_OPT)
#include "opt_ddb.h"
@@ -92,8 +92,6 @@
#include <compat/netbsd32/netbsd32_conv.h>
#include <compat/netbsd32/netbsd32_sa.h>
-#include <machine/frame.h>
-
#if defined(DDB)
#include <ddb/ddbvar.h>
#endif
Index: src/sys/compat/netbsd32/netbsd32_syscall.h
diff -u src/sys/compat/netbsd32/netbsd32_syscall.h:1.88 src/sys/compat/netbsd32/netbsd32_syscall.h:1.89
--- src/sys/compat/netbsd32/netbsd32_syscall.h:1.88 Sun May 17 05:55:42 2009
+++ src/sys/compat/netbsd32/netbsd32_syscall.h Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: netbsd32_syscall.h,v 1.88 2009/05/17 05:55:42 pooka Exp $ */
+/* $NetBSD: netbsd32_syscall.h,v 1.89 2009/12/14 00:47:11 matt Exp $ */
/*
* System call numbers.
@@ -1095,6 +1095,9 @@
/* syscall: "compat_50_netbsd32___fhstat40" ret: "int" args: "netbsd32_pointer_t" "netbsd32_size_t" "netbsd32_stat50p_t" */
#define NETBSD32_SYS_compat_50_netbsd32___fhstat40 398
+/* syscall: "netbsd32___mount50" ret: "int" args: "netbsd32_charp" "netbsd32_charp" "int" "netbsd32_voidp" "netbsd32_size_t" */
+#define NETBSD32_SYS_netbsd32___mount50 410
+
/* syscall: "netbsd32_mremap" ret: "netbsd32_voidp" args: "netbsd32_voidp" "netbsd32_size_t" "netbsd32_voidp" "netbsd32_size_t" "int" */
#define NETBSD32_SYS_netbsd32_mremap 411
Index: src/sys/compat/netbsd32/netbsd32_syscallargs.h
diff -u src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.88 src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.89
--- src/sys/compat/netbsd32/netbsd32_syscallargs.h:1.88 Sun May 17 05:55:42 2009
+++ src/sys/compat/netbsd32/netbsd32_syscallargs.h Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: netbsd32_syscallargs.h,v 1.88 2009/05/17 05:55:42 pooka Exp $ */
+/* $NetBSD: netbsd32_syscallargs.h,v 1.89 2009/12/14 00:47:11 matt Exp $ */
/*
* System call argument lists.
@@ -2087,6 +2087,15 @@
};
check_syscall_args(compat_50_netbsd32___fhstat40)
+struct netbsd32___mount50_args {
+ syscallarg(netbsd32_charp) type;
+ syscallarg(netbsd32_charp) path;
+ syscallarg(int) flags;
+ syscallarg(netbsd32_voidp) data;
+ syscallarg(netbsd32_size_t) data_len;
+};
+check_syscall_args(netbsd32___mount50)
+
struct netbsd32_mremap_args {
syscallarg(netbsd32_voidp) old_address;
syscallarg(netbsd32_size_t) old_size;
@@ -3047,6 +3056,8 @@
int compat_50_netbsd32___fhstat40(struct lwp *, const struct compat_50_netbsd32___fhstat40_args *, register_t *);
+int netbsd32___mount50(struct lwp *, const struct netbsd32___mount50_args *, register_t *);
+
int netbsd32_mremap(struct lwp *, const struct netbsd32_mremap_args *, register_t *);
int netbsd32___posix_fadvise50(struct lwp *, const struct netbsd32___posix_fadvise50_args *, register_t *);
Index: src/sys/compat/netbsd32/netbsd32_syscalls.c
diff -u src/sys/compat/netbsd32/netbsd32_syscalls.c:1.87 src/sys/compat/netbsd32/netbsd32_syscalls.c:1.88
--- src/sys/compat/netbsd32/netbsd32_syscalls.c:1.87 Sun May 17 05:55:42 2009
+++ src/sys/compat/netbsd32/netbsd32_syscalls.c Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: netbsd32_syscalls.c,v 1.87 2009/05/17 05:55:42 pooka Exp $ */
+/* $NetBSD: netbsd32_syscalls.c,v 1.88 2009/12/14 00:47:11 matt Exp $ */
/*
* System call names.
@@ -8,7 +8,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.87 2009/05/17 05:55:42 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: netbsd32_syscalls.c,v 1.88 2009/12/14 00:47:11 matt Exp $");
#if defined(_KERNEL_OPT)
#if defined(_KERNEL_OPT)
@@ -514,7 +514,7 @@
/* 407 */ "#407 (unimplemented)",
/* 408 */ "#408 (unimplemented)",
/* 409 */ "#409 (unimplemented)",
- /* 410 */ "#410 (unimplemented sys___mount50)",
+ /* 410 */ "netbsd32___mount50",
/* 411 */ "netbsd32_mremap",
/* 412 */ "#412 (unimplemented)",
/* 413 */ "#413 (unimplemented)",
Index: src/sys/compat/netbsd32/netbsd32_sysent.c
diff -u src/sys/compat/netbsd32/netbsd32_sysent.c:1.87 src/sys/compat/netbsd32/netbsd32_sysent.c:1.88
--- src/sys/compat/netbsd32/netbsd32_sysent.c:1.87 Sun May 17 05:55:42 2009
+++ src/sys/compat/netbsd32/netbsd32_sysent.c Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: netbsd32_sysent.c,v 1.87 2009/05/17 05:55:42 pooka Exp $ */
+/* $NetBSD: netbsd32_sysent.c,v 1.88 2009/12/14 00:47:11 matt Exp $ */
/*
* System call switch table.
@@ -8,7 +8,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: netbsd32_sysent.c,v 1.87 2009/05/17 05:55:42 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: netbsd32_sysent.c,v 1.88 2009/12/14 00:47:11 matt Exp $");
#if defined(_KERNEL_OPT)
#include "opt_compat_netbsd.h"
@@ -471,9 +471,9 @@
#endif
{ 0, 0, 0,
sys_nosys }, /* 172 = unimplemented */
- { ns(struct netbsd32_pread_args), 0,
+ { ns(struct netbsd32_pread_args), SYCALL_NARGS64_VAL(1) | SYCALL_ARG4_64,
(sy_call_t *)netbsd32_pread }, /* 173 = netbsd32_pread */
- { ns(struct netbsd32_pwrite_args), 0,
+ { ns(struct netbsd32_pwrite_args), SYCALL_NARGS64_VAL(1) | SYCALL_ARG4_64,
(sy_call_t *)netbsd32_pwrite }, /* 174 = netbsd32_pwrite */
#if defined(NTP) || !defined(_KERNEL_OPT)
{ ns(struct compat_30_netbsd32_ntp_gettime_args), 0,
@@ -537,15 +537,15 @@
(sy_call_t *)netbsd32_setrlimit }, /* 195 = netbsd32_setrlimit */
{ ns(struct compat_12_netbsd32_getdirentries_args), 0,
(sy_call_t *)compat_12(netbsd32_getdirentries) },/* 196 = compat_12_netbsd32_getdirentries */
- { ns(struct netbsd32_mmap_args), 0,
+ { ns(struct netbsd32_mmap_args), SYCALL_NARGS64_VAL(1) | SYCALL_ARG6_64,
(sy_call_t *)netbsd32_mmap }, /* 197 = netbsd32_mmap */
- { ns(struct netbsd32____syscall_args), SYCALL_INDIRECT,
+ { ns(struct netbsd32____syscall_args), SYCALL_NARGS64_VAL(1) | SYCALL_ARG0_64 | SYCALL_RET_64 | SYCALL_INDIRECT,
(sy_call_t *)netbsd32____syscall }, /* 198 = netbsd32____syscall */
- { ns(struct netbsd32_lseek_args), 0,
+ { ns(struct netbsd32_lseek_args), SYCALL_NARGS64_VAL(1) | SYCALL_ARG2_64 | SYCALL_RET_64,
(sy_call_t *)netbsd32_lseek }, /* 199 = netbsd32_lseek */
- { ns(struct netbsd32_truncate_args), 0,
+ { ns(struct netbsd32_truncate_args), SYCALL_NARGS64_VAL(1) | SYCALL_ARG2_64,
(sy_call_t *)netbsd32_truncate }, /* 200 = netbsd32_truncate */
- { ns(struct netbsd32_ftruncate_args), 0,
+ { ns(struct netbsd32_ftruncate_args), SYCALL_NARGS64_VAL(1) | SYCALL_ARG2_64,
(sy_call_t *)netbsd32_ftruncate }, /* 201 = netbsd32_ftruncate */
{ ns(struct netbsd32___sysctl_args), 0,
(sy_call_t *)netbsd32___sysctl }, /* 202 = netbsd32___sysctl */
@@ -777,9 +777,9 @@
(sy_call_t *)netbsd32___clone }, /* 287 = netbsd32___clone */
{ ns(struct netbsd32_fktrace_args), 0,
(sy_call_t *)netbsd32_fktrace }, /* 288 = netbsd32_fktrace */
- { ns(struct netbsd32_preadv_args), 0,
+ { ns(struct netbsd32_preadv_args), SYCALL_NARGS64_VAL(1) | SYCALL_ARG4_64,
(sy_call_t *)netbsd32_preadv }, /* 289 = netbsd32_preadv */
- { ns(struct netbsd32_pwritev_args), 0,
+ { ns(struct netbsd32_pwritev_args), SYCALL_NARGS64_VAL(1) | SYCALL_ARG4_64,
(sy_call_t *)netbsd32_pwritev }, /* 290 = netbsd32_pwritev */
{ ns(struct netbsd32___sigaction14_args), 0,
(sy_call_t *)netbsd32___sigaction14 },/* 291 = netbsd32___sigaction14 */
@@ -922,7 +922,7 @@
sys_nosys }, /* 352 = unimplemented */
{ 0, 0, 0,
sys_nosys }, /* 353 = unimplemented */
- { ns(struct netbsd32_fsync_range_args), 0,
+ { ns(struct netbsd32_fsync_range_args), SYCALL_NARGS64_VAL(2) | SYCALL_ARG3_64 | SYCALL_ARG2_64,
(sy_call_t *)netbsd32_fsync_range },/* 354 = netbsd32_fsync_range */
{ ns(struct netbsd32_uuidgen_args), 0,
(sy_call_t *)netbsd32_uuidgen }, /* 355 = netbsd32_uuidgen */
@@ -1039,8 +1039,8 @@
sys_nosys }, /* 408 = unimplemented */
{ 0, 0, 0,
sys_nosys }, /* 409 = unimplemented */
- { 0, 0, 0,
- sys_nosys }, /* 410 = unimplemented sys___mount50 */
+ { ns(struct netbsd32___mount50_args), 0,
+ (sy_call_t *)netbsd32___mount50 }, /* 410 = netbsd32___mount50 */
{ ns(struct netbsd32_mremap_args), 0,
(sy_call_t *)netbsd32_mremap }, /* 411 = netbsd32_mremap */
{ 0, 0, 0,
@@ -1051,7 +1051,7 @@
sys_nosys }, /* 414 = unimplemented */
{ 0, 0, 0,
sys_nosys }, /* 415 = unimplemented */
- { ns(struct netbsd32___posix_fadvise50_args), 0,
+ { ns(struct netbsd32___posix_fadvise50_args), SYCALL_NARGS64_VAL(2) | SYCALL_ARG3_64 | SYCALL_ARG2_64,
(sy_call_t *)netbsd32___posix_fadvise50 },/* 416 = netbsd32___posix_fadvise50 */
{ ns(struct netbsd32___select50_args), 0,
(sy_call_t *)netbsd32___select50 }, /* 417 = netbsd32___select50 */
Index: src/sys/compat/netbsd32/syscalls.master
diff -u src/sys/compat/netbsd32/syscalls.master:1.80 src/sys/compat/netbsd32/syscalls.master:1.81
--- src/sys/compat/netbsd32/syscalls.master:1.80 Sun May 17 05:54:22 2009
+++ src/sys/compat/netbsd32/syscalls.master Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
- $NetBSD: syscalls.master,v 1.80 2009/05/17 05:54:22 pooka Exp $
+ $NetBSD: syscalls.master,v 1.81 2009/12/14 00:47:11 matt Exp $
; from: NetBSD: syscalls.master,v 1.81 1998/07/05 08:49:50 jonathan Exp
; @(#)syscalls.master 8.2 (Berkeley) 1/13/94
@@ -866,7 +866,9 @@
408 UNIMPL
409 UNIMPL
-410 UNIMPL sys___mount50
+410 STD { int|netbsd32||__mount50(netbsd32_charp type, \
+ netbsd32_charp path, int flags, \
+ netbsd32_voidp data, netbsd32_size_t data_len); }
411 STD { netbsd32_voidp|netbsd32||mremap( \
netbsd32_voidp old_address, \
netbsd32_size_t old_size, \
Index: src/sys/compat/ultrix/ultrix_flock.h
diff -u src/sys/compat/ultrix/ultrix_flock.h:1.1 src/sys/compat/ultrix/ultrix_flock.h:1.2
--- src/sys/compat/ultrix/ultrix_flock.h:1.1 Fri Jul 30 16:03:49 1999
+++ src/sys/compat/ultrix/ultrix_flock.h Mon Dec 14 00:47:11 2009
@@ -1,12 +1,12 @@
-/* $NetBSD: ultrix_flock.h,v 1.1 1999/07/30 16:03:49 drochner Exp $ */
+/* $NetBSD: ultrix_flock.h,v 1.2 2009/12/14 00:47:11 matt Exp $ */
struct ultrix_flock {
- short l_type;
+ int16_t l_type;
#define ULTRIX_F_RDLCK 1
#define ULTRIX_F_WRLCK 2
#define ULTRIX_F_UNLCK 3
- short l_whence;
- long l_start;
- long l_len;
- int l_pid;
+ int16_t l_whence;
+ int32_t l_start;
+ int32_t l_len;
+ int32_t l_pid;
};
Index: src/sys/compat/ultrix/ultrix_fs.c
diff -u src/sys/compat/ultrix/ultrix_fs.c:1.50 src/sys/compat/ultrix/ultrix_fs.c:1.51
--- src/sys/compat/ultrix/ultrix_fs.c:1.50 Wed Dec 17 20:51:34 2008
+++ src/sys/compat/ultrix/ultrix_fs.c Mon Dec 14 00:47:11 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: ultrix_fs.c,v 1.50 2008/12/17 20:51:34 cegger Exp $ */
+/* $NetBSD: ultrix_fs.c,v 1.51 2009/12/14 00:47:11 matt Exp $ */
/*
* Copyright (c) 1995, 1997 Jonathan Stone
@@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ultrix_fs.c,v 1.50 2008/12/17 20:51:34 cegger Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ultrix_fs.c,v 1.51 2009/12/14 00:47:11 matt Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -75,24 +75,24 @@
* compatibility with the size the Ultrix kernel and user apps expect.
*/
struct ultrix_fs_data {
- u_int32_t ufsd_flags; /* how mounted */
- u_int32_t ufsd_mtsize; /* max transfer size in bytes */
- u_int32_t ufsd_otsize; /* optimal transfer size in bytes */
- u_int32_t ufsd_bsize; /* fs block size (bytes) for vm code */
- u_int32_t ufsd_fstype; /* see ../h/fs_types.h */
- u_int32_t ufsd_gtot; /* total number of gnodes */
- u_int32_t ufsd_gfree; /* # of free gnodes */
- u_int32_t ufsd_btot; /* total number of 1K blocks */
- u_int32_t ufsd_bfree; /* # of free 1K blocks */
- u_int32_t ufsd_bfreen; /* user consumable 1K blocks */
- u_int32_t ufsd_pgthresh; /* min size in bytes before paging*/
+ uint32_t ufsd_flags; /* how mounted */
+ uint32_t ufsd_mtsize; /* max transfer size in bytes */
+ uint32_t ufsd_otsize; /* optimal transfer size in bytes */
+ uint32_t ufsd_bsize; /* fs block size (bytes) for vm code */
+ uint32_t ufsd_fstype; /* see ../h/fs_types.h */
+ uint32_t ufsd_gtot; /* total number of gnodes */
+ uint32_t ufsd_gfree; /* # of free gnodes */
+ uint32_t ufsd_btot; /* total number of 1K blocks */
+ uint32_t ufsd_bfree; /* # of free 1K blocks */
+ uint32_t ufsd_bfreen; /* user consumable 1K blocks */
+ uint32_t ufsd_pgthresh; /* min size in bytes before paging*/
int32_t ufsd_uid; /* uid that mounted me */
int16_t ufsd_dev; /* major/minor of fs */
int16_t ufsd_exroot; /* root mapping from exports */
char ufsd_devname[ULTRIX_MAXPATHLEN + 4]; /* name of dev */
char ufsd_path[ULTRIX_MAXPATHLEN + 4]; /* name of mnt point */
- u_int32_t ufsd_nupdate; /* number of writes */
- u_int32_t ufsd_pad[112]; /* pad to 2560 bytes. */
+ uint32_t ufsd_nupdate; /* number of writes */
+ uint32_t ufsd_pad[112]; /* pad to 2560 bytes. */
};
/*
@@ -337,8 +337,8 @@
* mounting local (4.2bsd FFS) filesystems
*/
struct ultrix_ufs_args {
- u_long ufs_flags; /* mount flags?*/
- u_long ufs_pgthresh; /* minimum file size to page */
+ uint32_t ufs_flags; /* mount flags?*/
+ uint32_t ufs_pgthresh; /* minimum file size to page */
};
int
Index: src/sys/compat/ultrix/ultrix_ioctl.c
diff -u src/sys/compat/ultrix/ultrix_ioctl.c:1.35 src/sys/compat/ultrix/ultrix_ioctl.c:1.36
--- src/sys/compat/ultrix/ultrix_ioctl.c:1.35 Fri Mar 21 21:54:59 2008
+++ src/sys/compat/ultrix/ultrix_ioctl.c Mon Dec 14 00:47:12 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: ultrix_ioctl.c,v 1.35 2008/03/21 21:54:59 ad Exp $ */
+/* $NetBSD: ultrix_ioctl.c,v 1.36 2009/12/14 00:47:12 matt Exp $ */
/* from : NetBSD: sunos_ioctl.c,v 1.21 1995/10/07 06:27:31 mycroft Exp */
/*
@@ -28,7 +28,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ultrix_ioctl.c,v 1.35 2008/03/21 21:54:59 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ultrix_ioctl.c,v 1.36 2009/12/14 00:47:12 matt Exp $");
#if defined(_KERNEL_OPT)
#include "opt_compat_ultrix.h"
@@ -87,7 +87,7 @@
{ -1, -1 }
};
-static const u_long s2btab[] = {
+static const uint16_t s2btab[] = {
0,
50,
75,
@@ -143,7 +143,7 @@
static void
stios2btios(struct emul_termios *st, struct termios *bt)
{
- u_long l, r;
+ uint32_t l, r;
l = st->c_iflag;
r = ((l & 0x00000001) ? IGNBRK : 0);
@@ -273,7 +273,7 @@
static void
btios2stios(struct termios *bt, struct emul_termios *st)
{
- u_long l, r;
+ uint32_t l, r;
int speed;
l = bt->c_iflag;
Index: src/sys/compat/ultrix/ultrix_pathname.c
diff -u src/sys/compat/ultrix/ultrix_pathname.c:1.37 src/sys/compat/ultrix/ultrix_pathname.c:1.38
--- src/sys/compat/ultrix/ultrix_pathname.c:1.37 Mon Jun 29 05:08:16 2009
+++ src/sys/compat/ultrix/ultrix_pathname.c Mon Dec 14 00:47:12 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: ultrix_pathname.c,v 1.37 2009/06/29 05:08:16 dholland Exp $ */
+/* $NetBSD: ultrix_pathname.c,v 1.38 2009/12/14 00:47:12 matt Exp $ */
/*
* Copyright (c) 1992, 1993
@@ -59,7 +59,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ultrix_pathname.c,v 1.37 2009/06/29 05:08:16 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ultrix_pathname.c,v 1.38 2009/12/14 00:47:12 matt Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -191,15 +191,15 @@
struct ultrix_statfs {
- long f_type; /* type of info, zero for now */
- long f_bsize; /* fundamental file system block size */
- long f_blocks; /* total blocks in file system */
- long f_bfree; /* free blocks */
- long f_bavail; /* free blocks available to non-super-user */
- long f_files; /* total file nodes in file system */
- long f_ffree; /* free file nodes in fs */
+ int32_t f_type; /* type of info, zero for now */
+ int32_t f_bsize; /* fundamental file system block size */
+ int32_t f_blocks; /* total blocks in file system */
+ int32_t f_bfree; /* free blocks */
+ int32_t f_bavail; /* free blocks available to non-super-user */
+ int32_t f_files; /* total file nodes in file system */
+ int32_t f_ffree; /* free file nodes in fs */
fsid_t f_fsid; /* file system id */
- long f_spare[7]; /* spare for later */
+ int32_t f_spare[7]; /* spare for later */
};
/*
Index: src/sys/compat/ultrix/ultrix_tty.h
diff -u src/sys/compat/ultrix/ultrix_tty.h:1.2 src/sys/compat/ultrix/ultrix_tty.h:1.3
--- src/sys/compat/ultrix/ultrix_tty.h:1.2 Thu Jan 4 19:03:36 1996
+++ src/sys/compat/ultrix/ultrix_tty.h Mon Dec 14 00:47:12 2009
@@ -1,4 +1,4 @@
-/* $NetBSD: ultrix_tty.h,v 1.2 1996/01/04 19:03:36 jonathan Exp $ */
+/* $NetBSD: ultrix_tty.h,v 1.3 2009/12/14 00:47:12 matt Exp $ */
/* From: NetBSD sunos.h,v 1.4 1995/03/04 09:50:00 pk Exp */
@@ -31,10 +31,10 @@
* Very similar to SunOS but with more c_cc entries (gag)
*/
struct ultrix_termios {
- u_long c_iflag;
- u_long c_oflag;
- u_long c_cflag;
- u_long c_lflag;
+ __uint32_t c_iflag;
+ __uint32_t c_oflag;
+ __uint32_t c_cflag;
+ __uint32_t c_lflag;
u_char c_cc[19]; /* 17 for Sun */
u_char c_line;
};
Added files:
Index: src/sys/compat/irix/irix_exec_elf64.c
diff -u /dev/null src/sys/compat/irix/irix_exec_elf64.c:1.2
--- /dev/null Mon Dec 14 00:47:12 2009
+++ src/sys/compat/irix/irix_exec_elf64.c Mon Dec 14 00:47:10 2009
@@ -0,0 +1,5 @@
+/* $NetBSD: irix_exec_elf64.c,v 1.2 2009/12/14 00:47:10 matt Exp $ */
+
+#define ELFSIZE 64
+
+#include "irix_exec_elf32.c"