]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
wifi: b43: Stop/wake correct queue in PIO Tx path when QoS is disabled
authorRahul Rameshbabu <sergeantsagara@protonmail.com>
Sun, 31 Dec 2023 05:03:45 +0000 (05:03 +0000)
committerKalle Valo <kvalo@kernel.org>
Wed, 10 Jan 2024 14:56:17 +0000 (16:56 +0200)
When QoS is disabled, the queue priority value will not map to the correct
ieee80211 queue since there is only one queue. Stop/wake queue 0 when QoS
is disabled to prevent trying to stop/wake a non-existent queue and failing
to stop/wake the actual queue instantiated.

Fixes: 5100d5ac81b9 ("b43: Add PIO support for PCMCIA devices")
Signed-off-by: Rahul Rameshbabu <sergeantsagara@protonmail.com>
Reviewed-by: Julian Calaby <julian.calaby@gmail.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://msgid.link/20231231050300.122806-3-sergeantsagara@protonmail.com
drivers/net/wireless/broadcom/b43/pio.c

index 0cf70fdb60a6ab5cb4723b46efe5aadd972ffd5c..e41f2f5b4c2664ccf8eeaa78fd2b7ced529fb7c3 100644 (file)
@@ -525,7 +525,7 @@ int b43_pio_tx(struct b43_wldev *dev, struct sk_buff *skb)
        if (total_len > (q->buffer_size - q->buffer_used)) {
                /* Not enough memory on the queue. */
                err = -EBUSY;
-               ieee80211_stop_queue(dev->wl->hw, skb_get_queue_mapping(skb));
+               b43_stop_queue(dev, skb_get_queue_mapping(skb));
                q->stopped = true;
                goto out;
        }
@@ -552,7 +552,7 @@ int b43_pio_tx(struct b43_wldev *dev, struct sk_buff *skb)
        if (((q->buffer_size - q->buffer_used) < roundup(2 + 2 + 6, 4)) ||
            (q->free_packet_slots == 0)) {
                /* The queue is full. */
-               ieee80211_stop_queue(dev->wl->hw, skb_get_queue_mapping(skb));
+               b43_stop_queue(dev, skb_get_queue_mapping(skb));
                q->stopped = true;
        }
 
@@ -587,7 +587,7 @@ void b43_pio_handle_txstatus(struct b43_wldev *dev,
        list_add(&pack->list, &q->packets_list);
 
        if (q->stopped) {
-               ieee80211_wake_queue(dev->wl->hw, q->queue_prio);
+               b43_wake_queue(dev, q->queue_prio);
                q->stopped = false;
        }
 }