Skip to contentSkip to conversation

of: fdt: do not update local variable after use

PATCH Applied Ohhoon Kwon 2 participants 2 messages Aug 3, 2021 1 message not in the archive Device tree

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): CGME20210803101726epcas1p257df1a6ab948c39304f4246a95d039c3@epcas1p2.samsung.com

#1 lore raw

PATCH 1/1 of: fdt: do not update local variable after use

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;
             ^            ~~~~~~~~~
---
 drivers/of/fdt.c | 1 -
 1 file changed, 1 deletion(-)
drivers/of/fdt.c +0 -1
index bd35ba56aa96..5dc0b0310d7c 100644
@@ -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",
Signature · 1 line
2.32.0
maintainer Applied
#2 lore raw
Quoted 11 lines · Ohhoon Kwon

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;
             ^            ~~~~~~~~~
---
 drivers/of/fdt.c | 1 -
 1 file changed, 1 deletion(-)

Applied, thanks!