diff options
author | Felix Fietkau <nbd@nbd.name> | 2022-03-27 21:26:31 +0200 |
---|---|---|
committer | Felix Fietkau <nbd@nbd.name> | 2022-03-27 21:36:40 +0200 |
commit | a3764ee29dd09394fa750c78160e300d86532561 (patch) | |
tree | 5698d325acdbd921f7fa4203149adf3b5fb87f39 /target/linux/ramips/patches-5.15/106-PCI-Let-pcibios_root_bridge_prepare-access-bridge-wi.patch | |
parent | ac11f36b337da29f422d16776cf36c98013dcc77 (diff) | |
download | upstream-a3764ee29dd09394fa750c78160e300d86532561.tar.gz upstream-a3764ee29dd09394fa750c78160e300d86532561.tar.bz2 upstream-a3764ee29dd09394fa750c78160e300d86532561.zip |
ramips: add linux 5.15 support for mt7621
Signed-off-by: Felix Fietkau <nbd@nbd.name>
Diffstat (limited to 'target/linux/ramips/patches-5.15/106-PCI-Let-pcibios_root_bridge_prepare-access-bridge-wi.patch')
-rw-r--r-- | target/linux/ramips/patches-5.15/106-PCI-Let-pcibios_root_bridge_prepare-access-bridge-wi.patch | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/target/linux/ramips/patches-5.15/106-PCI-Let-pcibios_root_bridge_prepare-access-bridge-wi.patch b/target/linux/ramips/patches-5.15/106-PCI-Let-pcibios_root_bridge_prepare-access-bridge-wi.patch new file mode 100644 index 0000000000..2fbbf9a7aa --- /dev/null +++ b/target/linux/ramips/patches-5.15/106-PCI-Let-pcibios_root_bridge_prepare-access-bridge-wi.patch @@ -0,0 +1,38 @@ +From: Sergio Paracuellos <sergio.paracuellos@gmail.com> +Date: Tue, 7 Dec 2021 11:49:20 +0100 +Subject: [PATCH] PCI: Let pcibios_root_bridge_prepare() access bridge->windows + +When pci_register_host_bridge() is called, bridge->windows are already +available. However these windows are being moved temporarily from there. + +To let pcibios_root_bridge_prepare() have access to these windows, move the +windows movement after calling this function. This is useful for the MIPS +ralink mt7621 platform so it can set up I/O coherence units and avoid +custom MIPS code in the mt7621 PCIe controller driver. + +Link: https://lore.kernel.org/r/20211207104924.21327-2-sergio.paracuellos@gmail.com +Signed-off-by: Sergio Paracuellos <sergio.paracuellos@gmail.com> +Signed-off-by: Bjorn Helgaas <bhelgaas@google.com> +Acked-by: Arnd Bergmann <arnd@arndb.de> +--- + +--- a/drivers/pci/probe.c ++++ b/drivers/pci/probe.c +@@ -898,8 +898,6 @@ static int pci_register_host_bridge(stru + + bridge->bus = bus; + +- /* Temporarily move resources off the list */ +- list_splice_init(&bridge->windows, &resources); + bus->sysdata = bridge->sysdata; + bus->ops = bridge->ops; + bus->number = bus->busn_res.start = bridge->busnr; +@@ -925,6 +923,8 @@ static int pci_register_host_bridge(stru + if (err) + goto free; + ++ /* Temporarily move resources off the list */ ++ list_splice_init(&bridge->windows, &resources); + err = device_add(&bridge->dev); + if (err) { + put_device(&bridge->dev); |