From: Shawn Lin Date: Mon, 25 Apr 2016 01:59:14 +0000 (+0800) Subject: phy: rockchip-emmc: fix dllrdy timeout issue X-Git-Tag: firefly_0821_release~2738 X-Git-Url: http://plrg.eecs.uci.edu/git/?p=firefly-linux-kernel-4.4.55.git;a=commitdiff_plain;h=9faaf821a7f0115c300b418d09dd07979b3de989 phy: rockchip-emmc: fix dllrdy timeout issue According to the databook, 10.2us is the max time for dll to be ready to work. However from the test, some chips need 20us for dll to ready. So this patch add some extra margin for dllrdy to be ready to meet the reality. Change-Id: Ie5362b4403309d260ac621b8b20a0f5b579d3153 Signed-off-by: Shawn Lin --- diff --git a/drivers/phy/phy-rockchip-emmc.c b/drivers/phy/phy-rockchip-emmc.c index 3162554d6c16..3a2bbb703253 100644 --- a/drivers/phy/phy-rockchip-emmc.c +++ b/drivers/phy/phy-rockchip-emmc.c @@ -141,9 +141,10 @@ static int rockchip_emmc_phy_power(struct rockchip_emmc_phy *rk_phy, PHYCTRL_ENDLL_SHIFT)); /* * After enable analog DLL circuits, we need extra 10.2us - * for dll to be ready for work. + * for dll to be ready for work. But according to the test, we + * find some chips need more than 25us. */ - udelay(11); + udelay(30); regmap_read(rk_phy->reg_base, rk_phy->reg_offset + GRF_EMMCPHY_STATUS, &dllrdy);