3
0
Fork 0
forked from mirrors/linux
kernel/drivers/usb/cdns3
Pawel Laszczak 241e2ce88e usb: cdnsp: Fix issue with resuming from L1
In very rare cases after resuming controller from L1 to L0 it reads
registers before the clock UTMI have been enabled and as the result
driver reads incorrect value.
Most of registers are in APB domain clock but some of them (e.g. PORTSC)
are in UTMI domain clock.
After entering to L1 state the UTMI clock can be disabled.
When controller transition from L1 to L0 the port status change event is
reported and in interrupt runtime function driver reads PORTSC.
During this read operation controller synchronize UTMI and APB domain
but UTMI clock is still disabled and in result it reads 0xFFFFFFFF value.
To fix this issue driver increases APB timeout value.

The issue is platform specific and if the default value of APB timeout
is not sufficient then this time should be set Individually for each
platform.

Fixes: 3d82904559 ("usb: cdnsp: cdns3 Add main part of Cadence USBSSP DRD Driver")
Cc: stable <stable@kernel.org>
Signed-off-by: Pawel Laszczak <pawell@cadence.com>
Acked-by: Peter Chen <peter.chen@kernel.org>
Link: https://lore.kernel.org/r/PH7PR07MB953846C57973E4DB134CAA71DDBF2@PH7PR07MB9538.namprd07.prod.outlook.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2025-05-01 17:36:12 +02:00
..
cdns3-debug.h usb: cdns3: change trace event cdns3_ring() operation 2023-03-09 15:35:03 +01:00
cdns3-ep0.c
cdns3-gadget.c usb: cdns3: Fix deadlock when using NCM gadget 2025-04-11 16:20:59 +02:00
cdns3-gadget.h usb: cdns3: fix iso transfer error when mult is not zero 2024-01-04 16:01:44 +01:00
cdns3-imx.c usb: Switch back to struct platform_driver::remove() 2024-10-04 15:13:03 +02:00
cdns3-pci-wrap.c usb: cdns3: Synchronise PCI IDs via common data base 2024-11-13 07:16:31 +01:00
cdns3-plat.c usb: Switch back to struct platform_driver::remove() 2024-10-04 15:13:03 +02:00
cdns3-starfive.c usb: Switch back to struct platform_driver::remove() 2024-10-04 15:13:03 +02:00
cdns3-ti.c usb: cdns3-ti: run HW init at resume() if HW was reset 2025-03-14 09:18:02 +01:00
cdns3-trace.c
cdns3-trace.h tracing/treewide: Remove second parameter of __assign_str() 2024-05-22 20:14:47 -04:00
cdnsp-debug.h usb: cdnsp: Replace snprintf() with the safer scnprintf() variant 2023-12-04 22:25:17 +09:00
cdnsp-ep0.c usb: cdnsp: Fixes error: uninitialized symbol 'len' 2023-04-05 19:55:04 +02:00
cdnsp-gadget.c usb: cdnsp: Fix issue with resuming from L1 2025-05-01 17:36:12 +02:00
cdnsp-gadget.h usb: cdnsp: Fix issue with resuming from L1 2025-05-01 17:36:12 +02:00
cdnsp-mem.c
cdnsp-pci.c usb: cdnsp: Fix issue with resuming from L1 2025-05-01 17:36:12 +02:00
cdnsp-ring.c usb: cdnsp: Fix incorrect usb_request status 2024-09-11 15:35:23 +02:00
cdnsp-trace.c
cdnsp-trace.h tracing/treewide: Remove second parameter of __assign_str() 2024-05-22 20:14:47 -04:00
core.c usb: cdns3: call cdns_power_is_lost() only once in cdns_resume() 2025-03-14 09:18:02 +01:00
core.h usb: cdnsp: Fix issue with resuming from L1 2025-05-01 17:36:12 +02:00
drd.c usb: cdns3: Add quirk flag to enable suspend residency 2024-06-04 15:41:10 +02:00
drd.h usb: cdns3: Add quirk flag to enable suspend residency 2024-06-04 15:41:10 +02:00
gadget-export.h
host-export.h
host.c usb: host: cdns3: forward lost power information to xhci 2025-03-14 09:18:03 +01:00
Kconfig usb: cdns3: Add StarFive JH7110 USB driver 2023-05-29 15:52:11 +01:00
Makefile usb: cdns3: Add StarFive JH7110 USB driver 2023-05-29 15:52:11 +01:00