Module Name:    src
Committed By:   rmind
Date:           Sun Jul 19 02:41:27 UTC 2009

Modified Files:
        src/sys/compat/common: compat_mod.c kern_time_50.c

Log Message:
- Use #ifdef AIO, instead of #ifdef notyet.  Not a solution, but at
  least gets it working for MONOLITHIC kernel.
- Similarily add #ifdef MQUEUE for mqueue compat.
- Amend TNF license to be 2-clause.  Approved by <christos>.


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/compat/common/compat_mod.c \
    src/sys/compat/common/kern_time_50.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/common/compat_mod.c
diff -u src/sys/compat/common/compat_mod.c:1.7 src/sys/compat/common/compat_mod.c:1.8
--- src/sys/compat/common/compat_mod.c:1.7	Tue Jan 13 20:47:47 2009
+++ src/sys/compat/common/compat_mod.c	Sun Jul 19 02:41:27 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: compat_mod.c,v 1.7 2009/01/13 20:47:47 martin Exp $	*/
+/*	$NetBSD: compat_mod.c,v 1.8 2009/07/19 02:41:27 rmind Exp $	*/
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: compat_mod.c,v 1.7 2009/01/13 20:47:47 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: compat_mod.c,v 1.8 2009/07/19 02:41:27 rmind Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_compat_netbsd.h"
@@ -231,6 +231,8 @@
 # endif
 	{ SYS_compat_50___fhstat40, 0, (sy_call_t *)compat_50_sys___fhstat40 },
 	{ SYS_compat_50_aio_suspend, 0, (sy_call_t *)compat_50_sys_aio_suspend },
+	{ SYS_compat_50_mq_timedreceive, 0, (sy_call_t *)compat_50_sys_mq_timedreceive },
+	{ SYS_compat_50_mq_timedsend, 0, (sy_call_t *)compat_50_sys_mq_timedsend },
 #endif
 	{ 0, 0, NULL },
 };
Index: src/sys/compat/common/kern_time_50.c
diff -u src/sys/compat/common/kern_time_50.c:1.7 src/sys/compat/common/kern_time_50.c:1.8
--- src/sys/compat/common/kern_time_50.c:1.7	Sun Mar 29 19:21:19 2009
+++ src/sys/compat/common/kern_time_50.c	Sun Jul 19 02:41:27 2009
@@ -1,7 +1,7 @@
-/*	$NetBSD: kern_time_50.c,v 1.7 2009/03/29 19:21:19 christos Exp $	*/
+/*	$NetBSD: kern_time_50.c,v 1.8 2009/07/19 02:41:27 rmind Exp $	*/
 
 /*-
- * Copyright (c) 2008 The NetBSD Foundation, Inc.
+ * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc.
  * All rights reserved.
  *
  * This code is derived from software contributed to The NetBSD Foundation
@@ -15,13 +15,6 @@
  * 2. Redistributions in binary form must reproduce the above copyright
  *    notice, this list of conditions and the following disclaimer in the
  *    documentation and/or other materials provided with the distribution.
- * 3. All advertising materials mentioning features or use of this software
- *    must display the following acknowledgement:
- *        This product includes software developed by the NetBSD
- *        Foundation, Inc. and its contributors.
- * 4. Neither the name of The NetBSD Foundation nor the names of its
- *    contributors may be used to endorse or promote products derived
- *    from this software without specific prior written permission.
  *
  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
@@ -36,10 +29,12 @@
  * POSSIBILITY OF SUCH DAMAGE.
  */
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_time_50.c,v 1.7 2009/03/29 19:21:19 christos Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_time_50.c,v 1.8 2009/07/19 02:41:27 rmind Exp $");
 
 #ifdef _KERNEL_OPT
+#include "opt_aio.h"
 #include "opt_ntp.h"
+#include "opt_mqueue.h"
 #endif
 
 #include <sys/param.h>
@@ -373,7 +368,7 @@
 		syscallarg(int) nent;
 		syscallarg(const struct timespec50 *) timeout;
 	} */
-#ifdef notyet
+#ifdef AIO
 	struct aiocb **list;
 	struct timespec ts;
 	struct timespec50 ts50;
@@ -542,6 +537,7 @@
 		syscallarg(unsigned) msg_prio;
 		syscallarg(const struct timespec50 *) abs_timeout;
 	} */
+#ifdef MQUEUE
 	int t;
 	int error;
 	struct timespec50 ts50;
@@ -561,6 +557,9 @@
 
 	return mq_send1(l, SCARG(uap, mqdes), SCARG(uap, msg_ptr),
 	    SCARG(uap, msg_len), SCARG(uap, msg_prio), t);
+#else
+	return ENOSYS;
+#endif
 }
 
 int
@@ -574,6 +573,7 @@
 		syscallarg(unsigned *) msg_prio;
 		syscallarg(const struct timespec50 *) abs_timeout;
 	} */
+#ifdef MQUEUE
 	int error, t;
 	ssize_t mlen;
 	struct timespec ts;
@@ -598,6 +598,9 @@
 		*retval = mlen;
 
 	return error;
+#else
+	return ENOSYS;
+#endif
 }
 
 static int

Reply via email to