public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/bridge: Add 200ms delay to wait FW HPD status stable
@ 2023-09-21  9:14 Xin Ji
  2023-09-21 12:09 ` Jani Nikula
  0 siblings, 1 reply; 5+ messages in thread
From: Xin Ji @ 2023-09-21  9:14 UTC (permalink / raw)
  To: Andrzej Hajda, Neil Armstrong, Robert Foss, Laurent Pinchart,
	Jonas Karlman, Jernej Skrabec, David Airlie, Daniel Vetter
  Cc: bliang, qwen, hsinyi, Xin Ji, dri-devel, linux-kernel

For the none-interrupt design(sink device is panel, polling HPD
status when chip power on), anx7625 FW has more than 200ms HPD
de-bounce time in FW, for the safety to get HPD status, driver
better to wait 200ms before HPD detection after OS resume back.

Signed-off-by: Xin Ji <xji@analogixsemi.com>
---
 drivers/gpu/drm/bridge/analogix/anx7625.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/gpu/drm/bridge/analogix/anx7625.c b/drivers/gpu/drm/bridge/analogix/anx7625.c
index 51abe42c639e..833d6d50a03d 100644
--- a/drivers/gpu/drm/bridge/analogix/anx7625.c
+++ b/drivers/gpu/drm/bridge/analogix/anx7625.c
@@ -1464,6 +1464,9 @@ static int _anx7625_hpd_polling(struct anx7625_data *ctx,
 	if (ctx->pdata.intp_irq)
 		return 0;
 
+	/* Delay 200ms for FW HPD de-bounce */
+	usleep_range(200000, 201000);
+
 	ret = readx_poll_timeout(anx7625_read_hpd_status_p0,
 				 ctx, val,
 				 ((val & HPD_STATUS) || (val < 0)),
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-09-22  7:01 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-09-21  9:14 [PATCH] drm/bridge: Add 200ms delay to wait FW HPD status stable Xin Ji
2023-09-21 12:09 ` Jani Nikula
2023-09-21 12:13   ` Laurent Pinchart
2023-09-22  6:57     ` Xin Ji
2023-09-22  7:00   ` Xin Ji

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox