mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-27 12:25:08 +07:00
rtlwifi: update RCR register in rtl_op_configure_filter()
Reconfigure RCR register in rtl_op_configure_filter() in order to apply RX filter configuration Signed-off-by: Lorenzo Bianconi <lorenzo.bianconi83@gmail.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
This commit is contained in:
parent
c15d789e3c
commit
99958588fc
@ -786,6 +786,7 @@ static void rtl_op_configure_filter(struct ieee80211_hw *hw,
|
|||||||
unsigned int changed_flags,
|
unsigned int changed_flags,
|
||||||
unsigned int *new_flags, u64 multicast)
|
unsigned int *new_flags, u64 multicast)
|
||||||
{
|
{
|
||||||
|
bool update_rcr = false;
|
||||||
struct rtl_priv *rtlpriv = rtl_priv(hw);
|
struct rtl_priv *rtlpriv = rtl_priv(hw);
|
||||||
struct rtl_mac *mac = rtl_mac(rtl_priv(hw));
|
struct rtl_mac *mac = rtl_mac(rtl_priv(hw));
|
||||||
|
|
||||||
@ -806,6 +807,7 @@ static void rtl_op_configure_filter(struct ieee80211_hw *hw,
|
|||||||
RT_TRACE(rtlpriv, COMP_MAC80211, DBG_LOUD,
|
RT_TRACE(rtlpriv, COMP_MAC80211, DBG_LOUD,
|
||||||
"Disable receive multicast frame\n");
|
"Disable receive multicast frame\n");
|
||||||
}
|
}
|
||||||
|
update_rcr = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (changed_flags & FIF_FCSFAIL) {
|
if (changed_flags & FIF_FCSFAIL) {
|
||||||
@ -818,6 +820,8 @@ static void rtl_op_configure_filter(struct ieee80211_hw *hw,
|
|||||||
RT_TRACE(rtlpriv, COMP_MAC80211, DBG_LOUD,
|
RT_TRACE(rtlpriv, COMP_MAC80211, DBG_LOUD,
|
||||||
"Disable receive FCS error frame\n");
|
"Disable receive FCS error frame\n");
|
||||||
}
|
}
|
||||||
|
if (!update_rcr)
|
||||||
|
update_rcr = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* if ssid not set to hw don't check bssid
|
/* if ssid not set to hw don't check bssid
|
||||||
@ -832,6 +836,8 @@ static void rtl_op_configure_filter(struct ieee80211_hw *hw,
|
|||||||
rtlpriv->cfg->ops->set_chk_bssid(hw, false);
|
rtlpriv->cfg->ops->set_chk_bssid(hw, false);
|
||||||
else
|
else
|
||||||
rtlpriv->cfg->ops->set_chk_bssid(hw, true);
|
rtlpriv->cfg->ops->set_chk_bssid(hw, true);
|
||||||
|
if (update_rcr)
|
||||||
|
update_rcr = false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -846,6 +852,8 @@ static void rtl_op_configure_filter(struct ieee80211_hw *hw,
|
|||||||
RT_TRACE(rtlpriv, COMP_MAC80211, DBG_LOUD,
|
RT_TRACE(rtlpriv, COMP_MAC80211, DBG_LOUD,
|
||||||
"Disable receive control frame.\n");
|
"Disable receive control frame.\n");
|
||||||
}
|
}
|
||||||
|
if (!update_rcr)
|
||||||
|
update_rcr = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (changed_flags & FIF_OTHER_BSS) {
|
if (changed_flags & FIF_OTHER_BSS) {
|
||||||
@ -858,7 +866,13 @@ static void rtl_op_configure_filter(struct ieee80211_hw *hw,
|
|||||||
RT_TRACE(rtlpriv, COMP_MAC80211, DBG_LOUD,
|
RT_TRACE(rtlpriv, COMP_MAC80211, DBG_LOUD,
|
||||||
"Disable receive other BSS's frame.\n");
|
"Disable receive other BSS's frame.\n");
|
||||||
}
|
}
|
||||||
|
if (!update_rcr)
|
||||||
|
update_rcr = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (update_rcr)
|
||||||
|
rtlpriv->cfg->ops->set_hw_reg(hw, HW_VAR_RCR,
|
||||||
|
(u8 *)(&mac->rx_conf));
|
||||||
}
|
}
|
||||||
static int rtl_op_sta_add(struct ieee80211_hw *hw,
|
static int rtl_op_sta_add(struct ieee80211_hw *hw,
|
||||||
struct ieee80211_vif *vif,
|
struct ieee80211_vif *vif,
|
||||||
|
Loading…
Reference in New Issue
Block a user