Commit 9a66af9d authored by Sujeet Kumar's avatar Sujeet Kumar Committed by Gerrit - the friendly Code Review server
Browse files

USB: android: Dont call functionfs_bind during android enable



During composition switch, first sys.usb.config is set
to NONE. As part of this stop adb and android disable
is done. As part of android disable, functionfs_unbind
is not called and it depends on adb release
closed_callback.

On the other side, android enable is getting called.
This calls functionfs bind. At this point functionfs
bind returns with warning because the adb release
closed callback still not finished. Both android
enable and closed callback waits on android mutex
to be acquired. If closed callback gets the mutex
first, warning is not thrown. If android enable
gets the mutext first, warning is thrown. This
is the issue happening in this case.

There seem to be no need to call functionfs bind
in ffs_function_enable as the bind/unbind
should happen in respective ready/closed callbacks.

CRs-Fixed: 643538
Change-Id: Iba9d8322471370702a7d60fbe16cba33791db6a3
Signed-off-by: default avatarSujeet Kumar <ksujeet@codeaurora.org>
parent 74d6196a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment