Commit d2a158d1 authored by Kalle Valo's avatar Kalle Valo
Browse files

Merge tag 'mt76-for-kvalo-2023-04-18' of https://github.com/nbd168/wireless

mt76 patches for 6.4

- fixes
- connac code unification
- mt7921 p2p support
- mt7996 mesh a-msdu support
- mt7996 eht support
- mt7996 coredump support
parents 6c6d62ae 3b522cad
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -111,6 +111,11 @@ properties:
    $ref: /schemas/leds/common.yaml#
    additionalProperties: false
    properties:
      led-active-low:
        description:
          LED is enabled with ground signal.
        type: boolean

      led-sources:
        maxItems: 1

+7 −3
Original line number Diff line number Diff line
@@ -402,8 +402,8 @@ mt76_dma_get_buf(struct mt76_dev *dev, struct mt76_queue *q, int idx,
		*info = le32_to_cpu(desc->info);

	if (mt76_queue_is_wed_rx(q)) {
		u32 token = FIELD_GET(MT_DMA_CTL_TOKEN,
				      le32_to_cpu(desc->buf1));
		u32 buf1 = le32_to_cpu(desc->buf1);
		u32 token = FIELD_GET(MT_DMA_CTL_TOKEN, buf1);
		struct mt76_txwi_cache *t = mt76_rx_token_release(dev, token);

		if (!t)
@@ -424,6 +424,8 @@ mt76_dma_get_buf(struct mt76_dev *dev, struct mt76_queue *q, int idx,

			*drop = !!(ctrl & (MT_DMA_CTL_TO_HOST_A |
					   MT_DMA_CTL_DROP));

			*drop |= !!(buf1 & MT_DMA_CTL_WO_DROP);
		}
	} else {
		buf = e->buf;
@@ -576,7 +578,9 @@ mt76_dma_tx_queue_skb(struct mt76_dev *dev, struct mt76_queue *q,
free_skb:
	status.skb = tx_info.skb;
	hw = mt76_tx_status_get_hw(dev, tx_info.skb);
	spin_lock_bh(&dev->rx_lock);
	ieee80211_tx_status_ext(hw, &status);
	spin_unlock_bh(&dev->rx_lock);

	return ret;
}
@@ -849,7 +853,7 @@ mt76_dma_rx_process(struct mt76_dev *dev, struct mt76_queue *q, int budget)
		    !(dev->drv->rx_check(dev, data, len)))
			goto free_frag;

		skb = build_skb(data, q->buf_size);
		skb = napi_build_skb(data, q->buf_size);
		if (!skb)
			goto free_frag;

+1 −0
Original line number Diff line number Diff line
@@ -19,6 +19,7 @@
#define MT_DMA_CTL_TO_HOST_A		BIT(12)
#define MT_DMA_CTL_DROP			BIT(14)
#define MT_DMA_CTL_TOKEN		GENMASK(31, 16)
#define MT_DMA_CTL_WO_DROP		BIT(8)

#define MT_DMA_PPE_CPU_REASON		GENMASK(15, 11)
#define MT_DMA_PPE_ENTRY		GENMASK(30, 16)
+12 −5
Original line number Diff line number Diff line
@@ -418,7 +418,8 @@ mt76_phy_init(struct mt76_phy *phy, struct ieee80211_hw *hw)
	SET_IEEE80211_DEV(hw, dev->dev);
	SET_IEEE80211_PERM_ADDR(hw, phy->macaddr);

	wiphy->features |= NL80211_FEATURE_ACTIVE_MONITOR;
	wiphy->features |= NL80211_FEATURE_ACTIVE_MONITOR |
			   NL80211_FEATURE_AP_MODE_CHAN_WIDTH_CHANGE;
	wiphy->flags |= WIPHY_FLAG_HAS_CHANNEL_SWITCH |
			WIPHY_FLAG_SUPPORTS_TDLS |
			WIPHY_FLAG_AP_UAPSD;
@@ -1066,9 +1067,14 @@ mt76_rx_convert(struct mt76_dev *dev, struct sk_buff *skb,
	status->enc_flags = mstat.enc_flags;
	status->encoding = mstat.encoding;
	status->bw = mstat.bw;
	if (status->encoding == RX_ENC_EHT) {
		status->eht.ru = mstat.eht.ru;
		status->eht.gi = mstat.eht.gi;
	} else {
		status->he_ru = mstat.he_ru;
		status->he_gi = mstat.he_gi;
		status->he_dcm = mstat.he_dcm;
	}
	status->rate_idx = mstat.rate_idx;
	status->nss = mstat.nss;
	status->band = mstat.band;
@@ -1303,6 +1309,7 @@ mt76_check_sta(struct mt76_dev *dev, struct sk_buff *skb)
	if (ps)
		set_bit(MT_WCID_FLAG_PS, &wcid->flags);

	if (dev->drv->sta_ps)
		dev->drv->sta_ps(dev, sta, ps);

	if (!ps)
+15 −4
Original line number Diff line number Diff line
@@ -621,12 +621,22 @@ struct mt76_rx_status {
	u16 freq;
	u32 flag;
	u8 enc_flags;
	u8 encoding:2, bw:3, he_ru:3;
	u8 he_gi:2, he_dcm:1;
	u8 encoding:3, bw:4;
	union {
		struct {
			u8 he_ru:3;
			u8 he_gi:2;
			u8 he_dcm:1;
		};
		struct {
			u8 ru:4;
			u8 gi:2;
		} eht;
	};

	u8 amsdu:1, first_amsdu:1, last_amsdu:1;
	u8 rate_idx;
	u8 nss;
	u8 band;
	u8 nss:5, band:3;
	s8 signal;
	u8 chains;
	s8 chain_signal[IEEE80211_MAX_CHAINS];
@@ -778,6 +788,7 @@ struct mt76_dev {
	spinlock_t rx_lock;
	struct napi_struct napi[__MT_RXQ_MAX];
	struct sk_buff_head rx_skb[__MT_RXQ_MAX];
	struct tasklet_struct irq_tasklet;

	struct list_head txwi_cache;
	struct list_head rxwi_cache;
Loading