summaryrefslogtreecommitdiffstats
path: root/sys/i4b
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2002-09-10 16:41:08 +0000
committerphk <phk@FreeBSD.org>2002-09-10 16:41:08 +0000
commit6be713fb9f040b0bfd6c2b4ffa536786f0513176 (patch)
treeedca7bd6db0affd04eb021ca165367914b986a15 /sys/i4b
parentfef1f5b9727a9a2020d743b202b4d1e16054517a (diff)
downloadFreeBSD-src-6be713fb9f040b0bfd6c2b4ffa536786f0513176.zip
FreeBSD-src-6be713fb9f040b0bfd6c2b4ffa536786f0513176.tar.gz
Add missing calls to mtx_init().
It seems counter-intuitive that all drivers have to do this. Pointed in right direction by: gj
Diffstat (limited to 'sys/i4b')
-rw-r--r--sys/i4b/layer1/itjc/i4b_itjc_pci.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/sys/i4b/layer1/itjc/i4b_itjc_pci.c b/sys/i4b/layer1/itjc/i4b_itjc_pci.c
index 4a13ee2..d528f62 100644
--- a/sys/i4b/layer1/itjc/i4b_itjc_pci.c
+++ b/sys/i4b/layer1/itjc/i4b_itjc_pci.c
@@ -1518,6 +1518,7 @@ itjc_attach(device_t dev)
void *ih = 0;
dma_context_t *ctx = &dma_context[unit];
+ l1_bchan_state_t *chan;
bzero(sc, sizeof(struct l1_softc));
@@ -1690,6 +1691,17 @@ itjc_attach(device_t dev)
/* init the ISAC */
itjc_isac_init(sc);
+ chan = &sc->sc_chan[HSCX_CH_A];
+ if(!mtx_initialized(&chan->rx_queue.ifq_mtx))
+ mtx_init(&chan->rx_queue.ifq_mtx, "i4b_avma1pp_rx", NULL, MTX_DEF);
+ if(!mtx_initialized(&chan->tx_queue.ifq_mtx))
+ mtx_init(&chan->tx_queue.ifq_mtx, "i4b_avma1pp_tx", NULL, MTX_DEF);
+ chan = &sc->sc_chan[HSCX_CH_B];
+ if(!mtx_initialized(&chan->rx_queue.ifq_mtx))
+ mtx_init(&chan->rx_queue.ifq_mtx, "i4b_avma1pp_rx", NULL, MTX_DEF);
+ if(!mtx_initialized(&chan->tx_queue.ifq_mtx))
+ mtx_init(&chan->tx_queue.ifq_mtx, "i4b_avma1pp_tx", NULL, MTX_DEF);
+
/* init the "HSCX" */
itjc_bchannel_setup(sc->sc_unit, HSCX_CH_A, BPROT_NONE, 0);
OpenPOWER on IntegriCloud