]> git.proxmox.com Git - mirror_ubuntu-jammy-kernel.git/commit
ASoC: samsung: s3c24xx_simtec: add missing error check
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Fri, 19 Feb 2021 23:09:14 +0000 (17:09 -0600)
committerMark Brown <broonie@kernel.org>
Wed, 10 Mar 2021 13:06:50 +0000 (13:06 +0000)
commit0587e83c5d8bc09af005bd736234b480a8fd66f2
tree2aa5826085436e142515ab2c62459f5dc3b9fc9b
parent5a81abc2ea3d7cc094b3bef16b0fb0157b8ced0f
ASoC: samsung: s3c24xx_simtec: add missing error check

cppcheck warning:

sound/soc/samsung/s3c24xx_simtec.c:191:7: style: Variable 'ret' is
assigned a value that is never used. [unreadVariable]
  ret = snd_soc_dai_set_clkdiv(cpu_dai, S3C24XX_DIV_PRESCALER,
      ^

Looking at the code, it's not clear why the return value is checked in
the two other cases but not here, so mirror the behavior and add a
check.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org>
Link: https://lore.kernel.org/r/20210219230918.5058-3-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/samsung/s3c24xx_simtec.c