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

Skip to content
Commit 94ffa3ab authored by Chandana Kishori Chiluveru's avatar Chandana Kishori Chiluveru Committed by Mayank Rana
Browse files

usb: gadget: Fix issue in queuing notification req upon function suspend



Selective suspend of device with remote-wakeup enabled by host
could race with device driver queuing a notification request on
interrupt endpoint. Driver calling usb_func_ep_queue() directly
and issues function wakeup command to controller and returns success to
the function driver. As a result notification request is not queued to
endpoint but returns with success and notify_req_queued remains true.
If function driver tries to queue any request further this results into
request drop as request is already queued.

Hence return -EAGAIN in usb_func_ep_queue to queue the notification request
upon function resume. Also initiate remote wakeup immediately after suspend
if notification request already queued to controller.

Change-Id: I7ac9231c44e8126a043886f5d6cedde491ff818d
Signed-off-by: default avatarChandana Kishori Chiluveru <cchiluve@codeaurora.org>
Signed-off-by: default avatarSriharsha Allenki <sallenki@codeaurora.org>
parent 018df480
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment