aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/pci/controller/dwc/pci-keystone.c
diff options
context:
space:
mode:
authorSerge Semin <[email protected]>2022-06-24 14:39:37 +0000
committerBjorn Helgaas <[email protected]>2022-08-01 20:02:36 +0000
commit0b0a780d52ad2bd51e4e154c190abcfed43e33bb (patch)
tree04b89e42417eb8a74cc6f0ca907526863959b006 /drivers/pci/controller/dwc/pci-keystone.c
parentPCI: dwc: Read DWC IP core version from register (diff)
downloadkernel-0b0a780d52ad2bd51e4e154c190abcfed43e33bb.tar.gz
kernel-0b0a780d52ad2bd51e4e154c190abcfed43e33bb.zip
PCI: dwc: Add macros to compare Synopsys IP core versions
Add macros to compare DWC IP core versions: dw_pcie_ver_is() dw_pcie_ver_is_ge() dw_pcie_ver_type_is() dw_pcie_ver_type_is_ge() These are along the lines of DWC3_VER_IS() and dw_spi_ver_is(). [bhelgaas: commit log] Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Serge Semin <[email protected]> Signed-off-by: Bjorn Helgaas <[email protected]> Reviewed-by: Rob Herring <[email protected]>
Diffstat (limited to 'drivers/pci/controller/dwc/pci-keystone.c')
-rw-r--r--drivers/pci/controller/dwc/pci-keystone.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/pci/controller/dwc/pci-keystone.c b/drivers/pci/controller/dwc/pci-keystone.c
index c4ab3d775a18..2a9bbde224af 100644
--- a/drivers/pci/controller/dwc/pci-keystone.c
+++ b/drivers/pci/controller/dwc/pci-keystone.c
@@ -1233,7 +1233,7 @@ static int __init ks_pcie_probe(struct platform_device *pdev)
goto err_get_sync;
}
- if (pci->version >= DW_PCIE_VER_480A)
+ if (dw_pcie_ver_is_ge(pci, 480A))
ret = ks_pcie_am654_set_mode(dev, mode);
else
ret = ks_pcie_set_mode(dev);