mirror of
https://github.com/openwrt/openwrt.git
synced 2025-01-01 11:36:49 +00:00
21549dbf7b
Update patch set for new release and add required kernel option
CONFIG_ZRAM_TRACK_ENTRY_ACTIME to generic config
Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.66
Manually rebased:
bcm27xx/patches-6.6/950-0092-MMC-added-alternative-MMC-driver.patch
bcm53xx/patches-6.6/180-usb-xhci-add-support-for-performing-fake-doorbell.patch
starfive/patches-6.6/1000-serial-8250_dw-Add-starfive-jh7100-hsuart-compatible.patch
Removed upstreamed:
bcm27xx/patches-6.6/950-0029-vc4_hdmi-Avoid-log-spam-for-audio-start-failure.patch[1]
All other patches automatically rebased.
1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.66&id=e0388a95736abd1f5f5a94221dd1ac24eacbd4d7
Build system: x86/64
Build-tested: bcm27xx/bcm2712, flogic/glinet_gl-mt6000, flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3, x86/64
Run-tested: bcm27xx/bcm2712, flogic/glinet_gl-mt6000, flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3, x86/64
Signed-off-by: John Audia <therealgraysky@proton.me>
Link: https://github.com/openwrt/openwrt/pull/17271
(cherry picked from commit 28f534d953
)
Link: https://github.com/openwrt/openwrt/pull/17302
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
72 lines
2.5 KiB
Diff
72 lines
2.5 KiB
Diff
From a956051a926b0a9e0bc587303ce1a2e153707e80 Mon Sep 17 00:00:00 2001
|
|
From: Dom Cobley <popcornmix@gmail.com>
|
|
Date: Mon, 31 Jul 2023 13:47:10 +0100
|
|
Subject: [PATCH 0061/1085] Revert "Revert "xhci: add quirk for host
|
|
controllers that don't update endpoint DCS""
|
|
|
|
This reverts commit 5bef4b3cb95a5b883dfec8b3ffc0d671323d55bb.
|
|
|
|
We don't agree with upstream revert so undo it.
|
|
---
|
|
drivers/usb/host/xhci-pci.c | 4 +++-
|
|
drivers/usb/host/xhci-ring.c | 25 ++++++++++++++++++++++++-
|
|
2 files changed, 27 insertions(+), 2 deletions(-)
|
|
|
|
--- a/drivers/usb/host/xhci-pci.c
|
|
+++ b/drivers/usb/host/xhci-pci.c
|
|
@@ -480,8 +480,10 @@ static void xhci_pci_quirks(struct devic
|
|
pdev->device == 0x3432)
|
|
xhci->quirks |= XHCI_BROKEN_STREAMS;
|
|
|
|
- if (pdev->vendor == PCI_VENDOR_ID_VIA && pdev->device == 0x3483)
|
|
+ if (pdev->vendor == PCI_VENDOR_ID_VIA && pdev->device == 0x3483) {
|
|
xhci->quirks |= XHCI_LPM_SUPPORT;
|
|
+ xhci->quirks |= XHCI_EP_CTX_BROKEN_DCS;
|
|
+ }
|
|
|
|
if (pdev->vendor == PCI_VENDOR_ID_ASMEDIA &&
|
|
pdev->device == PCI_DEVICE_ID_ASMEDIA_1042_XHCI) {
|
|
--- a/drivers/usb/host/xhci-ring.c
|
|
+++ b/drivers/usb/host/xhci-ring.c
|
|
@@ -633,8 +633,11 @@ static int xhci_move_dequeue_past_td(str
|
|
struct xhci_ring *ep_ring;
|
|
struct xhci_command *cmd;
|
|
struct xhci_segment *new_seg;
|
|
+ struct xhci_segment *halted_seg = NULL;
|
|
union xhci_trb *new_deq;
|
|
int new_cycle;
|
|
+ union xhci_trb *halted_trb;
|
|
+ int index = 0;
|
|
dma_addr_t addr;
|
|
u64 hw_dequeue;
|
|
bool cycle_found = false;
|
|
@@ -672,7 +675,27 @@ static int xhci_move_dequeue_past_td(str
|
|
hw_dequeue = xhci_get_hw_deq(xhci, dev, ep_index, stream_id);
|
|
new_seg = ep_ring->deq_seg;
|
|
new_deq = ep_ring->dequeue;
|
|
- new_cycle = hw_dequeue & 0x1;
|
|
+
|
|
+ /*
|
|
+ * Quirk: xHC write-back of the DCS field in the hardware dequeue
|
|
+ * pointer is wrong - use the cycle state of the TRB pointed to by
|
|
+ * the dequeue pointer.
|
|
+ */
|
|
+ if (xhci->quirks & XHCI_EP_CTX_BROKEN_DCS &&
|
|
+ !(ep->ep_state & EP_HAS_STREAMS))
|
|
+ halted_seg = trb_in_td(xhci, td->start_seg,
|
|
+ td->first_trb, td->last_trb,
|
|
+ hw_dequeue & ~0xf, false);
|
|
+ if (halted_seg) {
|
|
+ index = ((dma_addr_t)(hw_dequeue & ~0xf) - halted_seg->dma) /
|
|
+ sizeof(*halted_trb);
|
|
+ halted_trb = &halted_seg->trbs[index];
|
|
+ new_cycle = halted_trb->generic.field[3] & 0x1;
|
|
+ xhci_dbg(xhci, "Endpoint DCS = %d TRB index = %d cycle = %d\n",
|
|
+ (u8)(hw_dequeue & 0x1), index, new_cycle);
|
|
+ } else {
|
|
+ new_cycle = hw_dequeue & 0x1;
|
|
+ }
|
|
|
|
/*
|
|
* We want to find the pointer, segment and cycle state of the new trb
|