Commit 2577ba8c authored by Johan Hovold's avatar Johan Hovold Committed by Vinod Koul

phy: qcom-qmp-pcie: clean up status polling

Clean up the status polling by dropping the ready bit mask which is no
longer needed since the QMP driver split.
Signed-off-by: default avatarJohan Hovold <johan+linaro@kernel.org>
Reviewed-by: default avatarDmitry Baryshkov <dmitry.baryshkov@linaro.org>
Link: https://lore.kernel.org/r/20221012085002.24099-4-johan+linaro@kernel.orgSigned-off-by: default avatarVinod Koul <vkoul@kernel.org>
parent 30518b19
...@@ -1966,7 +1966,7 @@ static int qmp_pcie_power_on(struct phy *phy) ...@@ -1966,7 +1966,7 @@ static int qmp_pcie_power_on(struct phy *phy)
const struct qmp_phy_cfg_tables *mode_tables; const struct qmp_phy_cfg_tables *mode_tables;
void __iomem *pcs = qphy->pcs; void __iomem *pcs = qphy->pcs;
void __iomem *status; void __iomem *status;
unsigned int mask, val, ready; unsigned int mask, val;
int ret; int ret;
qphy_setbits(pcs, cfg->regs[QPHY_PCS_POWER_DOWN_CONTROL], qphy_setbits(pcs, cfg->regs[QPHY_PCS_POWER_DOWN_CONTROL],
...@@ -2004,9 +2004,7 @@ static int qmp_pcie_power_on(struct phy *phy) ...@@ -2004,9 +2004,7 @@ static int qmp_pcie_power_on(struct phy *phy)
status = pcs + cfg->regs[QPHY_PCS_STATUS]; status = pcs + cfg->regs[QPHY_PCS_STATUS];
mask = cfg->phy_status; mask = cfg->phy_status;
ready = 0; ret = readl_poll_timeout(status, val, !(val & mask), 10,
ret = readl_poll_timeout(status, val, (val & mask) == ready, 10,
PHY_INIT_COMPLETE_TIMEOUT); PHY_INIT_COMPLETE_TIMEOUT);
if (ret) { if (ret) {
dev_err(qmp->dev, "phy initialization timed-out\n"); dev_err(qmp->dev, "phy initialization timed-out\n");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment