On Mon, May 10, 2021 at 09:59:55AM -0500, Pierre-Louis Bossart wrote:
On 5/10/21 8:13 AM, Charles Keepax wrote: Sounds all good to me, just wondering if while you're at it you can fix the remaining minor issues? Thanks!
cppcheck --platform=unix64 --force --max-configs=1024 --inconclusive --enable=all --suppress=variableScope --suppress=shiftTooManyBitsSigned --suppress=arithOperationsOnVoidPointer --suppress=bitwiseOnBoolean sound/soc/codecs/cs*.c
sound/soc/codecs/cs35l36.c:1159:10: style: Variable 'ret' is assigned a value that is never used. [unreadVariable] int ret = 0; ^ sound/soc/codecs/cs4265.c:619:6: style: Variable 'ret' is reassigned a value before the old one has been used. [redundantAssignment] ret = devm_snd_soc_register_component(&i2c_client->dev, ^ sound/soc/codecs/cs4265.c:604:6: note: ret is assigned ret = regmap_read(cs4265->regmap, CS4265_CHIP_ID, ®); ^ sound/soc/codecs/cs4265.c:619:6: note: ret is overwritten ret = devm_snd_soc_register_component(&i2c_client->dev, ^ sound/soc/codecs/cs42l52.c:1202:6: style: Variable 'ret' is reassigned a value before the old one has been used. [redundantAssignment] ret = devm_snd_soc_register_component(&i2c_client->dev, ^ sound/soc/codecs/cs42l52.c:1165:6: note: ret is assigned ret = regmap_read(cs42l52->regmap, CS42L52_CHIP, ®); ^ sound/soc/codecs/cs42l52.c:1202:6: note: ret is overwritten ret = devm_snd_soc_register_component(&i2c_client->dev,
Apologies my cppcheck doesn't seem to generate these, I guess that is what I get for using the one that comes from using the one in the package manager rather than building an up to date one.
I will have a look at these extra warnings as well.
Thanks, Charles