usb: dwc3: core: do not use 3.0 clock when operating in 2.0 mode
authorBin Yang <yangbin@rock-chips.com>
Mon, 28 Feb 2022 13:56:56 +0000 (08:56 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 15 Mar 2022 14:40:42 +0000 (15:40 +0100)
commit62b20e6e0dde8d5633e3d94b028f86fb24b31d22
tree018aa3b3004cac7af010246c083a34333cab9bd8
parent62a13a9c0046b2224af6aa6e39c54f89a06245d4
usb: dwc3: core: do not use 3.0 clock when operating in 2.0 mode

In the 3.0 device core, if the core is programmed to operate in
2.0 only, then setting the GUCTL1.DEV_FORCE_20_CLK_FOR_30_CLK makes
the internal 2.0(utmi/ulpi) clock to be routed as the 3.0 (pipe)
clock. Enabling this feature allows the pipe3 clock to be not-running
when forcibly operating in 2.0 device mode.

Tested-by: Michael Riesch <michael.riesch@wolfvision.net>
Signed-off-by: Bin Yang <yangbin@rock-chips.com>
Signed-off-by: Peter Geis <pgwipeout@gmail.com>
Link: https://lore.kernel.org/r/20220228135700.1089526-6-pgwipeout@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/dwc3/core.c
drivers/usb/dwc3/core.h