phy: qcom-qmp: Raise qcom_qmp_phy_enable() polling delay
authorMarc Gonzalez <marc.w.gonzalez@free.fr>
Thu, 13 Jun 2019 11:32:08 +0000 (13:32 +0200)
committerKishon Vijay Abraham I <kishon@ti.com>
Tue, 25 Jun 2019 13:47:38 +0000 (19:17 +0530)
readl_poll_timeout() calls usleep_range() to sleep between reads.
usleep_range() doesn't work efficiently for tiny values.

Raise the polling delay in qcom_qmp_phy_enable() to bring it in line
with the delay in qcom_qmp_phy_com_init().

Signed-off-by: Marc Gonzalez <marc.w.gonzalez@free.fr>
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
drivers/phy/qualcomm/phy-qcom-qmp.c

index bb522b915fa9cbdd7f1c5de615c5e3cfae0cdbd2..34ff6434da8f897293dbe2edc8ff6af5e8ea51f9 100644 (file)
@@ -1548,7 +1548,7 @@ static int qcom_qmp_phy_enable(struct phy *phy)
        status = pcs + cfg->regs[QPHY_PCS_READY_STATUS];
        mask = cfg->mask_pcs_ready;
 
-       ret = readl_poll_timeout(status, val, val & mask, 1,
+       ret = readl_poll_timeout(status, val, val & mask, 10,
                                 PHY_INIT_COMPLETE_TIMEOUT);
        if (ret) {
                dev_err(qmp->dev, "phy initialization timed-out\n");