[PATCH 04/15] drm/amd/display: Replace msleep with udelay while read edid return defer.

Qingqing Zhuo qingqing.zhuo at amd.com
Wed Sep 16 19:36:24 UTC 2020


From: jinlong zhang <jinlong.zhang at amd.com>

[why]
while read edid return defer, then it enter to msleep,
but it actually took more time during msleep,
this will cause remaining edid read fail.

[how]
Replacing msleep with udelay, it will not take any extra time, edid return pass finally.

Signed-off-by: jinlong zhang <jinlong.zhang at amd.com>
Reviewed-by: Wenjing Liu <Wenjing.Liu at amd.com>
Acked-by: Qingqing Zhuo <qingqing.zhuo at amd.com>
---
 drivers/gpu/drm/amd/display/dc/dce/dce_aux.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_aux.c b/drivers/gpu/drm/amd/display/dc/dce/dce_aux.c
index 743042d5905a..cdcad82765e0 100644
--- a/drivers/gpu/drm/amd/display/dc/dce/dce_aux.c
+++ b/drivers/gpu/drm/amd/display/dc/dce/dce_aux.c
@@ -653,7 +653,7 @@ bool dce_aux_transfer_with_retries(struct ddc_service *ddc,
 					if ((*payload->reply == AUX_TRANSACTION_REPLY_AUX_DEFER) ||
 						(*payload->reply == AUX_TRANSACTION_REPLY_I2C_OVER_AUX_DEFER)) {
 						if (payload->defer_delay > 0)
-							msleep(payload->defer_delay);
+							udelay(payload->defer_delay * 1000);
 					}
 				}
 				break;
-- 
2.17.1



More information about the amd-gfx mailing list