diff options
| author | Arnd Bergmann <[email protected]> | 2024-11-13 17:57:13 +0000 |
|---|---|---|
| committer | Mark Brown <[email protected]> | 2024-11-14 11:42:41 +0000 |
| commit | c48a4497356f701f94f1951626637ae240af909e (patch) | |
| tree | f2d58d147ccda7e8c4f347d4c0d8374d37cad92a /drivers/fpga/altera-fpga2sdram.c | |
| parent | ASoC: Merge up fixes (diff) | |
| download | kernel-c48a4497356f701f94f1951626637ae240af909e.tar.gz kernel-c48a4497356f701f94f1951626637ae240af909e.zip | |
ASoC: sma1307: fix uninitialized variable refence
When firmware loading is disabled, gcc warns that the local
'fw' variable fails to get initialized:
sound/soc/codecs/sma1307.c: In function 'sma1307_setting_loaded.isra':
sound/soc/codecs/sma1307.c:1717:12: error: 'fw' is used uninitialized [-Werror=uninitialized]
1717 | if (!fw) {
| ^
sound/soc/codecs/sma1307.c:1712:32: note: 'fw' was declared here
1712 | const struct firmware *fw;
Check the return code from request_firmware() to ensure that the
firmware is correctly set, and drop the incorrect release_firmware()
on that uninitialized data.
Fixes: 576c57e6b4c1 ("ASoC: sma1307: Add driver for Iron Device SMA1307")
Signed-off-by: Arnd Bergmann <[email protected]>
Link: https://patch.msgid.link/[email protected]
Signed-off-by: Mark Brown <[email protected]>
Diffstat (limited to 'drivers/fpga/altera-fpga2sdram.c')
0 files changed, 0 insertions, 0 deletions
