Staging: rtl8188eu: core: rtw_pwrctrl.c: Fix a comparision warning.
PATCH 1/1 Staging: rtl8188eu: core: rtw_pwrctrl.c: Fix a comparision warning.
Replace the constant at the right side of comparision. Issue found by checkpatch.pl semantic patch results for rtw_ap.c
WARNING:Comparision should place the constant on the right side of the test.
--- drivers/staging/rtl8188eu/core/rtw_pwrctrl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/rtl8188eu/core/rtw_pwrctrl.c +1 -1
@@ -374,7 +374,7 @@ void rtw_set_ps_mode(struct adapter *padapter, u8 ps_mode, u8 smart_ps, u8 bcn_a }if (pwrpriv->pwr_mode == ps_mode) { -if (PS_MODE_ACTIVE == ps_mode) +if (ps_mode ==PS_MODE_ACTIVE )return ; if ((pwrpriv->smart_ps == smart_ps) &&
Signature · 1 line
2.17.1
Quoted 1 line · Sanjana Sanikommu
Replace the constant at the right side of comparision.
Replace suggests that there was one cnstant, and now you want to use a different one. What you did would be better described as "move the constant to the right side...".
julia
Quoted 33 lines
Issue found by checkpatch.pl semantic patch results for
rtw_ap.cWARNING:Comparision should place the constant on the right side of the test.
Signed-off-by Sanjana Sanikommu <[email protected]>--- drivers/staging/rtl8188eu/core/rtw_pwrctrl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/staging/rtl8188eu/core/rtw_pwrctrl.c +1
-2@@ -374,7 +374,7 @@ void rtw_set_ps_mode(struct adapter *padapter, u8 ps_mode, u8 smart_ps, u8 bcn_a }if (pwrpriv->pwr_mode == ps_mode) { -if (PS_MODE_ACTIVE == ps_mode) +if (ps_mode ==PS_MODE_ACTIVE )return ; if ((pwrpriv->smart_ps == smart_ps) && --2.17.1
--
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/20190318123121.11548-1-sanjana99reddy99%40gmail.com.
For more options, visit https://groups.google.com/d/optout.
Quoted 5 lines · Julia Lawall
On Mon, 18 Mar 2019, Sanjana Sanikommu wrote:
Quoted 7 lines
Quoted 1 line
Replace the constant at the right side of comparision.
Replace suggests that there was one cnstant, and now you want to use a different one. What you did would be better described as "move the constant to the right side...".
I would change the log message. Thank you for correcting me.
Sanjana
Quoted 43 lines
julia
Review
Quoted 11 lines
Issue found by checkpatch.pl semantic patch results for
rtw_ap.cWARNING:Comparision should place the constant on the right side of the test.
Signed-off-by Sanjana Sanikommu <[email protected] <javascript:>>---
drivers/staging/rtl8188eu/core/rtw_pwrctrl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)(quoted diff) +0
-0
b/drivers/staging/rtl8188eu/core/rtw_pwrctrl.cdrivers/staging/rtl8188eu/core/rtw_pwrctrl.c void rtw_set_ps_mode(struct adapter *padapter, u8
Quoted 4 lines
index
6a846d08d449..7b16632048b7100644drivers/staging/rtl8188eu/core/rtw_pwrctrl.c +0
-0@@ -374,7 +374,7 @@ void rtw_set_ps_mode(struct adapter *padapter, u8
ps_mode, u8smart_ps, u8bcn_aQuoted 13 lines
drivers/staging/rtl8188eu/core/rtw_pwrctrl.c +1
-1}if (pwrpriv->pwr_mode == ps_mode) { -if (PS_MODE_ACTIVE == ps_mode) +if (ps_mode ==PS_MODE_ACTIVE )return ; if ((pwrpriv->smart_ps == smart_ps) &&Signature · 4 lines
2.17.1 -- You received this message because you are subscribed to the GoogleGroups "outreachy-kernel" group.
Quoted 1 line
To unsubscribe from this group and stop receiving emails from it, send
an email to [email protected] <javascript:>.
Quoted 1 line
To post to this group, send email to [email protected]
<javascript:>.
Quoted 1 line
To view this discussion on the web visit
Quoted 2 lines
For more options, visit https://groups.google.com/d/optout.
PATCH v2 1/1 Staging: rtl8188eu: core: rtw_pwrctrl.c: Fix a comparision warning.
In reply to Sanjana SanikommuMove the constant to the right side of comparision. Issue found by checkpatch.pl semantic patch results for rtw_ap.c
WARNING:Comparision should place the constant on the right side of the test.
---
Changes in v2:
Correction of log message
drivers/staging/rtl8188eu/core/rtw_pwrctrl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/rtl8188eu/core/rtw_pwrctrl.c +1 -1
@@ -374,7 +374,7 @@ void rtw_set_ps_mode(struct adapter *padapter, u8 ps_mode, u8 smart_ps, u8 bcn_a }if (pwrpriv->pwr_mode == ps_mode) { -if (PS_MODE_ACTIVE == ps_mode) +if (ps_mode ==PS_MODE_ACTIVE )return ; if ((pwrpriv->smart_ps == smart_ps) &&
Signature · 1 line
2.17.1