aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/ast/ast_mode.c
diff options
context:
space:
mode:
authorThomas Zimmermann <[email protected]>2024-07-17 14:24:19 +0000
committerThomas Zimmermann <[email protected]>2024-07-30 10:15:37 +0000
commit2281475168d2ab3fbd763c2fd762f99a411fa1b6 (patch)
treeec53dd17b217a5453c8583e810dfe9ac4406cf89 /drivers/gpu/drm/ast/ast_mode.c
parentdrm/ast: astdp: Only test HDP state in ast_astdp_is_connected() (diff)
downloadkernel-2281475168d2ab3fbd763c2fd762f99a411fa1b6.tar.gz
kernel-2281475168d2ab3fbd763c2fd762f99a411fa1b6.zip
drm/ast: astdp: Perform link training during atomic_enable
The place for link training is in the encoder's atomic_enable helper. Remove all related tests from other helper ASTDP functions; especially ast_astdp_is_connected(), which tests HPD status. DP link training is controlled by the firmware. A status flag reports success or failure. The process can be fragile on Aspeed hardware. Moving the test from connector detection to the atomic_enable allows for several retries and a longer timeout. Signed-off-by: Thomas Zimmermann <[email protected]> Reviewed-by: Jocelyn Falempe <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
Diffstat (limited to 'drivers/gpu/drm/ast/ast_mode.c')
-rw-r--r--drivers/gpu/drm/ast/ast_mode.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/ast/ast_mode.c b/drivers/gpu/drm/ast/ast_mode.c
index dc8f639e82fd..0a206b17e22b 100644
--- a/drivers/gpu/drm/ast/ast_mode.c
+++ b/drivers/gpu/drm/ast/ast_mode.c
@@ -1621,6 +1621,8 @@ static void ast_astdp_encoder_helper_atomic_enable(struct drm_encoder *encoder,
struct ast_device *ast = to_ast_device(dev);
ast_dp_power_on_off(dev, AST_DP_POWER_ON);
+ ast_dp_link_training(ast);
+
ast_wait_for_vretrace(ast);
ast_dp_set_on_off(dev, 1);
}