[PATCH] dma: at_xdmac: fix a missing check on list iterator

Vinod Koul vkoul at kernel.org
Mon Apr 11 06:34:32 PDT 2022


On 27-03-22, 14:11, Xiaomeng Tong wrote:
> The bug is here:
> 	__func__, desc, &desc->tx_dma_desc.phys, ret, cookie, residue);
> 
> The list iterator 'desc' will point to a bogus position containing
> HEAD if the list is empty or no element is found. To avoid dev_dbg()
> prints a invalid address, use a new variable 'iter' as the list
> iterator, while use the origin variable 'desc' as a dedicated
> pointer to point to the found element.

Applied, thanks

-- 
~Vinod



More information about the linux-arm-kernel mailing list