Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

phy: qcom-qmp-pcie: clean up PHY lane init

Clean up the PHY lane initialisation somewhat by adding further
temporary variables and programming both tx and rx for the second lane
after the first lane.

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Johan Hovold <johan+linaro@kernel.org>
Link: https://lore.kernel.org/r/20221105145939.20318-8-johan+linaro@kernel.org
Signed-off-by: Vinod Koul <vkoul@kernel.org>

authored by

Johan Hovold and committed by
Vinod Koul
f8b64114 63bf101a

+7 -6
+7 -6
drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
··· 1835 1835 const struct qmp_phy_cfg *cfg = qmp->cfg; 1836 1836 void __iomem *tx = qmp->tx; 1837 1837 void __iomem *rx = qmp->rx; 1838 + void __iomem *tx2 = qmp->tx2; 1839 + void __iomem *rx2 = qmp->rx2; 1838 1840 1839 1841 if (!tables) 1840 1842 return; 1841 1843 1842 1844 qmp_pcie_configure_lane(tx, tables->tx, tables->tx_num, 1); 1843 - 1844 - if (cfg->lanes >= 2) 1845 - qmp_pcie_configure_lane(qmp->tx2, tables->tx, tables->tx_num, 2); 1846 - 1847 1845 qmp_pcie_configure_lane(rx, tables->rx, tables->rx_num, 1); 1848 - if (cfg->lanes >= 2) 1849 - qmp_pcie_configure_lane(qmp->rx2, tables->rx, tables->rx_num, 2); 1846 + 1847 + if (cfg->lanes >= 2) { 1848 + qmp_pcie_configure_lane(tx2, tables->tx, tables->tx_num, 2); 1849 + qmp_pcie_configure_lane(rx2, tables->rx, tables->rx_num, 2); 1850 + } 1850 1851 } 1851 1852 1852 1853 static void qmp_pcie_pcs_init(struct qmp_pcie *qmp, const struct qmp_phy_cfg_tables *tables)