diff options
author | Xiaomeng Tong <xiam0nd.tong@gmail.com> | 2022-03-27 09:11:54 +0300 |
---|---|---|
committer | Vinod Koul <vkoul@kernel.org> | 2022-04-11 16:33:29 +0300 |
commit | 206680c4e46b62fd8909385e0874a36952595b85 (patch) | |
tree | ac0730d794636f639dbaf3efef1f392215fd72b9 /drivers/siox | |
parent | a3ae97f4c87d9570e7e9a3e3324c443757f6e29a (diff) | |
download | linux-206680c4e46b62fd8909385e0874a36952595b85.tar.xz |
dma: at_xdmac: fix a missing check on list iterator
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.
Cc: stable@vger.kernel.org
Fixes: 82e2424635f4c ("dmaengine: xdmac: fix print warning on dma_addr_t variable")
Signed-off-by: Xiaomeng Tong <xiam0nd.tong@gmail.com>
Link: https://lore.kernel.org/r/20220327061154.4867-1-xiam0nd.tong@gmail.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/siox')
0 files changed, 0 insertions, 0 deletions