[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240628095831.207942-2-krzysztof.kozlowski@linaro.org>
Date: Fri, 28 Jun 2024 11:58:31 +0200
From: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To: Srinivas Kandagatla <srinivas.kandagatla@...aro.org>,
Banajit Goswami <bgoswami@...cinc.com>,
Liam Girdwood <lgirdwood@...il.com>,
Mark Brown <broonie@...nel.org>,
Jaroslav Kysela <perex@...ex.cz>,
Takashi Iwai <tiwai@...e.com>,
Dmitry Baryshkov <dmitry.baryshkov@...aro.org>,
Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>,
alsa-devel@...a-project.org,
linux-arm-msm@...r.kernel.org,
linux-sound@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH 2/2] ASoC: codecs: lpass-wsa-macro: Fix using NULL pointer in probe() dev_err
The 'wsa->dev' is assigned closer to the end of the probe() function, so
the dev_err() must not use it - it is still NULL at this point. Instead
there is already a local 'dev' variable.
Fixes: 727de4fbc546 ("ASoC: codecs: lpass-wsa-macro: Correct support for newer v2.5 version")
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
---
sound/soc/codecs/lpass-wsa-macro.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/lpass-wsa-macro.c b/sound/soc/codecs/lpass-wsa-macro.c
index f619b06b8aec..14e0cc4fbff3 100644
--- a/sound/soc/codecs/lpass-wsa-macro.c
+++ b/sound/soc/codecs/lpass-wsa-macro.c
@@ -2798,7 +2798,7 @@ static int wsa_macro_probe(struct platform_device *pdev)
break;
default:
- dev_err(wsa->dev, "Unsupported Codec version (%d)\n", wsa->codec_version);
+ dev_err(dev, "Unsupported Codec version (%d)\n", wsa->codec_version);
return -EINVAL;
}
--
2.43.0
Powered by blists - more mailing lists