Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/wscons get rid of CIRCLEQ
details: https://anonhg.NetBSD.org/src/rev/0534ac1cde5e
branches: trunk
changeset: 791568:0534ac1cde5e
user: christos <christos%NetBSD.org@localhost>
date: Sat Nov 23 20:56:41 2013 +0000
description:
get rid of CIRCLEQ
diffstat:
sys/dev/wscons/wsmux.c | 26 +++++++++++++-------------
sys/dev/wscons/wsmuxvar.h | 6 +++---
2 files changed, 16 insertions(+), 16 deletions(-)
diffs (144 lines):
diff -r 5f91434510e8 -r 0534ac1cde5e sys/dev/wscons/wsmux.c
--- a/sys/dev/wscons/wsmux.c Sat Nov 23 20:53:46 2013 +0000
+++ b/sys/dev/wscons/wsmux.c Sat Nov 23 20:56:41 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: wsmux.c,v 1.55 2013/03/18 11:40:39 jmcneill Exp $ */
+/* $NetBSD: wsmux.c,v 1.56 2013/11/23 20:56:41 christos Exp $ */
/*
* Copyright (c) 1998, 2005 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: wsmux.c,v 1.55 2013/03/18 11:40:39 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: wsmux.c,v 1.56 2013/11/23 20:56:41 christos Exp $");
#include "opt_compat_netbsd.h"
#include "opt_modular.h"
@@ -259,7 +259,7 @@
sc->sc_base.me_evp = evar; /* remember event variable, mark as open */
/* Open all children. */
- CIRCLEQ_FOREACH(me, &sc->sc_cld, me_next) {
+ TAILQ_FOREACH(me, &sc->sc_cld, me_next) {
DPRINTF(("wsmuxopen: %s: m=%p dev=%s\n",
device_xname(sc->sc_base.me_dv), me,
device_xname(me->me_dv)));
@@ -330,7 +330,7 @@
device_xname(sc->sc_base.me_dv), sc));
/* Close all the children. */
- CIRCLEQ_FOREACH(me, &sc->sc_cld, me_next) {
+ TAILQ_FOREACH(me, &sc->sc_cld, me_next) {
DPRINTF(("wsmuxclose %s: m=%p dev=%s\n",
device_xname(sc->sc_base.me_dv), me,
device_xname(me->me_dv)));
@@ -451,7 +451,7 @@
DPRINTF(("%s: rem type=%d, no=%d\n",
device_xname(sc->sc_base.me_dv), d->type, d->idx));
/* Locate the device */
- CIRCLEQ_FOREACH(me, &sc->sc_cld, me_next) {
+ TAILQ_FOREACH(me, &sc->sc_cld, me_next) {
if (me->me_ops->type == d->type &&
device_unit(me->me_dv) == d->idx) {
DPRINTF(("wsmux_do_ioctl: detach\n"));
@@ -466,7 +466,7 @@
DPRINTF(("%s: list\n", device_xname(sc->sc_base.me_dv)));
l = (struct wsmux_device_list *)data;
n = 0;
- CIRCLEQ_FOREACH(me, &sc->sc_cld, me_next) {
+ TAILQ_FOREACH(me, &sc->sc_cld, me_next) {
if (n >= WSMUX_MAXDEV)
break;
l->devices[n].type = me->me_ops->type;
@@ -534,7 +534,7 @@
/* Return 0 if any of the ioctl() succeeds, otherwise the last error */
error = 0;
ok = 0;
- CIRCLEQ_FOREACH(me, &sc->sc_cld, me_next) {
+ TAILQ_FOREACH(me, &sc->sc_cld, me_next) {
#ifdef DIAGNOSTIC
/* XXX check evp? */
if (me->me_parent != sc) {
@@ -652,7 +652,7 @@
free(sc, M_DEVBUF);
return NULL;
}
- CIRCLEQ_INIT(&sc->sc_cld);
+ TAILQ_INIT(&sc->sc_cld);
snprintf(sc->sc_base.me_dv->dv_xname, sizeof sc->sc_base.me_dv->dv_xname,
"%s%d", name, unit);
sc->sc_base.me_dv->dv_private = sc;
@@ -681,7 +681,7 @@
}
#endif
me->me_parent = sc;
- CIRCLEQ_INSERT_TAIL(&sc->sc_cld, me, me_next);
+ TAILQ_INSERT_TAIL(&sc->sc_cld, me, me_next);
error = 0;
#if NWSDISPLAY > 0
@@ -724,7 +724,7 @@
if (error) {
me->me_parent = NULL;
- CIRCLEQ_REMOVE(&sc->sc_cld, me, me_next);
+ TAILQ_REMOVE(&sc->sc_cld, me, me_next);
}
DPRINTF(("wsmux_attach_sc: %s(%p) done, error=%d\n",
@@ -762,7 +762,7 @@
(void)wsevsrc_close(me);
}
- CIRCLEQ_REMOVE(&sc->sc_cld, me, me_next);
+ TAILQ_REMOVE(&sc->sc_cld, me, me_next);
me->me_parent = NULL;
DPRINTF(("wsmux_detach_sc: done sc=%p\n", sc));
@@ -795,7 +795,7 @@
*/
error = EPASSTHROUGH;
ok = 0;
- CIRCLEQ_FOREACH(me, &sc->sc_cld, me_next) {
+ TAILQ_FOREACH(me, &sc->sc_cld, me_next) {
DPRINTF(("wsmux_displayioctl: me=%p\n", me));
#ifdef DIAGNOSTIC
if (me->me_parent != sc) {
@@ -858,7 +858,7 @@
device_xname(displaydv));
ok = 0;
error = 0;
- CIRCLEQ_FOREACH(me, &sc->sc_cld,me_next) {
+ TAILQ_FOREACH(me, &sc->sc_cld,me_next) {
#ifdef DIAGNOSTIC
if (me->me_parent != sc) {
printf("wsmux_set_display: bad child parent %p\n", me);
diff -r 5f91434510e8 -r 0534ac1cde5e sys/dev/wscons/wsmuxvar.h
--- a/sys/dev/wscons/wsmuxvar.h Sat Nov 23 20:53:46 2013 +0000
+++ b/sys/dev/wscons/wsmuxvar.h Sat Nov 23 20:56:41 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: wsmuxvar.h,v 1.14 2008/04/28 20:24:01 martin Exp $ */
+/* $NetBSD: wsmuxvar.h,v 1.15 2013/11/23 20:56:41 christos Exp $ */
/*
* Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -42,7 +42,7 @@
#endif
#if NWSMUX > 0
struct wsmux_softc *me_parent; /* parent mux device */
- CIRCLEQ_ENTRY(wsevsrc) me_next; /* sibling pointers */
+ TAILQ_ENTRY(wsevsrc) me_next; /* sibling pointers */
#endif
};
@@ -74,7 +74,7 @@
struct wsmux_softc {
struct wsevsrc sc_base;
struct proc *sc_p; /* open proc */
- CIRCLEQ_HEAD(, wsevsrc) sc_cld; /* list of children */
+ TAILQ_HEAD(, wsevsrc) sc_cld; /* list of children */
u_int32_t sc_kbd_layout; /* current layout of keyboard */
#ifdef WSDISPLAY_COMPAT_RAWKBD
int sc_rawkbd; /* A hack to remember the kbd mode */
Home |
Main Index |
Thread Index |
Old Index