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

Commit 814277d9 authored by Tarun Gupta's avatar Tarun Gupta Committed by Jack Pham
Browse files

USB: f_fs: Don't queue already queued request again



f_fs uses only one request per ep and driver is trying to queue
same request again before it completed. This is seen in following
scenario, as part of system suspend wait_for_completion was
interrupted by -ERESTARTSYS, and driver tried to dequeue this
request, as USB was in LPM it was unable to dequeue this and
later on system resume ffs_epfile_read tried to queue same
request again which was never dequeued or completed. ep_queue
will return error if same request is queued again while it is in
progress. User space considers this ep_queue failure as halt and
try to clear halt condition that never happened. When User space
is trying to clear halt by that time USB has entered LPM again
leading to crash.

Avoid this by making sure same request is not queued again until
it is completed.

CRs-Fixed: 813068
Change-Id: I6e9f357b9b8a47753b1323b4308e60844d7dec94
Signed-off-by: default avatarTarun Gupta <tarung@codeaurora.org>
Signed-off-by: default avatarJack Pham <jackp@codeaurora.org>
parent a5f9d251
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