mirror of
https://github.com/outbackdingo/mt76.git
synced 2026-10-24 13:26:48 +00:00
mt76: mmio: move mt76_insert_hdr_pad in mt76_dma_tx_queue_skb
Introduce tx_aligned4_skbs in mt76_driver_ops and move mt76_insert_hdr_pad in mt76_dma_tx_queue_skb. This is a preliminary patch in order to unify tx dma mapping for mt76x02 and new chipsets Signed-off-by: Lorenzo Bianconi <[email protected]> Signed-off-by: Felix Fietkau <[email protected]>
This commit is contained in:
committed by
Felix Fietkau
parent
0fe6386820
commit
efe9a473af
+5
-5
@@ -152,20 +152,20 @@ int mt76x02_tx_prepare_skb(struct mt76_dev *mdev, void *txwi_ptr,
|
||||
u32 *tx_info)
|
||||
{
|
||||
struct mt76x02_dev *dev = container_of(mdev, struct mt76x02_dev, mt76);
|
||||
struct ieee80211_hdr *hdr = (struct ieee80211_hdr *)skb->data;
|
||||
struct mt76x02_txwi *txwi = txwi_ptr;
|
||||
int qsel = MT_QSEL_EDCA;
|
||||
int pid;
|
||||
int hdrlen, len, pid, qsel = MT_QSEL_EDCA;
|
||||
|
||||
if (qid == MT_TXQ_PSD && wcid && wcid->idx < 128)
|
||||
mt76x02_mac_wcid_set_drop(dev, wcid->idx, false);
|
||||
|
||||
mt76x02_mac_write_txwi(dev, txwi, skb, wcid, sta, skb->len);
|
||||
hdrlen = ieee80211_hdrlen(hdr->frame_control);
|
||||
len = skb->len - (hdrlen & 2);
|
||||
mt76x02_mac_write_txwi(dev, txwi, skb, wcid, sta, len);
|
||||
|
||||
pid = mt76_tx_status_skb_add(mdev, wcid, skb);
|
||||
txwi->pktid = pid;
|
||||
|
||||
mt76_insert_hdr_pad(skb);
|
||||
|
||||
if (pid >= MT_PACKET_ID_FIRST)
|
||||
qsel = MT_QSEL_MGMT;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user