]> git.baikalelectronics.ru Git - kernel.git/commit
ASoC: intel: initialize return value properly
authorArnd Bergmann <arnd@arndb.de>
Mon, 6 Nov 2017 13:30:36 +0000 (14:30 +0100)
committerMark Brown <broonie@kernel.org>
Tue, 7 Nov 2017 10:55:25 +0000 (11:55 +0100)
commit24296fe7c4210a61fc820d37516132cd1e274e47
tree4571f73079ab7b4eeafc3bf4bcd4d4648029f0df
parentddfa05d40991ceb087bc9fc05d98ee9dccebc017
ASoC: intel: initialize return value properly

When CONFIG_SND_SOC_HDAC_HDMI is disabled, we can run into an
uninitialized variable:

sound/soc/intel/skylake/skl.c: In function 'skl_resume':
sound/soc/intel/skylake/skl.c:326:6: error: 'ret' may be used uninitialized in this function [-Werror=maybe-uninitialized]

I have run into this on today's linux-next kernel, but it appears
that this is an older problem that was just hard to trigger
with randconfig builds as CONFIG_SND_SOC_HDAC_HDMI would in
effect be impossible to disable when having SND_SOC_INTEL_SKYLAKE
enabled.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Acked-By: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/intel/skylake/skl.c