summaryrefslogtreecommitdiff
path: root/sound/soc/pxa
diff options
context:
space:
mode:
authorDan Murphy <dmurphy@ti.com>2020-05-26 20:52:47 +0300
committerMark Brown <broonie@kernel.org>2020-05-27 16:48:55 +0300
commit850ba84b5c6d4ad4d1259584ebc0338eb769f2ef (patch)
tree021ed5ddafc023255e2fe26df10c7056a1f90bba /sound/soc/pxa
parent920bef64cc5fa0e955be357bfc876179729df216 (diff)
downloadlinux-850ba84b5c6d4ad4d1259584ebc0338eb769f2ef.tar.xz
ASoC: tlv320adcx140: Fix warnings when using W=1
Fix the warnings when using the W=1 compiler flag. sound/soc/codecs/tlv320adcx140.c: In function ‘adcx140_reset’: sound/soc/codecs/tlv320adcx140.c:570:6: warning: variable ‘ret’ set but not used [-Wunused-but-set-variable] 570 | int ret = 0; | ^~~ This was set but only used in case where the reset GPIO is not defined. Have the function return the value of ret. sound/soc/codecs/tlv320adcx140.c: In function ‘adcx140_codec_probe’: sound/soc/codecs/tlv320adcx140.c:778:18: warning: comparison of unsigned expression < 0 is always false [-Wtype-limits] 778 | if (bias_source < ADCX140_MIC_BIAS_VAL_VREF || | ^ sound/soc/codecs/tlv320adcx140.c:789:18: warning: comparison of unsigned expression < 0 is always false [-Wtype-limits] 789 | if (vref_source < ADCX140_MIC_BIAS_VREF_275V || This condition will not occur since if the dt property is not set then the *_source variable is set to the default value. So there is no way that *_source can be less then 0. Which is what each #define is set to. The code just needs to make sure that the dt property is not out of the upper bounds. Reported-by: kbuild test robot <lkp@intel.com> Signed-off-by: Dan Murphy <dmurphy@ti.com> Link: https://lore.kernel.org/r/20200526175247.15309-1-dmurphy@ti.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/pxa')
0 files changed, 0 insertions, 0 deletions