diff options
| author | Dan Carpenter <dan.carpenter@linaro.org> | 2025-01-08 12:28:46 +0300 |
|---|---|---|
| committer | Mark Brown <broonie@kernel.org> | 2025-01-08 12:36:57 +0000 |
| commit | 82a0a3e6f8c02b3236b55e784a083fa4ee07c321 (patch) | |
| tree | 76962c116874c54773811078293580253b92b643 /scripts/gdb/linux/proc.py | |
| parent | 9c3d68ce5dee76f30b23ca29b2be4774e291f7f1 (diff) | |
ASoC: renesas: rz-ssi: Add a check for negative sample_space
My static checker rule complains about this code. The concern is that
if "sample_space" is negative then the "sample_space >= runtime->channels"
condition will not work as intended because it will be type promoted to a
high unsigned int value.
strm->fifo_sample_size is SSI_FIFO_DEPTH (32). The SSIFSR_TDC_MASK is
0x3f. Without any further context it does seem like a reasonable warning
and it can't hurt to add a check for negatives.
Cc: stable@vger.kernel.org
Fixes: 03e786bd4341 ("ASoC: sh: Add RZ/G2L SSIF-2 driver")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Link: https://patch.msgid.link/e07c3dc5-d885-4b04-a742-71f42243f4fd@stanley.mountain
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'scripts/gdb/linux/proc.py')
0 files changed, 0 insertions, 0 deletions
