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

Skip to content
Commit 3689dffd authored by Manu Gautam's avatar Manu Gautam Committed by Stephen Boyd
Browse files

usb: u_bam: Free endpoint request buffer on disconnect



Some controller drivers (e.g. DWC3) keep a mapping between USB
request and its corresponding endpoint on request allocation.
This is later used by DCD when request is queued.
During USB disconnect, u_bam disables IN ep and adds the request
back to tx_idle pool instead of freeing it. This USB request in
idle pool may point to invalid EP if composition switch happens
resulting in u_bam's IN EP getting assigned to some other function.
Later when u_bam tries to enqueue this request again, DCD may queue
to the old EP now used by some other function. Fix this by freeing
usb_request on disconnect.

Change-Id: I0f18a8c85fce636bab4bb4e5bb7e85365339f2a9
CRs-Fixed: 468071
Signed-off-by: default avatarManu Gautam <mgautam@codeaurora.org>
parent 88f3dfb7
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