mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
mt76: dma: introduce skb field in mt76_txwi_cache
Introduce skb field in mt76_txwi_cache. Moreover add txwi_flags to mt76_driver_ops since new chipsets will release mt76_txwi_cache/skbs at tx completion instead of dma one. This is a preliminary patch to add mt7615 support Signed-off-by: Lorenzo Bianconi <[email protected]>
This commit is contained in:
committed by
Felix Fietkau
parent
5007326555
commit
c47a5685d0
@@ -174,7 +174,8 @@ mt76_dma_tx_cleanup(struct mt76_dev *dev, enum mt76_txq_id qid, bool flush)
|
||||
dev->drv->tx_complete_skb(dev, qid, &entry);
|
||||
|
||||
if (entry.txwi) {
|
||||
mt76_put_txwi(dev, entry.txwi);
|
||||
if (!(dev->drv->txwi_flags & MT_TXWI_NO_FREE))
|
||||
mt76_put_txwi(dev, entry.txwi);
|
||||
wake = !flush;
|
||||
}
|
||||
|
||||
|
||||
@@ -233,6 +233,8 @@ struct mt76_txq {
|
||||
struct mt76_txwi_cache {
|
||||
struct list_head list;
|
||||
dma_addr_t dma_addr;
|
||||
|
||||
struct sk_buff *skb;
|
||||
};
|
||||
|
||||
struct mt76_rx_tid {
|
||||
@@ -286,7 +288,10 @@ struct mt76_hw_cap {
|
||||
bool has_5ghz;
|
||||
};
|
||||
|
||||
#define MT_TXWI_NO_FREE BIT(0)
|
||||
|
||||
struct mt76_driver_ops {
|
||||
u32 txwi_flags;
|
||||
u16 txwi_size;
|
||||
|
||||
void (*update_survey)(struct mt76_dev *dev);
|
||||
|
||||
Reference in New Issue
Block a user