]> git.baikalelectronics.ru Git - kernel.git/commit
PCI: tegra: Enable Relaxed Ordering only for Tegra20 & Tegra30
authorVidya Sagar <vidyas@nvidia.com>
Thu, 4 Jul 2019 15:04:28 +0000 (20:34 +0530)
committerLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Fri, 5 Jul 2019 12:59:59 +0000 (13:59 +0100)
commitc42ad3ccd08262e40c6d21738245961250419bf2
treee8fe9e7caa561bd201a8459c0a48a928128e96e2
parentc8bf7f8094d0e9fc17e8050061e1d8b68c910431
PCI: tegra: Enable Relaxed Ordering only for Tegra20 & Tegra30

The PCI Tegra controller conversion to a device tree configurable
driver in commit 0b5b94de276c ("PCI: tegra: Move PCIe driver
to drivers/pci/host") implied that code for the driver can be
compiled in for a kernel supporting multiple platforms.

Unfortunately, a blind move of the code did not check that some of the
quirks that were applied in arch/arm (eg enabling Relaxed Ordering on
all PCI devices - since the quirk hook erroneously matches PCI_ANY_ID
for both Vendor-ID and Device-ID) are now applied in all kernels that
compile the PCI Tegra controlled driver, DT and ACPI alike.

This is completely wrong, in that enablement of Relaxed Ordering is only
required by default in Tegra20 platforms as described in the Tegra20
Technical Reference Manual (available at
https://developer.nvidia.com/embedded/downloads#?search=tegra%202 in
Section 34.1, where it is mentioned that Relaxed Ordering bit needs to
be enabled in its root ports to avoid deadlock in hardware) and in the
Tegra30 platforms for the same reasons (unfortunately not documented
in the TRM).

There is no other strict requirement on PCI devices Relaxed Ordering
enablement on any other Tegra platforms or PCI host bridge driver.

Fix this quite upsetting situation by limiting the vendor and device IDs
to which the Relaxed Ordering quirk applies to the root ports in
question, reported above.

Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
[lorenzo.pieralisi@arm.com: completely rewrote the commit log/fixes tag]
Signed-off-by: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
Acked-by: Thierry Reding <treding@nvidia.com>
drivers/pci/controller/pci-tegra.c