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

Commit 4a68c408 authored by Mayank Rana's avatar Mayank Rana
Browse files

dwc3: gadget: remove usage of wait_event_lock_irq()



dwc3_gadget_ep_dequeue() API uses wait_event_lock_irq() which takes
mutex_lock(). Hence if function driver calls this API with interrupt
and preemption disable, it results into calling sleeping function
with preemption disable. wait_event_lock_irq() API is used to wait
for stop endpoint command completion, and already existing delay
should suffice. Hence fix this issue by removing usage of
wait_event_lock_irq() from dwc3_gadget_ep_dequeue() API.

Change-Id: If31e045b37334ddeddb6e2dfb23500f356806719
Signed-off-by: default avatarMayank Rana <mrana@codeaurora.org>
parent a8cbba84
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -1599,10 +1599,6 @@ static int dwc3_gadget_ep_dequeue(struct usb_ep *ep,
			 * consideration so we don't mess up our TRB ring
			 * pointers.
			 */
			wait_event_lock_irq(dep->wait_end_transfer,
					!(dep->flags & DWC3_EP_END_TRANSFER_PENDING),
					dwc->lock);

			if (!r->trb)
				goto out0;