OSDN Git Service

usb: dwc3: gadget: Introduce a DWC3 VBUS draw callback
authorWesley Cheng <wcheng@codeaurora.org>
Tue, 29 Dec 2020 23:03:29 +0000 (15:03 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 4 Jan 2021 15:45:35 +0000 (16:45 +0100)
commit82c46b8ed9dc395df902c1857e908f08f8395ca7
treeab8f0e2d7ef5f216aa009205be6b1b9ed1b34625
parent9b3bd898421bd9fca5c88a3c3291d9f60df3bb69
usb: dwc3: gadget: Introduce a DWC3 VBUS draw callback

Some devices support charging while in device mode.  In these situations,
the USB gadget will notify the DWC3 gadget driver to modify the current
based on the enumeration and device state.  The usb_phy_set_power() API
will allow external charger entities to adjust the charge current through
the notifier block.

Reviewed-by: Peter Chen <peter.chen@nxp.com>
Signed-off-by: Wesley Cheng <wcheng@codeaurora.org>
Link: https://lore.kernel.org/r/1609283011-21997-2-git-send-email-wcheng@codeaurora.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/dwc3/gadget.c