0514-drm-vc4-Increase-timeout-for-HDMI_SCHEDULER_CONTROL-.patch 1.4 KB

12345678910111213141516171819202122232425262728293031323334
  1. From 4fe0280a07dea7997dd8a789c704f69b5620cdd2 Mon Sep 17 00:00:00 2001
  2. From: Eric Anholt <eric@anholt.net>
  3. Date: Wed, 28 Sep 2016 17:21:05 -0700
  4. Subject: [PATCH] drm/vc4: Increase timeout for HDMI_SCHEDULER_CONTROL changes.
  5. Fixes occasional debug spew at boot when connected directly through
  6. HDMI, and probably confusing the HDMI state machine when we go trying
  7. to poke registers for the enable sequence too soon.
  8. Signed-off-by: Eric Anholt <eric@anholt.net>
  9. ---
  10. drivers/gpu/drm/vc4/vc4_hdmi.c | 4 ++--
  11. 1 file changed, 2 insertions(+), 2 deletions(-)
  12. --- a/drivers/gpu/drm/vc4/vc4_hdmi.c
  13. +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c
  14. @@ -408,7 +408,7 @@ static void vc4_hdmi_encoder_enable(stru
  15. VC4_HDMI_SCHEDULER_CONTROL_MODE_HDMI);
  16. ret = wait_for(HDMI_READ(VC4_HDMI_SCHEDULER_CONTROL) &
  17. - VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE, 1);
  18. + VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE, 1000);
  19. WARN_ONCE(ret, "Timeout waiting for "
  20. "VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE\n");
  21. } else {
  22. @@ -420,7 +420,7 @@ static void vc4_hdmi_encoder_enable(stru
  23. ~VC4_HDMI_SCHEDULER_CONTROL_MODE_HDMI);
  24. ret = wait_for(!(HDMI_READ(VC4_HDMI_SCHEDULER_CONTROL) &
  25. - VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE), 1);
  26. + VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE), 1000);
  27. WARN_ONCE(ret, "Timeout waiting for "
  28. "!VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE\n");
  29. }