lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Thu, 22 Sep 2022 12:58:00 +0100
From:   Colin Ian King <colin.i.king@...il.com>
To:     Tony Luck <tony.luck@...el.com>, Borislav Petkov <bp@...en8.de>,
        Mauro Carvalho Chehab <mchehab@...nel.org>,
        James Morse <james.morse@....com>,
        Robert Richter <rric@...nel.org>, linux-edac@...r.kernel.org
Cc:     kernel-janitors@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH] EDAC, pnd2: remove redundant initialization to variable mot_intlv_bit

Variable mot_intlv_bit is being initialized with a value that
is never read, it is being reassigned later on with a different
value. The initialization is redundant and can be removed.

Cleans up clang scan-build warning:
drivers/edac/pnd2_edac.c:627:6: warning: Value stored to 'mot_intlv_bit'
during its initialization is never read [deadcode.DeadStores]

Signed-off-by: Colin Ian King <colin.i.king@...il.com>
---
 drivers/edac/pnd2_edac.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/edac/pnd2_edac.c b/drivers/edac/pnd2_edac.c
index a20b299f1202..eba2e6d9bd8f 100644
--- a/drivers/edac/pnd2_edac.c
+++ b/drivers/edac/pnd2_edac.c
@@ -624,8 +624,7 @@ static int hash_by_mask(u64 addr, u64 mask)
 static int sys2pmi(const u64 addr, u32 *pmiidx, u64 *pmiaddr, char *msg)
 {
 	u64 contig_addr, contig_base, contig_offset, contig_base_adj;
-	int mot_intlv_bit = two_slices ? MOT_CHAN_INTLV_BIT_2SLC_2CH :
-						MOT_CHAN_INTLV_BIT_1SLC_2CH;
+	int mot_intlv_bit;
 	int slice_intlv_bit_rm = SELECTOR_DISABLED;
 	int chan_intlv_bit_rm = SELECTOR_DISABLED;
 	/* Determine if address is in the MOT region. */
-- 
2.37.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ