diff for duplicates of <5AE317AB.4020404@kontron.com> diff --git a/a/1.txt b/N1/1.txt index 2751ddc..8c53f8f 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -1,4 +1,4 @@ -Le 27/04/2018 10:43, Ard Biesheuvel a écrit : +Le 27/04/2018 10:43, Ard Biesheuvel a ?crit : > (add Bjorn and linux-pci) > > On 13 April 2018 at 19:32, Gilles Buloz <Gilles.Buloz@kontron.com> wrote: @@ -45,3 +45,10 @@ and PCI_X_STATUS_533MHZ (as done in drivers/pci/probe.c at pci_cfg_space_size()) I'm currently using the attached patch (for kernel 4.1.35-rt41 from NXP Yocto BSP). It uses bus_flags to remember if a bus is behind a bridge without extended address capability to avoid PCi config accesses at offset >= 0x100. Thanks to this patch I now have a functional system with functional PCI/PCIe devices. +-------------- next part -------------- +A non-text attachment was scrubbed... +Name: cfgspace.patch +Type: text/x-patch +Size: 1943 bytes +Desc: cfgspace.patch +URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20180427/ac2bb836/attachment.bin> diff --git a/a/2.hdr b/a/2.hdr deleted file mode 100644 index 3e6b778..0000000 --- a/a/2.hdr +++ /dev/null @@ -1,7 +0,0 @@ -Content-Type: text/x-patch; name=cfgspace.patch -Content-Description: cfgspace.patch -Content-Disposition: attachment; filename="cfgspace.patch"; size=1943; - creation-date="Fri, 27 Apr 2018 12:29:32 GMT"; - modification-date="Fri, 27 Apr 2018 12:29:32 GMT" -Content-ID: <E91554AF1033DD4B91DD215219E3551F@Kontron.com> -Content-Transfer-Encoding: base64 diff --git a/a/2.txt b/a/2.txt deleted file mode 100644 index 1574c1e..0000000 --- a/a/2.txt +++ /dev/null @@ -1,53 +0,0 @@ ---- include/linux/pci.h.orig 2018-03-26 16:51:18.050000000 +0000 -+++ include/linux/pci.h 2018-03-26 16:51:27.660000000 +0000 -@@ -193,6 +193,7 @@ - enum pci_bus_flags { - PCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1, - PCI_BUS_FLAGS_NO_MMRBC = (__force pci_bus_flags_t) 2, -+ PCI_BUS_FLAGS_COMPAT_CFG_SPACE = (__force pci_bus_flags_t) 4, - }; - - /* These values come from the PCI Express Spec */ ---- drivers/pci/probe.c.orig 2018-01-22 09:29:52.000000000 +0000 -+++ drivers/pci/probe.c 2018-03-26 16:54:30.830000000 +0000 -@@ -827,6 +827,28 @@ - child->primary = primary; - pci_bus_insert_busn_res(child, secondary, subordinate); - child->bridge_ctl = bctl; -+ -+ { -+ int pos; -+ u32 status; -+ bool pci_compat_cfg_space = false; -+ -+ if (!pci_is_pcie(dev) || (pci_pcie_type(dev) == PCI_EXP_TYPE_PCIE_BRIDGE) || (pci_pcie_type(dev) == PCI_EXP_TYPE_PCI_BRIDGE)) { -+ /* for PCI/PCI bridges, or PCIe/PCI bridge in forward or reverse mode, we have to check for PCI-X capabilities */ -+ pos = pci_find_capability(dev, PCI_CAP_ID_PCIX); -+ if (pos) { -+ pci_read_config_dword(dev, pos + PCI_X_STATUS, &status); -+ if (!(status & (PCI_X_STATUS_266MHZ | PCI_X_STATUS_533MHZ))) -+ pci_compat_cfg_space = true; -+ } else { -+ pci_compat_cfg_space = true; -+ } -+ if (pci_compat_cfg_space) { -+ dev_info(&dev->dev, "[%04x:%04x] Child bus limited to PCI-Compatible config space\n", dev->vendor, dev->device); -+ child->bus_flags |= PCI_BUS_FLAGS_COMPAT_CFG_SPACE; -+ } -+ } -+ } - } - - cmax = pci_scan_child_bus(child); -@@ -1098,6 +1120,11 @@ - goto fail; - } - -+ if (dev->bus->bus_flags & PCI_BUS_FLAGS_COMPAT_CFG_SPACE) { -+ dev_info(&dev->dev, "[%04x:%04x] PCI-Compatible config space only due to parent bus(es)\n", dev->vendor, dev->device); -+ return PCI_CFG_SPACE_SIZE; -+ } -+ - return pci_cfg_space_size_ext(dev); - - fail: diff --git a/a/3.hdr b/a/3.hdr deleted file mode 100644 index 4b86001..0000000 --- a/a/3.hdr +++ /dev/null @@ -1,4 +0,0 @@ -Content-Type: text/plain; charset="us-ascii" -MIME-Version: 1.0 -Content-Transfer-Encoding: 7bit -Content-Disposition: inline diff --git a/a/3.txt b/a/3.txt deleted file mode 100644 index 8133cf0..0000000 --- a/a/3.txt +++ /dev/null @@ -1,4 +0,0 @@ -_______________________________________________ -linux-arm-kernel mailing list -linux-arm-kernel@lists.infradead.org -http://lists.infradead.org/mailman/listinfo/linux-arm-kernel diff --git a/a/content_digest b/N1/content_digest index 0388800..d086ed1 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -1,16 +1,12 @@ "ref\05AD0E995.3090802@kontron.com\0" "ref\0CAKv+Gu_v4V8DUa6f4WxvjZHoJbbqT0mKpOwYVmaLaE20CB3U_g@mail.gmail.com\0" - "From\0Gilles Buloz <Gilles.Buloz@kontron.com>\0" - "Subject\0Re: LS1043A : \"synchronous abort\" at boot due to PCI config read\0" + "From\0Gilles.Buloz@kontron.com (Gilles Buloz)\0" + "Subject\0LS1043A : \"synchronous abort\" at boot due to PCI config read\0" "Date\0Fri, 27 Apr 2018 12:29:32 +0000\0" - "To\0Ard Biesheuvel <ard.biesheuvel@linaro.org>\0" - "Cc\0Bjorn Helgaas <bhelgaas@google.com>" - linux-pci <linux-pci@vger.kernel.org> - linux-arm-kernel@lists.infradead.org <linux-arm-kernel@lists.infradead.org> - " minghuan.Lian@freescale.com <minghuan.Lian@freescale.com>\0" - "\01:1\0" + "To\0linux-arm-kernel@lists.infradead.org\0" + "\00:1\0" "b\0" - "Le 27/04/2018 10:43, Ard Biesheuvel a \303\251crit :\n" + "Le 27/04/2018 10:43, Ard Biesheuvel a ?crit :\n" "> (add Bjorn and linux-pci)\n" ">\n" "> On 13 April 2018 at 19:32, Gilles Buloz <Gilles.Buloz@kontron.com> wrote:\n" @@ -56,69 +52,13 @@ "\n" "I'm currently using the attached patch (for kernel 4.1.35-rt41 from NXP Yocto BSP). It uses bus_flags to remember if a bus is behind \n" "a bridge without extended address capability to avoid PCi config accesses at offset >= 0x100. Thanks to this patch I now have a \n" - functional system with functional PCI/PCIe devices. - "\01:2\0" - "fn\0cfgspace.patch\0" - "d\0cfgspace.patch\0" - "b\0" - "--- include/linux/pci.h.orig\t2018-03-26 16:51:18.050000000 +0000\n" - "+++ include/linux/pci.h\t2018-03-26 16:51:27.660000000 +0000\n" - "@@ -193,6 +193,7 @@\n" - " enum pci_bus_flags {\n" - " \tPCI_BUS_FLAGS_NO_MSI = (__force pci_bus_flags_t) 1,\n" - " \tPCI_BUS_FLAGS_NO_MMRBC = (__force pci_bus_flags_t) 2,\n" - "+\tPCI_BUS_FLAGS_COMPAT_CFG_SPACE = (__force pci_bus_flags_t) 4,\n" - " };\n" - " \n" - " /* These values come from the PCI Express Spec */\n" - "--- drivers/pci/probe.c.orig\t2018-01-22 09:29:52.000000000 +0000\n" - "+++ drivers/pci/probe.c\t2018-03-26 16:54:30.830000000 +0000\n" - "@@ -827,6 +827,28 @@\n" - " \t\t\tchild->primary = primary;\n" - " \t\t\tpci_bus_insert_busn_res(child, secondary, subordinate);\n" - " \t\t\tchild->bridge_ctl = bctl;\n" - "+\n" - "+\t\t\t{\n" - "+\t\t\t\tint pos;\n" - "+\t\t\t\tu32 status;\n" - "+\t\t\t\tbool pci_compat_cfg_space = false;\n" - "+\n" - "+\t\t\t\tif (!pci_is_pcie(dev) || (pci_pcie_type(dev) == PCI_EXP_TYPE_PCIE_BRIDGE) || (pci_pcie_type(dev) == PCI_EXP_TYPE_PCI_BRIDGE)) {\n" - "+\t\t\t\t\t/* for PCI/PCI bridges, or PCIe/PCI bridge in forward or reverse mode, we have to check for PCI-X capabilities */\n" - "+\t\t\t\t\tpos = pci_find_capability(dev, PCI_CAP_ID_PCIX);\n" - "+\t\t\t\t\tif (pos) {\n" - "+\t\t\t\t\t\tpci_read_config_dword(dev, pos + PCI_X_STATUS, &status);\n" - "+\t\t\t\t\t\tif (!(status & (PCI_X_STATUS_266MHZ | PCI_X_STATUS_533MHZ)))\n" - "+\t\t\t\t\t\t\tpci_compat_cfg_space = true;\n" - "+\t\t\t\t\t} else {\n" - "+\t\t\t\t\t\tpci_compat_cfg_space = true;\n" - "+\t\t\t\t\t}\n" - "+\t\t\t\t\tif (pci_compat_cfg_space) {\n" - "+\t\t\t\t\t\tdev_info(&dev->dev, \"[%04x:%04x] Child bus limited to PCI-Compatible config space\\n\", dev->vendor, dev->device);\n" - "+\t\t\t\t\t\tchild->bus_flags |= PCI_BUS_FLAGS_COMPAT_CFG_SPACE;\n" - "+\t\t\t\t\t}\n" - "+\t\t\t\t}\n" - "+\t\t\t}\n" - " \t\t}\n" - " \n" - " \t\tcmax = pci_scan_child_bus(child);\n" - "@@ -1098,6 +1120,11 @@\n" - " \t\t\tgoto fail;\n" - " \t}\n" - " \n" - "+\tif (dev->bus->bus_flags & PCI_BUS_FLAGS_COMPAT_CFG_SPACE) {\n" - "+\t\tdev_info(&dev->dev, \"[%04x:%04x] PCI-Compatible config space only due to parent bus(es)\\n\", dev->vendor, dev->device);\n" - "+\t\treturn PCI_CFG_SPACE_SIZE;\n" - "+\t}\n" - "+\n" - " \treturn pci_cfg_space_size_ext(dev);\n" - " \n" - fail: - "\01:3\0" - "b\0" - "_______________________________________________\n" - "linux-arm-kernel mailing list\n" - "linux-arm-kernel@lists.infradead.org\n" - http://lists.infradead.org/mailman/listinfo/linux-arm-kernel + "functional system with functional PCI/PCIe devices.\n" + "-------------- next part --------------\n" + "A non-text attachment was scrubbed...\n" + "Name: cfgspace.patch\n" + "Type: text/x-patch\n" + "Size: 1943 bytes\n" + "Desc: cfgspace.patch\n" + URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20180427/ac2bb836/attachment.bin> -5f3a1bfb3cfdd7105c9d083723aeab35c7881e1123b791623fda5da3a262fee9 +34c03e1c3c277aeff831e7d99300e79a91b8672d13491baf849b3b47a118302f
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.