summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/hw.c
diff options
context:
space:
mode:
authorAditya Srivastava <yashsri421@gmail.com>2021-01-10 15:15:23 +0300
committerKalle Valo <kvalo@codeaurora.org>2021-01-25 17:21:07 +0300
commit64338f0dfd6a3be20453789c6a4b2c7246e2aef8 (patch)
tree2a83a1fa7482fee5ea657b7a719e53b64d38501c /drivers/net/wireless/realtek/rtlwifi/rtl8188ee/hw.c
parentf7c76283fc5f532027404a346c69ebd111c92fdc (diff)
downloadlinux-64338f0dfd6a3be20453789c6a4b2c7246e2aef8.tar.xz
rtlwifi: rtl8188ee: fix bool comparison in expressions
There are certain conditional expressions in rtl8188ee, where a boolean variable is compared with true/false, in forms such as (foo == true) or (false != bar), which does not comply with checkpatch.pl (CHECK: BOOL_COMPARISON), according to which boolean variables should be themselves used in the condition, rather than comparing with true/false E.g., in drivers/net/wireless/realtek/rtlwifi/rtl8188ee/dm.c, "if (mac->act_scanning == true)" can be replaced with "if (mac->act_scanning)" Replace all such expressions with the bool variables appropriately Signed-off-by: Aditya Srivastava <yashsri421@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> Link: https://lore.kernel.org/r/20210110121525.2407-4-yashsri421@gmail.com
Diffstat (limited to 'drivers/net/wireless/realtek/rtlwifi/rtl8188ee/hw.c')
-rw-r--r--drivers/net/wireless/realtek/rtlwifi/rtl8188ee/hw.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/hw.c b/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/hw.c
index bd9160b166c5..861cc663ca93 100644
--- a/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/hw.c
+++ b/drivers/net/wireless/realtek/rtlwifi/rtl8188ee/hw.c
@@ -1269,12 +1269,12 @@ void rtl88ee_set_check_bssid(struct ieee80211_hw *hw, bool check_bssid)
if (rtlpriv->psc.rfpwr_state != ERFON)
return;
- if (check_bssid == true) {
+ if (check_bssid) {
reg_rcr |= (RCR_CBSSID_DATA | RCR_CBSSID_BCN);
rtlpriv->cfg->ops->set_hw_reg(hw, HW_VAR_RCR,
(u8 *)(&reg_rcr));
_rtl88ee_set_bcn_ctrl_reg(hw, 0, BIT(4));
- } else if (check_bssid == false) {
+ } else if (!check_bssid) {
reg_rcr &= (~(RCR_CBSSID_DATA | RCR_CBSSID_BCN));
_rtl88ee_set_bcn_ctrl_reg(hw, BIT(4), 0);
rtlpriv->cfg->ops->set_hw_reg(hw,