OpenCloudOS-Kernel/drivers/usb/cdns3
Pawel Laszczak aafeabf276 usb: xhci: fix loss of data on Cadence xHC
[ Upstream commit e5fa8db0be3e8757e8641600c518425a4589b85c ]

Streams should flush their TRB cache, re-read TRBs, and start executing
TRBs from the beginning of the new dequeue pointer after a 'Set TR Dequeue
Pointer' command.

Cadence controllers may fail to start from the beginning of the dequeue
TRB as it doesn't clear the Opaque 'RsvdO' field of the stream context
during 'Set TR Dequeue' command. This stream context area is where xHC
stores information about the last partially executed TD when a stream
is stopped. xHC uses this information to resume the transfer where it left
mid TD, when the stream is restarted.

Patch fixes this by clearing out all RsvdO fields before initializing new
Stream transfer using a 'Set TR Dequeue Pointer' command.

Fixes: 3d82904559 ("usb: cdnsp: cdns3 Add main part of Cadence USBSSP DRD Driver")
cc: stable@vger.kernel.org
Signed-off-by: Pawel Laszczak <pawell@cadence.com>
Reviewed-by: Peter Chen <peter.chen@kernel.org>
Link: https://lore.kernel.org/r/PH7PR07MB95386A40146E3EC64086F409DD9D2@PH7PR07MB9538.namprd07.prod.outlook.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-10-04 16:29:58 +02: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
cdns3-debug.h
cdns3-ep0.c
cdns3-gadget.c usb: cdns3: fix memory double free when handle zero packet 2024-03-01 13:35:02 +01:00
cdns3-gadget.h usb: cdns3: fix iso transfer error when mult is not zero 2024-01-25 15:35:43 -08:00
cdns3-imx.c usb: cdns3: imx: Rework system PM to avoid duplicated operations 2023-05-29 15:53:48 +01:00
cdns3-pci-wrap.c
cdns3-plat.c usb: Explicitly include correct DT includes 2023-07-25 18:20:02 +02:00
cdns3-starfive.c usb: cdns3: starfive: Convert to platform remove callback returning void 2023-07-25 18:18:52 +02:00
cdns3-ti.c usb: Explicitly include correct DT includes 2023-07-25 18:20:02 +02:00
cdns3-trace.c
cdns3-trace.h
cdnsp-debug.h
cdnsp-ep0.c usb: cdnsp: Fixes error: uninitialized symbol 'len' 2023-04-05 19:55:04 +02:00
cdnsp-gadget.c usb: cdnsp: Fixes issue with dequeuing not queued requests 2023-10-02 13:19:13 +02:00
cdnsp-gadget.h usb: cdnsp: fix for Link TRB with TC 2024-09-04 13:28:30 +02:00
cdnsp-mem.c
cdnsp-pci.c usb: cdns3: Put the cdns set active part outside the spin lock 2023-07-25 17:49:25 +02:00
cdnsp-ring.c usb: cdnsp: Fix incorrect usb_request status 2024-10-04 16:29:50 +02:00
cdnsp-trace.c
cdnsp-trace.h
core.c usb: cdnsp: fixed issue with incorrect detecting CDNSP family controllers 2024-03-01 13:35:02 +01:00
core.h usb: cdns3: Modify the return value of cdns_set_active () to void when CONFIG_PM_SLEEP is disabled 2023-10-02 14:25:39 +02:00
drd.c usb: cdnsp: fixed issue with incorrect detecting CDNSP family controllers 2024-03-01 13:35:02 +01:00
drd.h usb: cdnsp: fixed issue with incorrect detecting CDNSP family controllers 2024-03-01 13:35:02 +01:00
gadget-export.h
host-export.h
host.c usb: xhci: fix loss of data on Cadence xHC 2024-10-04 16:29:58 +02:00