[PATCH] of: fdt: do not update local variable after use

Subsystems: open firmware and flattened device tree, the rest

STALE1905d LANDED

Landed in mainline as 4409273b818c on 2021-08-03.

2 messages, 2 authors, 2021-08-03 · open the first message on its own page

[PATCH] of: fdt: do not update local variable after use

From: Ohhoon Kwon <hidden>
Date: 2021-08-03 10:17:33

Fix the below warning:
drivers/of/fdt.c:196:4: warning: Value stored to 'pprev' is never read
[clang-analyzer-deadcode.DeadStores]
             pprev      = &pp->next;
             ^            ~~~~~~~~~

Signed-off-by: Ohhoon Kwon <redacted>
---
 drivers/of/fdt.c | 1 -
 1 file changed, 1 deletion(-)
diff --git a/drivers/of/fdt.c b/drivers/of/fdt.c
index bd35ba56aa96..5dc0b0310d7c 100644
--- a/drivers/of/fdt.c
+++ b/drivers/of/fdt.c
@@ -193,7 +193,6 @@ static void populate_properties(const void *blob,
 			pp->length = len;
 			pp->value  = pp + 1;
 			*pprev     = pp;
-			pprev      = &pp->next;
 			memcpy(pp->value, ps, len - 1);
 			((char *)pp->value)[len - 1] = 0;
 			pr_debug("fixed up name for %s -> %s\n",
-- 
2.32.0

Re: [PATCH] of: fdt: do not update local variable after use

From: Rob Herring <robh@kernel.org>
Date: 2021-08-03 20:20:07

On Tue, 03 Aug 2021 19:13:09 +0900, Ohhoon Kwon wrote:
Fix the below warning:
drivers/of/fdt.c:196:4: warning: Value stored to 'pprev' is never read
[clang-analyzer-deadcode.DeadStores]
             pprev      = &pp->next;
             ^            ~~~~~~~~~

Signed-off-by: Ohhoon Kwon <redacted>
---
 drivers/of/fdt.c | 1 -
 1 file changed, 1 deletion(-)
Applied, thanks!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help