On 8/18/25 13:40, Anand Moon wrote:
Hi Andrew,

On Mon, 18 Aug 2025 at 14:54, Andrew Goodbody
<andrew.goodb...@linaro.org> wrote:

The timeout test in axi_dma_init is not correct due to the
post-decrement used on the timeout variable which will mean timeout is
not 0 if the timeout occurs. Make the timeout variable an int instead of
a u32 and then test for timeout being -1.

This issue was found by Smatch.

You can use read_poll_timeout instead of a while loop timeout?
he could use it but then this should be split to two reads because two conditions are checked and not sure if it is worth to do it.

Thanks,
Michal

Reply via email to