13951ccfcd
Coverity reports a possible integer overflow because routine aspeeed_smc_hclk_divisor() has a codepath returning 0, which could lead to an integer overflow when computing variable 'hclk_shift' in the caller aspeed_smc_dma_calibration(). The value passed to aspeed_smc_hclk_divisor() is always between 0 and 15 and, in this case, there is always a matching hclk divisor. Remove the return 0 and use g_assert_not_reached() instead. Fixes: Coverity CID 1547822 Suggested-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Cédric Le Goater <clg@redhat.com> Reviewed-by: Peter Maydell <peter.maydell@linaro.org> |
||
---|---|---|
.. | ||
aspeed_smc.c | ||
bcm2835_spi.c | ||
ibex_spi_host.c | ||
imx_spi.c | ||
Kconfig | ||
meson.build | ||
mss-spi.c | ||
npcm7xx_fiu.c | ||
npcm_pspi.c | ||
omap_spi.c | ||
pl022.c | ||
sifive_spi.c | ||
ssi.c | ||
stm32f2xx_spi.c | ||
trace-events | ||
trace.h | ||
xilinx_spi.c | ||
xilinx_spips.c | ||
xlnx-versal-ospi.c |