ASoC: max9867: fix type of variable containing error codes
PATCH 2/2 ASoC: max9867: fix type of variable containing error codes
value variable can contain error values and is compared with zero. Its type must be signed.
The problem has been detected using coccinelle script scripts/coccinelle/tests/unsigned_lesser_than_zero.cocci
--- sound/soc/codecs/max9867.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
sound/soc/codecs/max9867.c +2 -1
@@ -180,7 +180,8 @@ static int max9867_dai_hw_params(struct snd_pcm_substream *substream, {struct snd_soc_codec *codec = dai->codec;struct max9867_priv *max9867 =snd_soc_codec_get_drvdata (codec); -unsigned int ni_h, ni_l, value; +unsigned int ni_h, ni_l; +int value; value =get_ni_value (max9867->sysclk,params_rate (params));if (value <0 )
Signature · 1 line
1.9.1
2016-02-23 14:45 GMT+08:00 Andrzej Hajda <[email protected]>:
Quoted 2 lines
value variable can contain error values and is compared with zero. Its type must be signed.
Mark Brown
maintainerApplied "ASoC: max9867: fix type of variable containing error codes" to the asoc tree
In reply to Andrzej HajdaThe patch
ASoC: max9867: fix type of variable containing error codes
has been applied to the asoc tree at
git://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark
Quoted 1 line
From
127a9cbb5860a7cf15f4d4703ab0454e4603e8acMon Sep 17 00:00:00 2001
From: Andrzej Hajda <[email protected]>
Date: Tue, 23 Feb 2016 07:45:14 +0100
Subject: [PATCH] ASoC: max9867: fix type of variable containing error codes
value variable can contain error values and is compared with zero. Its type must be signed.
The problem has been detected using coccinelle script scripts/coccinelle/tests/unsigned_lesser_than_zero.cocci
--- sound/soc/codecs/max9867.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
sound/soc/codecs/max9867.c +2 -1
@@ -180,7 +180,8 @@ static int max9867_dai_hw_params(struct snd_pcm_substream *substream, {struct snd_soc_codec *codec = dai->codec;struct max9867_priv *max9867 =snd_soc_codec_get_drvdata (codec); -unsigned int ni_h, ni_l, value; +unsigned int ni_h, ni_l; +int value; value =get_ni_value (max9867->sysclk,params_rate (params));if (value <0 )
Signature · 1 line
2.7.0