From fdeee9b388361f55c94860ab8952062fb2cf9fcb Mon Sep 17 00:00:00 2001 From: Haojian Zhuang Date: Thu, 22 Aug 2013 17:04:13 +0800 Subject: fb: use busy loop to replace detecting phy In some boards, system fails on detecting dsi command status. So use busy loop as workaround. Signed-off-by: Haojian Zhuang --- drivers/video/hisilicon/hi3620_dsi.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/drivers/video/hisilicon/hi3620_dsi.c b/drivers/video/hisilicon/hi3620_dsi.c index f945a7a417fa..e7140d2accb2 100644 --- a/drivers/video/hisilicon/hi3620_dsi.c +++ b/drivers/video/hisilicon/hi3620_dsi.c @@ -446,12 +446,20 @@ static int recv_generic_pkt(void __iomem *base, u8 *val, int len) static void wait_phy_ready(void __iomem *base) { +#if 0 unsigned int status; do { cpu_relax(); status = readl_relaxed(base + DSI_PHY_STATUS); } while (!(status & DSI_PHY_STOP_STATE0_LANE)); +#else + /* + * In some board, it always loop as dead. + * So use delay as workaround. + */ + msleep(5); +#endif } int set_packet(struct device *dev, u8 *cmd, int nr_payload) -- cgit v1.2.3