Re: [PATCH] ASoC: tegra: Fix -Wuninitialized in tegra210_amx_platform_probe()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 11, 2023 at 01:21:51PM -0700, Nathan Chancellor wrote:
> Clang warns (or errors with CONFIG_WERROR=y):
> 
>   sound/soc/tegra/tegra210_amx.c:553:10: error: variable 'soc_data' is uninitialized when used here [-Werror,-Wuninitialized]
>     553 |                                             soc_data->regmap_conf);
>         |                                             ^~~~~~~~
> 
> A refactoring removed the initialization of this variable but its use
> was not updated. Use the soc_data value in the amx variable to resolve
> the warning and remove the soc_data variable, as it is now entirely
> unused.
> 
> Closes: https://github.com/ClangBuiltLinux/linux/issues/1943
> Fixes: 9958d85968ed ("ASoC: Use device_get_match_data()")
> Signed-off-by: Nathan Chancellor <nathan@xxxxxxxxxx>
> ---
>  sound/soc/tegra/tegra210_amx.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)

I see that Mark was quicker and this is already applied, but just for
the record, this fixes an OOPS that I started seeing recently but hadn't
gotten around to look at more closely, so I guess:

Tested-by: Thierry Reding <treding@xxxxxxxxxx>

And thanks!

Thierry

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [ARM Kernel]     [Linux ARM]     [Linux ARM MSM]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux