summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Walle <michael@walle.cc>2022-04-04 12:56:03 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-08-17 16:14:10 +0300
commite424ccda9c8b989df33f69006ab1ce89054cc034 (patch)
treed7c22b84bded623a300a36f8d20149120b65c34f
parentca18e97c52a73196a4bfe83c745f47ac218c91f0 (diff)
downloadlinux-e424ccda9c8b989df33f69006ab1ce89054cc034.tar.xz
soc: fsl: guts: machine variable might be unset
[ Upstream commit ab3f045774f704c4e7b6a878102f4e9d4ae7bc74 ] If both the model and the compatible properties are missing, then machine will not be set. Initialize it with NULL. Fixes: 34c1c21e94ac ("soc: fsl: fix section mismatch build warnings") Signed-off-by: Michael Walle <michael@walle.cc> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Shawn Guo <shawnguo@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org>
-rw-r--r--drivers/soc/fsl/guts.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/soc/fsl/guts.c b/drivers/soc/fsl/guts.c
index 5ed2fc1c53a0..be18d46c7b0f 100644
--- a/drivers/soc/fsl/guts.c
+++ b/drivers/soc/fsl/guts.c
@@ -140,7 +140,7 @@ static int fsl_guts_probe(struct platform_device *pdev)
struct device_node *root, *np = pdev->dev.of_node;
struct device *dev = &pdev->dev;
const struct fsl_soc_die_attr *soc_die;
- const char *machine;
+ const char *machine = NULL;
u32 svr;
/* Initialize guts */