Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 72c5df1a authored by qctecmdr Service's avatar qctecmdr Service Committed by Gerrit - the friendly Code Review server
Browse files

Merge "usb: dwc3: Do not traverse list using list_for_each_safe"

parents 760c0f8f 2b3d90ae
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -2804,15 +2804,16 @@ static int __dwc3_cleanup_done_trbs(struct dwc3 *dwc, struct dwc3_ep *dep,
static int dwc3_cleanup_done_reqs(struct dwc3 *dwc, struct dwc3_ep *dep,
		const struct dwc3_event_depevt *event, int status)
{
	struct dwc3_request	*req, *n;
	struct dwc3_request	*req;
	struct dwc3_trb		*trb;
	bool			ioc = false;
	int			ret = 0;

	list_for_each_entry_safe(req, n, &dep->started_list, list) {
	while (!list_empty(&dep->started_list)) {
		unsigned length;
		int chain;

		req = next_request(&dep->started_list);
		length = req->request.length;
		chain = req->num_pending_sgs > 0;
		if (chain) {