drm/msm/dp: make eDP panel as the first connected connector
authorKuogee Hsieh <quic_khsieh@quicinc.com>
Wed, 6 Jul 2022 19:32:08 +0000 (12:32 -0700)
committerAbhinav Kumar <quic_abhinavk@quicinc.com>
Wed, 20 Jul 2022 19:04:04 +0000 (12:04 -0700)
commitdeffa2d75db7e7a9a1fe3dad4f99310bff7b6449
tree633f0285d4168de56c5b615108dd78ebd9b717a9
parentcb77085b1f0a86ef9dfba86b5f3ed6c3340c2ea3
drm/msm/dp: make eDP panel as the first connected connector

Some userspace presumes that the first connected connector is the main
display, where it's supposed to display e.g. the login screen. For
laptops, this should be the main panel.

This patch call drm_helper_move_panel_connectors_to_head() after
drm_bridge_connector_init() to make sure eDP stay at head of
connected connector list. This fixes unexpected corruption happen
at eDP panel if eDP is not placed at head of connected connector
list.

Changes in v2:
-- move drm_helper_move_panel_connectors_to_head() to
dpu_kms_drm_obj_init()

Changes in v4:
-- move drm_helper_move_panel_connectors_to_head() to msm_drm_init()

Signed-off-by: Kuogee Hsieh <quic_khsieh@quicinc.com>
Reviewed-by: Abhinav Kumar <quic_abhinavk@quicinc.com>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Tested-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Reviewed-by: Stephen Boyd <swboyd@chromium.org>
Fixes: ef7837ff091c ("drm/msm/dp: Add DP controllers for sc7280")
Patchwork: https://patchwork.freedesktop.org/patch/492581/
Link: https://lore.kernel.org/r/1657135928-31195-1-git-send-email-quic_khsieh@quicinc.com
Signed-off-by: Abhinav Kumar <quic_abhinavk@quicinc.com>
drivers/gpu/drm/msm/msm_drv.c