]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
usb: dwc3: core: Introduce glue callbacks for flattened implementations
authorKrishna Kurapati <krishna.kurapati@oss.qualcomm.com>
Sun, 7 Sep 2025 18:14:11 +0000 (23:44 +0530)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 12 Sep 2025 12:04:20 +0000 (14:04 +0200)
commit643df901f7ead35a71552a61927ad665a15aa87f
tree266cd661a703a5c99cf0ebca1e2cf64fb25c6d67
parent5df186e2ef11dca3fb6f0f332dc09c4ac0bed870
usb: dwc3: core: Introduce glue callbacks for flattened implementations

In certain situations like role switching, the glue layers need to be
informed of these events, so that they can take any necessary action.
But in non-flattened implementations, the glue drivers have no data on
when the core driver probe was successful post invoking of_platform_
populate. Now that the core driver supports flattened implementations
as well, introduce vendor callbacks that can be passed on from glue to
core before invoking dwc3_core_probe.

Introduce callbacks to notify glue layer of role_switch and run_stop
changes. These can be used by flattened implementation of Qualcomm
glue layer to generate connect/disconnect events in controller during
cable connect and run stop modifications by udc in device mode.

Acked-by: Thinh Nguyen <Thinh.Nguyen@synopsys.com>
Signed-off-by: Krishna Kurapati <krishna.kurapati@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20250907181412.2174616-2-krishna.kurapati@oss.qualcomm.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/dwc3/core.c
drivers/usb/dwc3/core.h
drivers/usb/dwc3/drd.c
drivers/usb/dwc3/gadget.c