diff options
author | mlaier <mlaier@FreeBSD.org> | 2007-02-03 13:53:22 +0000 |
---|---|---|
committer | mlaier <mlaier@FreeBSD.org> | 2007-02-03 13:53:22 +0000 |
commit | 9a2ac087c9aca2cf0a14bfa77f5265683c5e06b8 (patch) | |
tree | 121582af478b10ebfeb878a7d7cc8a06fa5b5c09 | |
parent | e297f369ca116565e98034eea29b8385e939d8f9 (diff) | |
download | FreeBSD-src-9a2ac087c9aca2cf0a14bfa77f5265683c5e06b8.zip FreeBSD-src-9a2ac087c9aca2cf0a14bfa77f5265683c5e06b8.tar.gz |
Add ALTQ support for aue(4).
Tested by: Greg Hennessy, Volker
MFC after: 1 week
-rw-r--r-- | share/man/man4/altq.4 | 1 | ||||
-rw-r--r-- | sys/dev/usb/if_aue.c | 12 |
2 files changed, 8 insertions, 5 deletions
diff --git a/share/man/man4/altq.4 b/share/man/man4/altq.4 index 460a37e..8cc2202 100644 --- a/share/man/man4/altq.4 +++ b/share/man/man4/altq.4 @@ -117,6 +117,7 @@ are required to use a certain network card with They have been applied to the following hardware drivers: .Xr an 4 , .Xr ath 4 , +.Xr aue 4 , .Xr awi 4 , .Xr bce 4 , .Xr bfe 4 , diff --git a/sys/dev/usb/if_aue.c b/sys/dev/usb/if_aue.c index e51a6f8..348e6ef 100644 --- a/sys/dev/usb/if_aue.c +++ b/sys/dev/usb/if_aue.c @@ -722,7 +722,9 @@ USB_ATTACH(aue) ifp->if_ioctl = aue_ioctl; ifp->if_start = aue_start; ifp->if_init = aue_init; - ifp->if_snd.ifq_maxlen = IFQ_MAXLEN; + IFQ_SET_MAXLEN(&ifp->if_snd, IFQ_MAXLEN); + ifp->if_snd.ifq_drv_maxlen = IFQ_MAXLEN; + IFQ_SET_READY(&ifp->if_snd); /* * Do MII setup. @@ -1002,7 +1004,7 @@ aue_tick_thread(struct aue_softc *sc) if (!sc->aue_link && mii->mii_media_status & IFM_ACTIVE && IFM_SUBTYPE(mii->mii_media_active) != IFM_NONE) { sc->aue_link++; - if (ifp->if_snd.ifq_head != NULL) + if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) aue_start_thread(sc); } resched: @@ -1079,13 +1081,13 @@ aue_start_thread(struct aue_softc *sc) return; } - IF_DEQUEUE(&ifp->if_snd, m_head); + IFQ_DRV_DEQUEUE(&ifp->if_snd, m_head); if (m_head == NULL) { return; } if (aue_encap(sc, m_head, 0)) { - IF_PREPEND(&ifp->if_snd, m_head); + IFQ_DRV_PREPEND(&ifp->if_snd, m_head); ifp->if_drv_flags |= IFF_DRV_OACTIVE; return; } @@ -1321,7 +1323,7 @@ aue_watchdog(struct aue_softc *sc) c->ue_status = stat; aue_txeof_thread(sc); - if (ifp->if_snd.ifq_head != NULL) + if (!IFQ_IS_EMPTY(&ifp->if_snd)) aue_start_thread(sc); return; } |