Commit bf04362f authored by John Oldman's avatar John Oldman Committed by Greg Kroah-Hartman

staging: rtl8192e: Using comparison to true is error prone

clear below issues reported by checkpatch.pl:

CHECK: Using comparison to true is error prone
CHECK: Using comparison to false is error prone
Signed-off-by: default avatarJohn Oldman <john.oldman@polehill.co.uk>
Link: https://lore.kernel.org/r/20200521084732.12576-1-john.oldman@polehill.co.ukSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 728774f7
...@@ -456,7 +456,7 @@ static void _rtl92e_dm_bandwidth_autoswitch(struct net_device *dev) ...@@ -456,7 +456,7 @@ static void _rtl92e_dm_bandwidth_autoswitch(struct net_device *dev)
if (priv->CurrentChannelBW == HT_CHANNEL_WIDTH_20 || if (priv->CurrentChannelBW == HT_CHANNEL_WIDTH_20 ||
!priv->rtllib->bandwidth_auto_switch.bautoswitch_enable) !priv->rtllib->bandwidth_auto_switch.bautoswitch_enable)
return; return;
if (priv->rtllib->bandwidth_auto_switch.bforced_tx20Mhz == false) { if (!priv->rtllib->bandwidth_auto_switch.bforced_tx20Mhz) {
if (priv->undecorated_smoothed_pwdb <= if (priv->undecorated_smoothed_pwdb <=
priv->rtllib->bandwidth_auto_switch.threshold_40Mhzto20Mhz) priv->rtllib->bandwidth_auto_switch.threshold_40Mhzto20Mhz)
priv->rtllib->bandwidth_auto_switch.bforced_tx20Mhz = true; priv->rtllib->bandwidth_auto_switch.bforced_tx20Mhz = true;
...@@ -1297,7 +1297,7 @@ static void _rtl92e_dm_dig_init(struct net_device *dev) ...@@ -1297,7 +1297,7 @@ static void _rtl92e_dm_dig_init(struct net_device *dev)
static void _rtl92e_dm_ctrl_initgain_byrssi(struct net_device *dev) static void _rtl92e_dm_ctrl_initgain_byrssi(struct net_device *dev)
{ {
if (dm_digtable.dig_enable_flag == false) if (!dm_digtable.dig_enable_flag)
return; return;
if (dm_digtable.dig_algorithm == DIG_ALGO_BY_FALSE_ALARM) if (dm_digtable.dig_algorithm == DIG_ALGO_BY_FALSE_ALARM)
...@@ -1332,7 +1332,7 @@ static void _rtl92e_dm_ctrl_initgain_byrssi_driver(struct net_device *dev) ...@@ -1332,7 +1332,7 @@ static void _rtl92e_dm_ctrl_initgain_byrssi_driver(struct net_device *dev)
u8 i; u8 i;
static u8 fw_dig; static u8 fw_dig;
if (dm_digtable.dig_enable_flag == false) if (!dm_digtable.dig_enable_flag)
return; return;
if (dm_digtable.dig_algorithm_switch) if (dm_digtable.dig_algorithm_switch)
...@@ -1366,7 +1366,7 @@ static void _rtl92e_dm_ctrl_initgain_byrssi_false_alarm(struct net_device *dev) ...@@ -1366,7 +1366,7 @@ static void _rtl92e_dm_ctrl_initgain_byrssi_false_alarm(struct net_device *dev)
static u32 reset_cnt; static u32 reset_cnt;
u8 i; u8 i;
if (dm_digtable.dig_enable_flag == false) if (!dm_digtable.dig_enable_flag)
return; return;
if (dm_digtable.dig_algorithm_switch) { if (dm_digtable.dig_algorithm_switch) {
...@@ -1501,7 +1501,7 @@ static void _rtl92e_dm_initial_gain(struct net_device *dev) ...@@ -1501,7 +1501,7 @@ static void _rtl92e_dm_initial_gain(struct net_device *dev)
reset_cnt = 0; reset_cnt = 0;
} }
if (rtllib_act_scanning(priv->rtllib, true) == true) { if (rtllib_act_scanning(priv->rtllib, true)) {
force_write = 1; force_write = 1;
return; return;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment