diff options
| author | Stefan Roese <[email protected]> | 2021-01-15 08:52:56 +0100 |
|---|---|---|
| committer | Marek Vasut <[email protected]> | 2021-02-10 22:23:24 +0100 |
| commit | cec804251d4b4765bbcaa207f4c931fef350585e (patch) | |
| tree | 1081ae9d2eb1da8e83c44fe1a263300ab3b6d251 /drivers | |
| parent | 5a5024fee073fea1b2f72601c4f3f006451fd176 (diff) | |
usb: xhci: Fix compare to use physical addresses in xhci_bulk_tx()
Testing with v2021.01 on MIPS Octeon has shown, that the latest patch
for the "short packet event trb handling" did introduce a bug on
platforms with virtual address != physical address. This patch fixes
this issue by using the correct address types in the compare (both
physical in this case).
Signed-off-by: Stefan Roese <[email protected]>
Cc: Aaron Williams <[email protected]>
Cc: Chandrakala Chavva <[email protected]>
Cc: Ran Wang <[email protected]>
Cc: Nicolas Saenz Julienne <[email protected]>
Cc: Marek Vasut <[email protected]>
Cc: Bin Meng <[email protected]>
Diffstat (limited to 'drivers')
| -rw-r--r-- | drivers/usb/host/xhci-ring.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/host/xhci-ring.c b/drivers/usb/host/xhci-ring.c index d708fc928b2..d6c47d579bc 100644 --- a/drivers/usb/host/xhci-ring.c +++ b/drivers/usb/host/xhci-ring.c @@ -723,8 +723,8 @@ again: return -ETIMEDOUT; } - if ((uintptr_t)(le64_to_cpu(event->trans_event.buffer)) - != (uintptr_t)last_transfer_trb_addr) { + if ((uintptr_t)(le64_to_cpu(event->trans_event.buffer)) != + (uintptr_t)virt_to_phys(last_transfer_trb_addr)) { available_length -= (int)EVENT_TRB_LEN(le32_to_cpu(event->trans_event.transfer_len)); xhci_acknowledge_event(ctrl); |
