Skip to contentSkip to conversation

staging: rtl8192e: Fix logical operator continuations

PATCH In review Sumitra Sharma 2 participants 3 messages Apr 8, 2023 – Apr 11, 2023 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 staging: rtl8192e: Fix logical operator continuations

Fix logical operator continuation as suggested by Linux kernel coding-style. Check reported by checkpatch:

CHECK: Logical continuations should be on the previous line

---
 drivers/staging/rtl8192e/rtl8192e/rtl_ps.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/rtl8192e/rtl8192e/rtl_ps.c +2 -2
index 5a1cd22f5e25..58ed394202ae 100644
@@ -209,8 +209,8 @@ void rtl92e_leisure_ps_enter(struct net_device *dev)
 					&priv->rtllib->pwr_save_ctrl;
 
 	if (!((priv->rtllib->iw_mode == IW_MODE_INFRA) &&
-	    (priv->rtllib->state == RTLLIB_LINKED))
-	    || (priv->rtllib->iw_mode == IW_MODE_ADHOC) ||
+	    (priv->rtllib->state == RTLLIB_LINKED)) ||
+	    (priv->rtllib->iw_mode == IW_MODE_ADHOC) ||
 	    (priv->rtllib->iw_mode == IW_MODE_MASTER))
 		return;
 
Signature · 1 line
2.25.1
#1 lore raw
Quoted 6 lines · Sumitra Sharma

Fix logical operator continuation as suggested by Linux kernel coding-style. Check reported by checkpatch:

CHECK: Logical continuations should be on the previous line

Hi Sumitra,

That commit message can be explicit, like "Move logical operator to previous line"

Alison

Quoted 22 lines
---
 drivers/staging/rtl8192e/rtl8192e/rtl_ps.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/rtl8192e/rtl8192e/rtl_ps.c +2 -2
index 5a1cd22f5e25..58ed394202ae 100644
@@ -209,8 +209,8 @@ void rtl92e_leisure_ps_enter(struct net_device *dev)
 					&priv->rtllib->pwr_save_ctrl;
 
 	if (!((priv->rtllib->iw_mode == IW_MODE_INFRA) &&
-	    (priv->rtllib->state == RTLLIB_LINKED))
-	    || (priv->rtllib->iw_mode == IW_MODE_ADHOC) ||
+	    (priv->rtllib->state == RTLLIB_LINKED)) ||
+	    (priv->rtllib->iw_mode == IW_MODE_ADHOC) ||
 	    (priv->rtllib->iw_mode == IW_MODE_MASTER))
 		return;
 
Signature · 1 line
2.25.1
#2 lore raw
Quoted 4 lines · Alison Schofield
Quoted 3 lines · Sumitra Sharma

Fix logical operator continuation as suggested by Linux kernel coding-style. Check reported by checkpatch:

Quoted 9 lines
Quoted 3 lines

CHECK: Logical continuations should be on the previous line

Hi Sumitra,

That commit message can be explicit, like "Move logical operator to previous line"

Hi Alison

Okay I will change it. Thank you.

Regards
Sumitra

Quoted 25 lines

Alison

Quoted 22 lines
---
 drivers/staging/rtl8192e/rtl8192e/rtl_ps.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/rtl8192e/rtl8192e/rtl_ps.c +2 -2
index 5a1cd22f5e25..58ed394202ae 100644
@@ -209,8 +209,8 @@ void rtl92e_leisure_ps_enter(struct net_device *dev)
 					&priv->rtllib->pwr_save_ctrl;
 
 	if (!((priv->rtllib->iw_mode == IW_MODE_INFRA) &&
-	    (priv->rtllib->state == RTLLIB_LINKED))
-	    || (priv->rtllib->iw_mode == IW_MODE_ADHOC) ||
+	    (priv->rtllib->state == RTLLIB_LINKED)) ||
+	    (priv->rtllib->iw_mode == IW_MODE_ADHOC) ||
 	    (priv->rtllib->iw_mode == IW_MODE_MASTER))
 		return;
 
Signature · 1 line
2.25.1