ral: Don't use IF_ macros on ifnet.if_snd
authorSepherosa Ziehau <sephe@dragonflybsd.org>
Thu, 3 Jan 2013 03:52:31 +0000 (11:52 +0800)
committerSepherosa Ziehau <sephe@dragonflybsd.org>
Thu, 3 Jan 2013 03:52:31 +0000 (11:52 +0800)
sys/dev/netif/ral/rt2560.c
sys/dev/netif/ral/rt2661.c

index 8136f5d..b027d99 100644 (file)
@@ -1916,11 +1916,11 @@ rt2560_start_locked(struct ifnet *ifp)
        struct ieee80211_node *ni;
 
        for (;;) {
-               IF_DEQUEUE(&ifp->if_snd, m);
+               m = ifq_dequeue(&ifp->if_snd, NULL);
                if (m == NULL)
                        break;
                if (sc->txq.queued >= RT2560_TX_RING_COUNT - 1) {
-                       IF_PREPEND(&ifp->if_snd, m);
+                       ifq_prepend(&ifp->if_snd, m);
                        ifq_set_oactive(&ifp->if_snd);
                        sc->sc_flags |= RT2560_F_DATA_OACTIVE;
                        break;
index 605a48e..cf7ac86 100644 (file)
@@ -1619,14 +1619,14 @@ rt2661_start_locked(struct ifnet *ifp)
                return;
 
        for (;;) {
-               IF_DEQUEUE(&ifp->if_snd, m);
+               m = ifq_dequeue(&ifp->if_snd, NULL);
                if (m == NULL)
                        break;
 
                ac = M_WME_GETAC(m);
                if (sc->txq[ac].queued >= RT2661_TX_RING_COUNT - 1) {
                        /* there is no place left in this ring */
-                       IF_PREPEND(&ifp->if_snd, m);
+                       ifq_prepend(&ifp->if_snd, m);
                        ifq_set_oactive(&ifp->if_snd);
                        break;
                }