aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/phy
diff options
context:
space:
mode:
authorShawn Lin <shawn.lin@rock-chips.com>2016-06-20 13:56:40 -0400
committerUlf Hansson <ulf.hansson@linaro.org>2016-07-25 04:34:14 -0400
commit4d54a25ba5df8d4fd1c1604d1526c9279237ac27 (patch)
tree6fb4b4f9848dd112733b739585efc6ab352fd7b4 /drivers/phy
parent476bf3d62d5cc0ec003da37ba9da4f2b46c23660 (diff)
phy: rockchip-emmc: give DLL some extra time to be ready
According to the databook, 10.2us is the max time for dll to be ready to work. However in testing, some chips need 20us for dll to be ready. This patch adds some extra margin for dllrdy to be ready, fixing our -ETIMEDOUT issues. Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com> Signed-off-by: Brian Norris <briannorris@chromium.org> Signed-off-by: Douglas Anderson <dianders@chromium.org> Acked-by: Kishon Vijay Abraham I <kishon@ti.com> Tested-by: Heiko Stuebner <heiko@sntech.de> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
Diffstat (limited to 'drivers/phy')
-rw-r--r--drivers/phy/phy-rockchip-emmc.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/phy/phy-rockchip-emmc.c b/drivers/phy/phy-rockchip-emmc.c
index 6ebcf3e41c46..48cbe691a889 100644
--- a/drivers/phy/phy-rockchip-emmc.c
+++ b/drivers/phy/phy-rockchip-emmc.c
@@ -119,10 +119,11 @@ static int rockchip_emmc_phy_power(struct rockchip_emmc_phy *rk_phy,
119 PHYCTRL_ENDLL_MASK, 119 PHYCTRL_ENDLL_MASK,
120 PHYCTRL_ENDLL_SHIFT)); 120 PHYCTRL_ENDLL_SHIFT));
121 /* 121 /*
122 * After enable analog DLL circuits, we need extra 10.2us 122 * After enable analog DLL circuits, we need an extra 10.2us
123 * for dll to be ready for work. 123 * for dll to be ready for work. But according to testing, we
124 * find some chips need more than 25us.
124 */ 125 */
125 udelay(11); 126 udelay(30);
126 regmap_read(rk_phy->reg_base, 127 regmap_read(rk_phy->reg_base,
127 rk_phy->reg_offset + GRF_EMMCPHY_STATUS, 128 rk_phy->reg_offset + GRF_EMMCPHY_STATUS,
128 &dllrdy); 129 &dllrdy);