mirror_ubuntu-kernels/drivers/usb/gadget/udc/bdc
Jakob Koschel b6af554427 usb: gadget: bdc: remove usage of list iterator past the loop body
If the list representing the request queue does not contain the expected
request, the value of the list_for_each_entry() iterator will not point
to a valid structure. To avoid type confusion in such case, the list
iterator scope will be limited to the list_for_each_entry() loop.

In preparation to limiting scope of the list iterator to the list traversal
loop, use a dedicated pointer to point to the found request object [1].

Link: https://lore.kernel.org/all/YhdfEIwI4EdtHdym@kroah.com/
Signed-off-by: Jakob Koschel <jakobkoschel@gmail.com>
Link: https://lore.kernel.org/r/20220308171818.384491-3-jakobkoschel@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2022-03-15 18:19:43 +01:00
..
bdc_cmd.c usb: gadget: bdc: remove unnecessary AND operation when get ep maxp 2021-08-13 13:05:51 +02:00
bdc_cmd.h usb: gadget: bdc: add identifier name for function declaraion 2021-01-13 11:24:02 +01:00
bdc_core.c usb: bdc: fix error handling code in bdc_resume 2021-12-03 13:50:43 +01:00
bdc_dbg.c usb: gadget: bdc: fix warning of embedded function name 2021-01-13 11:24:02 +01:00
bdc_dbg.h usb: gadget: bdc: add identifier name for function declaraion 2021-01-13 11:24:02 +01:00
bdc_ep.c usb: gadget: bdc: remove usage of list iterator past the loop body 2022-03-15 18:19:43 +01:00
bdc_ep.h usb: gadget: bdc: add identifier name for function declaraion 2021-01-13 11:24:02 +01:00
bdc_udc.c usb: gadget: bdc: fix checkpatch.pl spacing error 2021-01-13 11:24:02 +01:00
bdc.h usb: gadget: bdc: use the BIT macro to define bit filed 2021-01-13 11:24:02 +01:00
Kconfig usb: bdc: Remove the BDC PCI driver 2021-01-18 18:36:31 +01:00
Makefile usb: bdc: Remove the BDC PCI driver 2021-01-18 18:36:31 +01:00