Module Name:    src
Committed By:   ad
Date:           Sat Feb 15 17:09:24 UTC 2020

Modified Files:
        src/sys/kern: kern_condvar.c sys_select.c
        src/sys/sys: syncobj.h

Log Message:
- List all of the syncobjs in syncobj.h.
- Update a comment.


To generate a diff of this commit:
cvs rdiff -u -r1.42 -r1.43 src/sys/kern/kern_condvar.c
cvs rdiff -u -r1.51 -r1.52 src/sys/kern/sys_select.c
cvs rdiff -u -r1.9 -r1.10 src/sys/sys/syncobj.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/kern/kern_condvar.c
diff -u src/sys/kern/kern_condvar.c:1.42 src/sys/kern/kern_condvar.c:1.43
--- src/sys/kern/kern_condvar.c:1.42	Wed Nov 20 21:49:00 2019
+++ src/sys/kern/kern_condvar.c	Sat Feb 15 17:09:24 2020
@@ -1,7 +1,7 @@
-/*	$NetBSD: kern_condvar.c,v 1.42 2019/11/20 21:49:00 ad Exp $	*/
+/*	$NetBSD: kern_condvar.c,v 1.43 2020/02/15 17:09:24 ad Exp $	*/
 
 /*-
- * Copyright (c) 2006, 2007, 2008, 2019 The NetBSD Foundation, Inc.
+ * Copyright (c) 2006, 2007, 2008, 2019, 2020 The NetBSD Foundation, Inc.
  * All rights reserved.
  *
  * This code is derived from software contributed to The NetBSD Foundation
@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_condvar.c,v 1.42 2019/11/20 21:49:00 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_condvar.c,v 1.43 2020/02/15 17:09:24 ad Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -53,7 +53,7 @@ __KERNEL_RCSID(0, "$NetBSD: kern_condvar
  *	cv_opaque[2]	description for ps(1)
  *
  * cv_opaque[0..1] is protected by the interlock passed to cv_wait() (enqueue
- * only), and the sleep queue lock acquired with sleeptab_lookup() (enqueue
+ * only), and the sleep queue lock acquired with sleepq_hashlock() (enqueue
  * and dequeue).
  *
  * cv_opaque[2] (the wmesg) is static and does not change throughout the life
@@ -70,7 +70,7 @@ static void		cv_unsleep(lwp_t *, bool);
 static inline void	cv_wakeup_one(kcondvar_t *);
 static inline void	cv_wakeup_all(kcondvar_t *);
 
-static syncobj_t cv_syncobj = {
+syncobj_t cv_syncobj = {
 	.sobj_flag	= SOBJ_SLEEPQ_SORTED,
 	.sobj_unsleep	= cv_unsleep,
 	.sobj_changepri	= sleepq_changepri,

Index: src/sys/kern/sys_select.c
diff -u src/sys/kern/sys_select.c:1.51 src/sys/kern/sys_select.c:1.52
--- src/sys/kern/sys_select.c:1.51	Sat Feb  1 02:23:04 2020
+++ src/sys/kern/sys_select.c	Sat Feb 15 17:09:24 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: sys_select.c,v 1.51 2020/02/01 02:23:04 riastradh Exp $	*/
+/*	$NetBSD: sys_select.c,v 1.52 2020/02/15 17:09:24 ad Exp $	*/
 
 /*-
  * Copyright (c) 2007, 2008, 2009, 2010, 2019 The NetBSD Foundation, Inc.
@@ -84,7 +84,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sys_select.c,v 1.51 2020/02/01 02:23:04 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sys_select.c,v 1.52 2020/02/15 17:09:24 ad Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -136,7 +136,7 @@ static const int sel_flag[] = {
 	POLLRDBAND
 };
 
-static syncobj_t select_sobj = {
+syncobj_t select_sobj = {
 	.sobj_flag	= SOBJ_SLEEPQ_FIFO,
 	.sobj_unsleep	= sleepq_unsleep,
 	.sobj_changepri	= sleepq_changepri,

Index: src/sys/sys/syncobj.h
diff -u src/sys/sys/syncobj.h:1.9 src/sys/sys/syncobj.h:1.10
--- src/sys/sys/syncobj.h:1.9	Sun Jan 26 19:01:56 2020
+++ src/sys/sys/syncobj.h	Sat Feb 15 17:09:24 2020
@@ -1,4 +1,4 @@
-/*	$NetBSD: syncobj.h,v 1.9 2020/01/26 19:01:56 ad Exp $	*/
+/*	$NetBSD: syncobj.h,v 1.10 2020/02/15 17:09:24 ad Exp $	*/
 
 /*-
  * Copyright (c) 2007, 2008, 2020 The NetBSD Foundation, Inc.
@@ -56,11 +56,13 @@ struct lwp *syncobj_noowner(wchan_t);
 #define	SOBJ_SLEEPQ_LIFO	0x04
 #define	SOBJ_SLEEPQ_NULL	0x08
 
-extern syncobj_t	sched_syncobj;
+extern syncobj_t	cv_syncobj;
+extern syncobj_t	lwp_park_syncobj;
 extern syncobj_t	mutex_syncobj;
 extern syncobj_t	rw_syncobj;
+extern syncobj_t	sched_syncobj;
+extern syncobj_t	select_syncobj;
 extern syncobj_t	sleep_syncobj;
-extern syncobj_t	lwp_park_syncobj;
 
 #endif /* defined(_KERNEL) */
 

Reply via email to