Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 657232b6 authored by Lennert Buytenhek's avatar Lennert Buytenhek Committed by John W. Linville
Browse files

mwl8k: simplify sequence number assignment



By storing the sequence counter in << 4 format, like other drivers do.

Signed-off-by: default avatarLennert Buytenhek <buytenh@marvell.com>
Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
parent c97470dd
Loading
Loading
Loading
Loading
+2 −4
Original line number Original line Diff line number Diff line
@@ -1355,11 +1355,9 @@ mwl8k_txq_xmit(struct ieee80211_hw *hw, int index, struct sk_buff *skb)
	mwl8k_vif = MWL8K_VIF(tx_info->control.vif);
	mwl8k_vif = MWL8K_VIF(tx_info->control.vif);


	if (tx_info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ) {
	if (tx_info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ) {
		u16 seqno = mwl8k_vif->seqno;

		wh->seq_ctrl &= cpu_to_le16(IEEE80211_SCTL_FRAG);
		wh->seq_ctrl &= cpu_to_le16(IEEE80211_SCTL_FRAG);
		wh->seq_ctrl |= cpu_to_le16(seqno << 4);
		wh->seq_ctrl |= cpu_to_le16(mwl8k_vif->seqno);
		mwl8k_vif->seqno = seqno++ % 4096;
		mwl8k_vif->seqno += 0x10;
	}
	}


	/* Setup firmware control bit fields for each frame type.  */
	/* Setup firmware control bit fields for each frame type.  */