Module Name:    src
Committed By:   martin
Date:           Sat Sep 16 09:04:50 UTC 2017

Modified Files:
        src/sys/compat/svr4_32: svr4_32_ioctl.c svr4_32_misc.c svr4_32_signal.c

Log Message:
Make debug code compile


To generate a diff of this commit:
cvs rdiff -u -r1.22 -r1.23 src/sys/compat/svr4_32/svr4_32_ioctl.c
cvs rdiff -u -r1.78 -r1.79 src/sys/compat/svr4_32/svr4_32_misc.c
cvs rdiff -u -r1.30 -r1.31 src/sys/compat/svr4_32/svr4_32_signal.c

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/svr4_32/svr4_32_ioctl.c
diff -u src/sys/compat/svr4_32/svr4_32_ioctl.c:1.22 src/sys/compat/svr4_32/svr4_32_ioctl.c:1.23
--- src/sys/compat/svr4_32/svr4_32_ioctl.c:1.22	Sat Mar 14 21:04:19 2009
+++ src/sys/compat/svr4_32/svr4_32_ioctl.c	Sat Sep 16 09:04:50 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: svr4_32_ioctl.c,v 1.22 2009/03/14 21:04:19 dsl Exp $	 */
+/*	$NetBSD: svr4_32_ioctl.c,v 1.23 2017/09/16 09:04:50 martin Exp $	 */
 
 /*-
  * Copyright (c) 1994, 2008 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: svr4_32_ioctl.c,v 1.22 2009/03/14 21:04:19 dsl Exp $");
+__KERNEL_RCSID(0, "$NetBSD: svr4_32_ioctl.c,v 1.23 2017/09/16 09:04:50 martin Exp $");
 
 #include <sys/param.h>
 #include <sys/proc.h>
@@ -103,8 +103,8 @@ svr4_32_sys_ioctl(struct lwp *l, const s
 
 	svr4_32_decode_cmd(SCARG(uap, com), dir, &c, &num, &argsiz);
 
-	uprintf("svr4_32_ioctl(%d, _IO%s(%c, %d, %d), %#x);\n", SCARG(uap, fd),
-	    dir, c, num, argsiz, SCARG(uap, data));
+	uprintf("svr4_32_ioctl(%d, _IO%s(%c, %d, %d), %p);\n", SCARG(uap, fd),
+	    dir, c, num, argsiz, NETBSD32PTR64(SCARG(uap, data)));
 #endif
 	cmd = SCARG(uap, com);
 

Index: src/sys/compat/svr4_32/svr4_32_misc.c
diff -u src/sys/compat/svr4_32/svr4_32_misc.c:1.78 src/sys/compat/svr4_32/svr4_32_misc.c:1.79
--- src/sys/compat/svr4_32/svr4_32_misc.c:1.78	Fri Jul 28 15:34:07 2017
+++ src/sys/compat/svr4_32/svr4_32_misc.c	Sat Sep 16 09:04:50 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: svr4_32_misc.c,v 1.78 2017/07/28 15:34:07 riastradh Exp $	 */
+/*	$NetBSD: svr4_32_misc.c,v 1.79 2017/09/16 09:04:50 martin Exp $	 */
 
 /*-
  * Copyright (c) 1994, 2008 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: svr4_32_misc.c,v 1.78 2017/07/28 15:34:07 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: svr4_32_misc.c,v 1.79 2017/09/16 09:04:50 martin Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -1012,7 +1012,8 @@ svr4_32_setinfo(int pid, struct rusage *
 	}
 
 	DPRINTF(("siginfo [pid %ld signo %d code %d errno %d status %d]\n",
-		 i.si_pid, i.si_signo, i.si_code, i.si_errno, i.si_status));
+		 (long)i.si_pid, i.si_signo, i.si_code, i.si_errno,
+		 i.si_status));
 
 	return copyout(&i, s, sizeof(i));
 }
@@ -1043,7 +1044,7 @@ svr4_32_sys_waitsys(struct lwp *l, const
 
 	DPRINTF(("waitsys(%d, %d, %p, %x)\n",
 	         SCARG(uap, grp), id,
-		 SCARG(uap, info), SCARG(uap, options)));
+		 NETBSD32PTR64(SCARG(uap, info)), SCARG(uap, options)));
 
 	/* Translate options */
 	options = 0;

Index: src/sys/compat/svr4_32/svr4_32_signal.c
diff -u src/sys/compat/svr4_32/svr4_32_signal.c:1.30 src/sys/compat/svr4_32/svr4_32_signal.c:1.31
--- src/sys/compat/svr4_32/svr4_32_signal.c:1.30	Sun Jul 30 12:31:46 2017
+++ src/sys/compat/svr4_32/svr4_32_signal.c	Sat Sep 16 09:04:50 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: svr4_32_signal.c,v 1.30 2017/07/30 12:31:46 christos Exp $	 */
+/*	$NetBSD: svr4_32_signal.c,v 1.31 2017/09/16 09:04:50 martin Exp $	 */
 
 /*-
  * Copyright (c) 1994, 1998 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: svr4_32_signal.c,v 1.30 2017/07/30 12:31:46 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: svr4_32_signal.c,v 1.31 2017/09/16 09:04:50 martin Exp $");
 
 #if defined(_KERNEL_OPT)
 #include "opt_compat_svr4.h"
@@ -651,12 +651,12 @@ svr4_32_sys_context(struct lwp *l, const
 
 	switch (SCARG(uap, func)) {
 	case SVR4_GETCONTEXT:
-		DPRINTF(("getcontext(%p)\n", SCARG(uap, uc)));
+		DPRINTF(("getcontext(%p)\n", NETBSD32PTR64(SCARG(uap, uc))));
 		svr4_32_getcontext(l, &uc, &l->l_sigmask);
 		return copyout(&uc, SCARG_P32(uap, uc), sizeof(uc));
 
 	case SVR4_SETCONTEXT:
-		DPRINTF(("setcontext(%p)\n", SCARG(uap, uc)));
+		DPRINTF(("setcontext(%p)\n", NETBSD32PTR64(SCARG(uap, uc))));
 		if (!SCARG_P32(uap, uc))
 			exit1(l, 0, 0);
 		else if ((error = copyin(SCARG_P32(uap, uc),
@@ -667,7 +667,7 @@ svr4_32_sys_context(struct lwp *l, const
 
 	default:
 		DPRINTF(("context(%d, %p)\n", SCARG(uap, func),
-		    SCARG(uap, uc)));
+		    NETBSD32PTR64(SCARG(uap, uc))));
 		return ENOSYS;
 	}
 	return 0;

Reply via email to