PCI: dra7xx: Invoke phy_set_mode API to set PHY mode to PHY_MODE_PCIE
PATCH 1/1 PCI: dra7xx: Invoke phy_set_mode API to set PHY mode to PHY_MODE_PCIE
Certain PHYs used with PCIe controller can also be used with other controllers such as USB or SATA. In order to configure the PHY to work with PCIe controller, invoke phy_set_mode API with mode set to PHY_MODE_PCIE.
Signed-off-by Kishon Vijay Abraham I <[email protected]>
--- drivers/pci/controller/dwc/pci-dra7xx.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/pci/controller/dwc/pci-dra7xx.c +4 -0
@@ -517,6 +517,10 @@ static int dra7xx_pcie_enable_phy(struct dra7xx_pcie *dra7xx)int i;for (i =0 ; i < phy_count; i++) { + ret =phy_set_mode (dra7xx->phy[i],PHY_MODE_PCIE ); +if (ret <0 ) + goto err_phy; + ret =phy_init (dra7xx->phy[i]);if (ret <0 ) goto err_phy;
Signature · 1 line
2.17.1
Lorenzo Pieralisi
AppliedQuoted 9 lines · Kishon Vijay Abraham I
Certain PHYs used with PCIe controller can also be used with other controllers such as USB or SATA. In order to configure the PHY to work with PCIe controller, invoke
phy_set_modeAPI with mode set toPHY_MODE_PCIE.Signed-off-by Kishon Vijay Abraham I <[email protected]>--- drivers/pci/controller/dwc/pci-dra7xx.c | 4 ++++ 1 file changed, 4 insertions(+)
Applied to pci/dwc for v5.1, thanks.
Lorenzo
Quoted 18 lines
drivers/pci/controller/dwc/pci-dra7xx.c +4
-0@@ -517,6 +517,10 @@ static int dra7xx_pcie_enable_phy(struct dra7xx_pcie *dra7xx)int i;for (i =0 ; i < phy_count; i++) { + ret =phy_set_mode (dra7xx->phy[i],PHY_MODE_PCIE ); +if (ret <0 ) + goto err_phy; + ret =phy_init (dra7xx->phy[i]);if (ret <0 ) goto err_phy;Signature · 1 line
2.17.1