[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y+dT6du6Nysyd8/t@ubun2204.myguest.virtualbox.org>
Date: Sat, 11 Feb 2023 14:08:01 +0530
From: Deepak R Varma <drv@...lo.com>
To: Florian Fainelli <f.fainelli@...il.com>,
Broadcom internal kernel review list
<bcm-kernel-feedback-list@...adcom.com>,
linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org
Cc: Saurabh Singh Sengar <ssengar@...rosoft.com>,
Praveen Kumar <kumarpraveen@...ux.microsoft.com>,
Deepak R Varma <drv@...lo.com>
Subject: [PATCH] soc: brcmstb: pm-arm: Remove duplicate/repeating constant
Constant DDR_PHY_RST_N is unnecessarily or'ed with itself. Remove
the redundant constant from the expression.
Issue identified using doublebitand.cocci Coccinelle semantic patch.
Signed-off-by: Deepak R Varma <drv@...lo.com>
---
Please note: I was unable to build the change though I had the appropriate
config, arch and cross compiler. I used the following:
.config = bmips_stb_defconfig
ARCH=mips
CROSS_COMPILE=/usr/bin/mips-linux-gnu-
BRCMSTB_PM=y
Let me know what I missed so I can build the objects myself. Thank you.
drivers/soc/bcm/brcmstb/pm/pm-arm.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/soc/bcm/brcmstb/pm/pm-arm.c b/drivers/soc/bcm/brcmstb/pm/pm-arm.c
index d681cd24c6e1..633e715446f7 100644
--- a/drivers/soc/bcm/brcmstb/pm/pm-arm.c
+++ b/drivers/soc/bcm/brcmstb/pm/pm-arm.c
@@ -288,7 +288,7 @@ static inline void s5entry_method1(void)
/* Step 3: Channel A (RST_N = CKE = 0) */
tmp = readl_relaxed(ctrl.memcs[i].ddr_phy_base +
ctrl.phy_a_standby_ctrl_offs);
- tmp &= ~(DDR_PHY_RST_N | DDR_PHY_RST_N);
+ tmp &= ~DDR_PHY_RST_N;
writel_relaxed(tmp, ctrl.memcs[i].ddr_phy_base +
ctrl.phy_a_standby_ctrl_offs);
@@ -296,7 +296,7 @@ static inline void s5entry_method1(void)
if (ctrl.phy_b_standby_ctrl_offs != DDR_PHY_NO_CHANNEL) {
tmp = readl_relaxed(ctrl.memcs[i].ddr_phy_base +
ctrl.phy_b_standby_ctrl_offs);
- tmp &= ~(DDR_PHY_RST_N | DDR_PHY_RST_N);
+ tmp &= ~DDR_PHY_RST_N;
writel_relaxed(tmp, ctrl.memcs[i].ddr_phy_base +
ctrl.phy_b_standby_ctrl_offs);
}
--
2.34.1
Powered by blists - more mailing lists