1. 19 11月, 2020 1 次提交
    • R
      PCI: dwc: Move MSI interrupt setup into DWC common code · 5bcb1757
      Rob Herring 提交于
      Platforms using the built-in DWC MSI controller all have a dedicated
      interrupt with "msi" name or at index 0, so let's move setting up the
      interrupt to the common DWC code.
      
      spear13xx and dra7xx are the 2 oddballs with muxed interrupts, so
      we need to prevent configuring the MSI interrupt by setting msi_irq
      to negative.
      
      Link: https://lore.kernel.org/r/20201105211159.1814485-9-robh@kernel.orgTested-by: NMarek Szyprowski <m.szyprowski@samsung.com>
      Signed-off-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Acked-by: NJingoo Han <jingoohan1@gmail.com>
      Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Cc: Kukjin Kim <kgene@kernel.org>
      Cc: Krzysztof Kozlowski <krzk@kernel.org>
      Cc: Richard Zhu <hongxing.zhu@nxp.com>
      Cc: Lucas Stach <l.stach@pengutronix.de>
      Cc: Shawn Guo <shawnguo@kernel.org>
      Cc: Sascha Hauer <s.hauer@pengutronix.de>
      Cc: Pengutronix Kernel Team <kernel@pengutronix.de>
      Cc: Fabio Estevam <festevam@gmail.com>
      Cc: NXP Linux Team <linux-imx@nxp.com>
      Cc: Yue Wang <yue.wang@Amlogic.com>
      Cc: Kevin Hilman <khilman@baylibre.com>
      Cc: Neil Armstrong <narmstrong@baylibre.com>
      Cc: Jerome Brunet <jbrunet@baylibre.com>
      Cc: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
      Cc: Jesper Nilsson <jesper.nilsson@axis.com>
      Cc: Gustavo Pimentel <gustavo.pimentel@synopsys.com>
      Cc: Xiaowei Song <songxiaowei@hisilicon.com>
      Cc: Binghui Wang <wangbinghui@hisilicon.com>
      Cc: Stanimir Varbanov <svarbanov@mm-sol.com>
      Cc: Andy Gross <agross@kernel.org>
      Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
      Cc: Pratyush Anand <pratyush.anand@gmail.com>
      Cc: Thierry Reding <thierry.reding@gmail.com>
      Cc: Jonathan Hunter <jonathanh@nvidia.com>
      Cc: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
      Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
      Cc: linux-samsung-soc@vger.kernel.org
      Cc: linux-amlogic@lists.infradead.org
      Cc: linux-arm-kernel@axis.com
      Cc: linux-arm-msm@vger.kernel.org
      Cc: linux-tegra@vger.kernel.org
      5bcb1757
  2. 10 9月, 2020 1 次提交
    • R
      PCI: dwc: Centralize link gen setting · 39bc5006
      Rob Herring 提交于
      keystone would force gen2 if no DT property. Now it relies on the
      PCI_EXP_LNKCAP value.
      
      Link: https://lore.kernel.org/r/20200821035420.380495-35-robh@kernel.orgSigned-off-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Kishon Vijay Abraham I <kishon@ti.com>
      Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Cc: Richard Zhu <hongxing.zhu@nxp.com>
      Cc: Lucas Stach <l.stach@pengutronix.de>
      Cc: Shawn Guo <shawnguo@kernel.org>
      Cc: Sascha Hauer <s.hauer@pengutronix.de>
      Cc: Pengutronix Kernel Team <kernel@pengutronix.de>
      Cc: Fabio Estevam <festevam@gmail.com>
      Cc: NXP Linux Team <linux-imx@nxp.com>
      Cc: Murali Karicheri <m-karicheri2@ti.com>
      Cc: Jingoo Han <jingoohan1@gmail.com>
      Cc: Gustavo Pimentel <gustavo.pimentel@synopsys.com>
      Cc: Stanimir Varbanov <svarbanov@mm-sol.com>
      Cc: Andy Gross <agross@kernel.org>
      Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
      Cc: Pratyush Anand <pratyush.anand@gmail.com>
      Cc: Thierry Reding <thierry.reding@gmail.com>
      Cc: Jonathan Hunter <jonathanh@nvidia.com>
      Cc: linux-omap@vger.kernel.org
      Cc: linux-arm-kernel@lists.infradead.org
      Cc: linux-arm-msm@vger.kernel.org
      Cc: linux-tegra@vger.kernel.org
      39bc5006
  3. 08 9月, 2020 3 次提交
    • R
      PCI: dwc/imx6: Use common PCI register definitions · 201a8df8
      Rob Herring 提交于
      The i.MX6 driver has its own defines for common PCI config space
      registers. It also hard codes the capability register offsets which are
      discoverable. Convert it to use the standard register definitions.
      
      Link: https://lore.kernel.org/r/20200821035420.380495-29-robh@kernel.orgSigned-off-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Richard Zhu <hongxing.zhu@nxp.com>
      Cc: Lucas Stach <l.stach@pengutronix.de>
      Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Cc: Shawn Guo <shawnguo@kernel.org>
      Cc: Sascha Hauer <s.hauer@pengutronix.de>
      Cc: Pengutronix Kernel Team <kernel@pengutronix.de>
      Cc: Fabio Estevam <festevam@gmail.com>
      Cc: NXP Linux Team <linux-imx@nxp.com>
      201a8df8
    • R
      PCI: dwc/imx6: Remove duplicate define PCIE_LINK_WIDTH_SPEED_CONTROL · 574523dc
      Rob Herring 提交于
      PCIE_LINK_WIDTH_SPEED_CONTROL is already defined in pcie-designware.h,
      so remove it from the i.MX6 driver.
      
      Link: https://lore.kernel.org/r/20200821035420.380495-23-robh@kernel.orgSigned-off-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Richard Zhu <hongxing.zhu@nxp.com>
      Cc: Lucas Stach <l.stach@pengutronix.de>
      Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Cc: Shawn Guo <shawnguo@kernel.org>
      Cc: Sascha Hauer <s.hauer@pengutronix.de>
      Cc: Pengutronix Kernel Team <kernel@pengutronix.de>
      Cc: Fabio Estevam <festevam@gmail.com>
      Cc: NXP Linux Team <linux-imx@nxp.com>
      574523dc
    • R
      PCI: dwc: Check CONFIG_PCI_MSI inside dw_pcie_msi_init() · cf627713
      Rob Herring 提交于
      Move the IS_ENABLED(CONFIG_PCI_MSI) check into dw_pcie_msi_init()
      instead of duplicating it in all the drivers.
      
      Link: https://lore.kernel.org/r/20200821035420.380495-22-robh@kernel.orgSigned-off-by: NRob Herring <robh@kernel.org>
      Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Richard Zhu <hongxing.zhu@nxp.com>
      Cc: Lucas Stach <l.stach@pengutronix.de>
      Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Cc: Shawn Guo <shawnguo@kernel.org>
      Cc: Sascha Hauer <s.hauer@pengutronix.de>
      Cc: Pengutronix Kernel Team <kernel@pengutronix.de>
      Cc: Fabio Estevam <festevam@gmail.com>
      Cc: NXP Linux Team <linux-imx@nxp.com>
      Cc: Yue Wang <yue.wang@Amlogic.com>
      Cc: Kevin Hilman <khilman@baylibre.com>
      Cc: Jesper Nilsson <jesper.nilsson@axis.com>
      Cc: Jingoo Han <jingoohan1@gmail.com>
      Cc: Gustavo Pimentel <gustavo.pimentel@synopsys.com>
      Cc: Xiaowei Song <songxiaowei@hisilicon.com>
      Cc: Binghui Wang <wangbinghui@hisilicon.com>
      Cc: Stanimir Varbanov <svarbanov@mm-sol.com>
      Cc: Andy Gross <agross@kernel.org>
      Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
      Cc: Kunihiko Hayashi <hayashi.kunihiko@socionext.com>
      Cc: Masahiro Yamada <yamada.masahiro@socionext.com>
      Cc: linux-amlogic@lists.infradead.org
      Cc: linux-arm-kernel@axis.com
      Cc: linux-arm-msm@vger.kernel.org
      cf627713
  4. 07 9月, 2020 2 次提交
  5. 24 8月, 2020 1 次提交
  6. 03 8月, 2020 1 次提交
  7. 23 7月, 2020 1 次提交
  8. 01 7月, 2020 1 次提交
  9. 12 5月, 2020 1 次提交
  10. 04 9月, 2019 1 次提交
    • T
      PCI: imx6: Propagate errors for optional regulators · 2170a09f
      Thierry Reding 提交于
      regulator_get_optional() can fail for a number of reasons besides probe
      deferral. It can for example return -ENOMEM if it runs out of memory as
      it tries to allocate data structures. Propagating only -EPROBE_DEFER is
      problematic because it results in these legitimately fatal errors being
      treated as "regulator not specified in DT".
      
      What we really want is to ignore the optional regulators only if they
      have not been specified in DT. regulator_get_optional() returns -ENODEV
      in this case, so that's the special case that we need to handle. So we
      propagate all errors, except -ENODEV, so that real failures will still
      cause the driver to fail probe.
      Signed-off-by: NThierry Reding <treding@nvidia.com>
      Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Reviewed-by: NAndrew Murray <andrew.murray@arm.com>
      Cc: Richard Zhu <hongxing.zhu@nxp.com>
      Cc: Lucas Stach <l.stach@pengutronix.de>
      Cc: Shawn Guo <shawnguo@kernel.org>
      Cc: Sascha Hauer <s.hauer@pengutronix.de>
      Cc: Fabio Estevam <festevam@gmail.com>
      Cc: kernel@pengutronix.de
      Cc: linux-imx@nxp.com
      2170a09f
  11. 15 8月, 2019 1 次提交
  12. 07 5月, 2019 1 次提交
  13. 01 5月, 2019 11 次提交
  14. 01 3月, 2019 2 次提交
  15. 13 2月, 2019 1 次提交
    • T
      PCI: imx: Add workaround for e10728, IMX7d PCIe PLL failure · 1df82ec4
      Trent Piepho 提交于
      This implements the workound described in the NXP IMX7d erratum e10728.
      
      Initial VCO oscillation may fail under corner conditions such as cold
      temperature. It causes PCIe PLL to fail to lock in the initialization
      phase, which results in the PCIe link failing to come up.
      
      The workaround is to disable Duty-Cycle Corrector (DCC) calibration
      after G_RST.
      
      To do this it is necessary to gain access to the undocumented and
      currently unused PCIe PHY register bank. A new device tree node of type
      "fsl,imx7d-pcie-phy" is created for the PHY block and the existing PCIe
      device uses a phandle named "fsl,imx7d-pcie-phy" to point to it.
      Signed-off-by: NTrent Piepho <tpiepho@impinj.com>
      [lorenzo.pieralisi@arm.com: updated log string, commit log]
      Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Reviewed-by: NLucas Stach <l.stach@pengutronix.de>
      1df82ec4
  16. 04 2月, 2019 4 次提交
  17. 01 2月, 2019 2 次提交
  18. 02 1月, 2019 1 次提交
  19. 18 12月, 2018 2 次提交
  20. 20 11月, 2018 1 次提交
    • T
      PCI: imx6: Fix link training status detection in link up check · 68bc10bf
      Trent Piepho 提交于
      This bug was introduced in the interaction for two commits on either
      branch of the merge commit 562df5c8 ("Merge branch
      'pci/host-designware' into next").
      
      Commit 4d107d3b ("PCI: imx6: Move link up check into
      imx6_pcie_wait_for_link()"), changed imx6_pcie_wait_for_link() to poll
      the link status register directly, checking for link up and not
      training, and made imx6_pcie_link_up() only check the link up bit (once,
      not a polling loop).
      
      While commit 886bc5ce ("PCI: designware: Add generic
      dw_pcie_wait_for_link()"), replaced the loop in
      imx6_pcie_wait_for_link() with a call to a new dwc core function, which
      polled imx6_pcie_link_up(), which still checked both link up and not
      training in a loop.
      
      When these two commits were merged, the version of
      imx6_pcie_wait_for_link() from 886bc5ce was kept, which eliminated
      the link training check placed there by 4d107d3b. However, the
      version of imx6_pcie_link_up() from 4d107d3b was kept, which
      eliminated the link training check that had been there and was moved to
      imx6_pcie_wait_for_link().
      
      The result was the link training check got lost for the imx6 driver.
      
      Eliminate imx6_pcie_link_up() so that the default handler,
      dw_pcie_link_up(), is used instead. The default handler has the correct
      code, which checks for link up and also that it still is not training,
      fixing the regression.
      
      Fixes: 562df5c8 ("Merge branch 'pci/host-designware' into next")
      Signed-off-by: NTrent Piepho <tpiepho@impinj.com>
      [lorenzo.pieralisi@arm.com: rewrote the commit log]
      Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Reviewed-by: NLucas Stach <l.stach@pengutronix.de>
      Cc: Bjorn Helgaas <bhelgaas@google.com>
      Cc: Joao Pinto <Joao.Pinto@synopsys.com>
      Cc: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Cc: Richard Zhu <hongxing.zhu@nxp.com>
      68bc10bf
  21. 05 10月, 2018 1 次提交
    • L
      PCI: imx: Add PME_Turn_Off support · f4e833ba
      Leonard Crestez 提交于
      When the root complex suspends it must send a PME_Turn_Off TLP.
      Implement this by asserting the "turnoff" reset.
      
      On imx7d this functionality is part of the System Reset Controller (SRC)
      and is exposed through the linux reset-controller subsystem.
      
      On imx6 equivalent bits are in the IOMUXC pinmux controller General
      Purpose Register (GPR) area which the imx6-pcie driver accesses
      directly.
      
      This is only for imx7d right now but it's deliberately implemented as an
      optional reset, ignoring the chip variant:
      * Older dtbs won't have this reset so it will be ignored.
      * Future chips might also expose this as a reset controller.
      
      For example imx8m (not yet supported) has the exact same
      PCIE_CTRL_APPS_TURNOFF bit in the same location.
      Signed-off-by: NLeonard Crestez <leonard.crestez@nxp.com>
      [lorenzo.pieralisi@arm.com: updated commit log]
      Signed-off-by: NLorenzo Pieralisi <lorenzo.pieralisi@arm.com>
      Reviewed-by: NLucas Stach <l.stach@pengutronix.de>
      f4e833ba