mirror of
https://github.com/LineageOS/android_kernel_samsung_msm8226.git
synced 2026-10-05 00:00:57 +02:00
Some peripherals share the USB connector, such as MHL, in which the ID pin is queried for voltage level determining the type of cable connected. Support this by allowing these peripherals to act as clients that can register for ID event notification. The registered callback is called upon ID state change, and when it returns 0, USB assumes the client is now handling the connection from this point. When the client is done, it will call the USB callback (passed as function parameter) indicating offline, at which point USB can continue to assume a USB connection. Change-Id: I4abe2c8ba9610ffa28895dfeb641fb625ada7c51 Signed-off-by: Jack Pham <jackp@codeaurora.org>