summaryrefslogtreecommitdiff
path: root/sys/arch/hp300/dev
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch/hp300/dev')
-rw-r--r--sys/arch/hp300/dev/dma.c5
-rw-r--r--sys/arch/hp300/dev/fhpib.c8
-rw-r--r--sys/arch/hp300/dev/hpib.c8
-rw-r--r--sys/arch/hp300/dev/mb89352.c4
-rw-r--r--sys/arch/hp300/dev/nhpib.c8
5 files changed, 16 insertions, 17 deletions
diff --git a/sys/arch/hp300/dev/dma.c b/sys/arch/hp300/dev/dma.c
index ba2a7cbeba4..15c1f722591 100644
--- a/sys/arch/hp300/dev/dma.c
+++ b/sys/arch/hp300/dev/dma.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dma.c,v 1.15 2004/12/16 16:48:44 miod Exp $ */
+/* $OpenBSD: dma.c,v 1.16 2004/12/25 23:02:23 miod Exp $ */
/* $NetBSD: dma.c,v 1.19 1997/05/05 21:02:39 thorpej Exp $ */
/*
@@ -310,8 +310,7 @@ dmafree(dq)
*/
dc->dm_job = NULL;
chan = 1 << unit;
- for (dn = sc->sc_queue.tqh_first; dn != NULL;
- dn = dn->dq_list.tqe_next) {
+ TAILQ_FOREACH(dn, &sc->sc_queue, dq_list) {
if (dn->dq_chan & chan) {
/* Found one... */
TAILQ_REMOVE(&sc->sc_queue, dn, dq_list);
diff --git a/sys/arch/hp300/dev/fhpib.c b/sys/arch/hp300/dev/fhpib.c
index c3dcfbf8c20..2bf82aea1fe 100644
--- a/sys/arch/hp300/dev/fhpib.c
+++ b/sys/arch/hp300/dev/fhpib.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: fhpib.c,v 1.13 2004/09/29 07:35:52 miod Exp $ */
+/* $OpenBSD: fhpib.c,v 1.14 2004/12/25 23:02:23 miod Exp $ */
/* $NetBSD: fhpib.c,v 1.18 1997/05/05 21:04:16 thorpej Exp $ */
/*
@@ -466,7 +466,7 @@ fhpibdmadone(arg)
hs->sc_flags &= ~(HPIBF_DONE|HPIBF_IO|HPIBF_READ|HPIBF_TIMO);
dmafree(hs->sc_dq);
- hq = hs->sc_queue.tqh_first;
+ hq = TAILQ_FIRST(&hs->sc_queue);
(hq->hq_intr)(hq->hq_softc);
}
splx(s);
@@ -546,7 +546,7 @@ fhpibintr(arg)
if ((fhpibdebug & FDB_DMA) && fhpibdebugunit == sc->sc_dev.dv_unit)
printf("fhpibintr: flags %x\n", hs->sc_flags);
#endif
- hq = hs->sc_queue.tqh_first;
+ hq = TAILQ_FIRST(&hs->sc_queue);
if (hs->sc_flags & HPIBF_IO) {
if (hs->sc_flags & HPIBF_TIMO)
timeout_del(&sc->sc_dma_to);
@@ -651,7 +651,7 @@ fhpibppwatch(arg)
if ((hs->sc_flags & HPIBF_PPOLL) == 0)
return;
- slave = (0x80 >> hs->sc_queue.tqh_first->hq_slave);
+ slave = (0x80 >> TAILQ_FIRST(&hs->sc_queue)->hq_slave);
#ifdef DEBUG
if (!doppollint) {
if (fhpibppoll(hs) & slave) {
diff --git a/sys/arch/hp300/dev/hpib.c b/sys/arch/hp300/dev/hpib.c
index 3ef5983265f..d972d9d315e 100644
--- a/sys/arch/hp300/dev/hpib.c
+++ b/sys/arch/hp300/dev/hpib.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: hpib.c,v 1.10 2003/06/02 23:27:44 millert Exp $ */
+/* $OpenBSD: hpib.c,v 1.11 2004/12/25 23:02:24 miod Exp $ */
/* $NetBSD: hpib.c,v 1.16 1997/04/27 20:58:57 thorpej Exp $ */
/*
@@ -262,7 +262,7 @@ hpibreq(pdev, hq)
TAILQ_INSERT_TAIL(&sc->sc_queue, hq, hq_list);
splx(s);
- if (sc->sc_queue.tqh_first == hq)
+ if (TAILQ_FIRST(&sc->sc_queue) == hq)
return (1);
return (0);
@@ -280,7 +280,7 @@ hpibfree(pdev, hq)
TAILQ_REMOVE(&sc->sc_queue, hq, hq_list);
splx(s);
- if ((hq = sc->sc_queue.tqh_first) != NULL)
+ if ((hq = TAILQ_FIRST(&sc->sc_queue)) != NULL)
(*hq->hq_start)(hq->hq_softc);
}
@@ -394,7 +394,7 @@ hpibstart(arg)
struct hpibbus_softc *sc = arg;
struct hpibqueue *hq;
- hq = sc->sc_queue.tqh_first;
+ hq = TAILQ_FIRST(&sc->sc_queue);
(*hq->hq_go)(hq->hq_softc);
}
diff --git a/sys/arch/hp300/dev/mb89352.c b/sys/arch/hp300/dev/mb89352.c
index a80fd43f805..9f0de06a403 100644
--- a/sys/arch/hp300/dev/mb89352.c
+++ b/sys/arch/hp300/dev/mb89352.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mb89352.c,v 1.11 2004/12/22 21:11:12 miod Exp $ */
+/* $OpenBSD: mb89352.c,v 1.12 2004/12/25 23:02:24 miod Exp $ */
/* $NetBSD: mb89352.c,v 1.5 2000/03/23 07:01:31 thorpej Exp $ */
/* NecBSD: mb89352.c,v 1.4 1998/03/14 07:31:20 kmatsuda Exp */
@@ -341,7 +341,7 @@ spc_free_acb(struct spc_softc *sc, struct spc_acb *acb, int flags)
* If there were none, wake anybody waiting for one to come free,
* starting with queued entries.
*/
- if (acb->chain.tqe_next == 0)
+ if (TAILQ_NEXT(acb, chain) == NULL)
wakeup(&sc->free_list);
splx(s);
diff --git a/sys/arch/hp300/dev/nhpib.c b/sys/arch/hp300/dev/nhpib.c
index 9cd0f88c727..3053f999a03 100644
--- a/sys/arch/hp300/dev/nhpib.c
+++ b/sys/arch/hp300/dev/nhpib.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: nhpib.c,v 1.13 2004/09/29 07:35:52 miod Exp $ */
+/* $OpenBSD: nhpib.c,v 1.14 2004/12/25 23:02:24 miod Exp $ */
/* $NetBSD: nhpib.c,v 1.17 1997/05/05 21:06:41 thorpej Exp $ */
/*
@@ -411,7 +411,7 @@ nhpibreadtimo(arg)
hs->sc_flags &= ~(HPIBF_DONE|HPIBF_IO|HPIBF_READ|HPIBF_TIMO);
dmafree(hs->sc_dq);
- hq = hs->sc_queue.tqh_first;
+ hq = TAILQ_FIRST(&hs->sc_queue);
(hq->hq_intr)(hq->hq_softc);
}
splx(s);
@@ -467,7 +467,7 @@ nhpibintr(arg)
stat0 = hd->hpib_mis;
stat1 = hd->hpib_lis;
- hq = hs->sc_queue.tqh_first;
+ hq = TAILQ_FIRST(&hs->sc_queue);
if (hs->sc_flags & HPIBF_IO) {
hd->hpib_mim = 0;
@@ -545,7 +545,7 @@ nhpibppwatch(arg)
if ((hs->sc_flags & HPIBF_PPOLL) == 0)
return;
again:
- if (nhpibppoll(hs) & (0x80 >> hs->sc_queue.tqh_first->hq_slave))
+ if (nhpibppoll(hs) & (0x80 >> TAILQ_FIRST(&hs->sc_queue)->hq_slave))
sc->sc_regs->hpib_mim = MIS_BO;
else if (cold)
/* timeouts not working yet */