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

Commit f1f21770 authored by Larry Finger's avatar Larry Finger Committed by Kalle Valo
Browse files

rtlwifi: Remove extraneous argument for rate mapping



Four of the drivers (92ce, 92cu, 92de, and 92se) supply an argument to the
rate-mapping routine that is never used, thus it can be removed.

Signed-off-by: default avatarLarry Finger <Larry.Finger@lwfinger.net>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent 99057920
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -883,7 +883,7 @@ static u8 _rtl_get_highest_n_rate(struct ieee80211_hw *hw,
 * DESC92_RATEMCS0-->DESC92_RATEMCS15 ==> idx is 0-->15
 */
int rtlwifi_rate_mapping(struct ieee80211_hw *hw,
			 bool isht, u8 desc_rate, bool first_ampdu)
			 bool isht, u8 desc_rate)
{
	int rate_idx;

+1 −1
Original line number Diff line number Diff line
@@ -124,7 +124,7 @@ void rtl_deinit_deferred_work(struct ieee80211_hw *hw);

bool rtl_action_proc(struct ieee80211_hw *hw, struct sk_buff *skb, u8 is_tx);
int rtlwifi_rate_mapping(struct ieee80211_hw *hw,
			 bool isht, u8 desc_rate, bool first_ampdu);
			 bool isht, u8 desc_rate);
bool rtl_tx_mgmt_proc(struct ieee80211_hw *hw, struct sk_buff *skb);
u8 rtl_is_special_data(struct ieee80211_hw *hw, struct sk_buff *skb, u8 is_tx);

+2 −3
Original line number Diff line number Diff line
@@ -400,9 +400,8 @@ bool rtl92ce_rx_query_desc(struct ieee80211_hw *hw,
	 * are use (RX_FLAG_HT)
	 * Notice: this is diff with windows define
	 */
	rx_status->rate_idx = rtlwifi_rate_mapping(hw,
				stats->is_ht, stats->rate,
				stats->isfirst_ampdu);
	rx_status->rate_idx = rtlwifi_rate_mapping(hw, stats->is_ht,
						   stats->rate);

	rx_status->mactime = stats->timestamp_low;
	if (phystatus) {
+2 −4
Original line number Diff line number Diff line
@@ -340,8 +340,7 @@ bool rtl92cu_rx_query_desc(struct ieee80211_hw *hw,
		rx_status->flag |= RX_FLAG_DECRYPTED;
	rx_status->rate_idx = rtlwifi_rate_mapping(hw,
					(bool)GET_RX_DESC_RX_HT(pdesc),
					(u8)GET_RX_DESC_RX_MCS(pdesc),
					(bool)GET_RX_DESC_PAGGR(pdesc));
					(u8)GET_RX_DESC_RX_MCS(pdesc));
	rx_status->mactime = GET_RX_DESC_TSFL(pdesc);
	if (phystatus) {
		p_drvinfo = (struct rx_fwinfo_92c *)(skb->data +
@@ -408,8 +407,7 @@ static void _rtl_rx_process(struct ieee80211_hw *hw, struct sk_buff *skb)
	/* Data rate */
	rx_status->rate_idx = rtlwifi_rate_mapping(hw,
					(bool)GET_RX_DESC_RX_HT(rxdesc),
					(u8)GET_RX_DESC_RX_MCS(rxdesc),
					(bool)GET_RX_DESC_PAGGR(rxdesc));
					(u8)GET_RX_DESC_RX_MCS(rxdesc));
	/*  There is a phy status after this rx descriptor. */
	if (GET_RX_DESC_PHY_STATUS(rxdesc)) {
		p_drvinfo = (struct rx_fwinfo_92c *)(rxdesc + RTL_RX_DESC_SIZE);
+1 −2
Original line number Diff line number Diff line
@@ -514,8 +514,7 @@ bool rtl92de_rx_query_desc(struct ieee80211_hw *hw, struct rtl_stats *stats,
		rx_status->flag |= RX_FLAG_DECRYPTED;
	rx_status->rate_idx = rtlwifi_rate_mapping(hw,
					(bool)GET_RX_DESC_RXHT(pdesc),
					(u8)GET_RX_DESC_RXMCS(pdesc),
					(bool)GET_RX_DESC_PAGGR(pdesc));
					(u8)GET_RX_DESC_RXMCS(pdesc));
	rx_status->mactime = GET_RX_DESC_TSFL(pdesc);
	if (phystatus) {
		p_drvinfo = (struct rx_fwinfo_92d *)(skb->data +
Loading