Searched hist:c09b1f37 (Results 1 – 1 of 1) sorted by relevance
/openbmc/linux/drivers/usb/gadget/udc/ |
H A D | aspeed_udc.c | c09b1f37 Sat Jun 18 03:54:20 CDT 2022 Dan Carpenter <dan.carpenter@oracle.com> usb: gadget: aspeed_udc: cleanup loop in ast_dma_descriptor_setup()
The "chunk >= 0" condition does not work because count is a u32. Also, really we shouldn't enter the loop when "chunk" is zero.
Once that condition is fixed then there is no need for the "last" variable. I reversed the "if (chunk <= ep->chunk_max)" as well. The new loop is much simpler.
Fixes: 055276c13205 ("usb: gadget: add Aspeed ast2600 udc driver") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Link: https://lore.kernel.org/r/Yq2SvM2bbrtSd1H9@kili Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
|