> On 2019-03-02 14:47, Lorenzo Bianconi wrote: > > Introduce mt76_sw_queue data structure in order to support new > > chipsets (e.g. mt7615) that have a shared hardware queue for all traffic > > identifiers. mt76_sw_queue will be used to track outstanding packets > > > > Signed-off-by: Lorenzo Bianconi <lorenzo@xxxxxxxxxx> > > --- > > drivers/net/wireless/mediatek/mt76/debugfs.c | 7 ++- > > drivers/net/wireless/mediatek/mt76/dma.c | 12 ++-- > > drivers/net/wireless/mediatek/mt76/mac80211.c | 4 +- > > drivers/net/wireless/mediatek/mt76/mt76.h | 16 ++++-- > > .../wireless/mediatek/mt76/mt7603/beacon.c | 8 +-- > > .../net/wireless/mediatek/mt76/mt7603/dma.c | 13 ++++- > > .../net/wireless/mediatek/mt76/mt7603/mac.c | 4 +- > > .../net/wireless/mediatek/mt76/mt7603/main.c | 2 +- > > .../net/wireless/mediatek/mt76/mt76x02_mmio.c | 19 +++++-- > > .../wireless/mediatek/mt76/mt76x02_usb_core.c | 2 +- > > .../net/wireless/mediatek/mt76/mt76x02_util.c | 2 +- > > drivers/net/wireless/mediatek/mt76/tx.c | 55 ++++++++++--------- > > drivers/net/wireless/mediatek/mt76/usb.c | 23 +++++--- > > 13 files changed, 100 insertions(+), 67 deletions(-) > > > Turns out this causes a crash on cleanup if not all queues are > initialized. I will fold in the following fix: > --- > --- a/drivers/net/wireless/mediatek/mt76/debugfs.c > +++ b/drivers/net/wireless/mediatek/mt76/debugfs.c > @@ -45,7 +45,7 @@ mt76_queues_read(struct seq_file *s, void *data) > for (i = 0; i < ARRAY_SIZE(dev->q_tx); i++) { > struct mt76_sw_queue *q = &dev->q_tx[i]; > > - if (!q->q->ndesc) > + if (!q->q) > continue; > > seq_printf(s, > --- a/drivers/net/wireless/mediatek/mt76/dma.c > +++ b/drivers/net/wireless/mediatek/mt76/dma.c > @@ -152,7 +152,7 @@ mt76_dma_tx_cleanup(struct mt76_dev *dev, enum mt76_txq_id qid, bool flush) > bool wake = false; > int last; > > - if (!q->ndesc) > + if (!q) > return; > > spin_lock_bh(&q->lock); ack, thx for fixing it. Regards, Lorenzo
Attachment:
signature.asc
Description: PGP signature