diff options
author | Robin Chen <robin.chen@amd.com> | 2023-02-17 20:47:57 +0800 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2023-03-15 18:45:13 -0400 |
commit | eeefe7c4820b6baa0462a8b723ea0a3b5846ccae (patch) | |
tree | e63ca600a79ee9354eeb66ff59fa1524cc7648fb /drivers/gpu/drm/amd/display/dc/link | |
parent | 825b3772a2047bd32ed3b3914234da0de19ef2e0 (diff) | |
download | linux-stable-eeefe7c4820b6baa0462a8b723ea0a3b5846ccae.tar.gz linux-stable-eeefe7c4820b6baa0462a8b723ea0a3b5846ccae.tar.bz2 linux-stable-eeefe7c4820b6baa0462a8b723ea0a3b5846ccae.zip |
drm/amd/display: hpd rx irq not working with eDP interface
[Why]
This is the fix for the defect of commit ab144f0b4ad6
("drm/amd/display: Allow individual control of eDP hotplug support").
[How]
To revise the default eDP hotplug setting and use the enum to git rid
of the magic number for different options.
Fixes: ab144f0b4ad6 ("drm/amd/display: Allow individual control of eDP hotplug support")
Cc: stable@vger.kernel.org
Cc: Mario Limonciello <mario.limonciello@amd.com>
Reviewed-by: Wenjing Liu <Wenjing.Liu@amd.com>
Acked-by: Qingqing Zhuo <qingqing.zhuo@amd.com>
Signed-off-by: Robin Chen <robin.chen@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/display/dc/link')
-rw-r--r-- | drivers/gpu/drm/amd/display/dc/link/link_factory.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/display/dc/link/link_factory.c b/drivers/gpu/drm/amd/display/dc/link/link_factory.c index 995032a341b3..3951d48118c4 100644 --- a/drivers/gpu/drm/amd/display/dc/link/link_factory.c +++ b/drivers/gpu/drm/amd/display/dc/link/link_factory.c @@ -528,14 +528,18 @@ static bool construct_phy(struct dc_link *link, link->irq_source_hpd = DC_IRQ_SOURCE_INVALID; switch (link->dc->config.allow_edp_hotplug_detection) { - case 1: // only the 1st eDP handles hotplug + case HPD_EN_FOR_ALL_EDP: + link->irq_source_hpd_rx = + dal_irq_get_rx_source(link->hpd_gpio); + break; + case HPD_EN_FOR_PRIMARY_EDP_ONLY: if (link->link_index == 0) link->irq_source_hpd_rx = dal_irq_get_rx_source(link->hpd_gpio); else link->irq_source_hpd = DC_IRQ_SOURCE_INVALID; break; - case 2: // only the 2nd eDP handles hotplug + case HPD_EN_FOR_SECONDARY_EDP_ONLY: if (link->link_index == 1) link->irq_source_hpd_rx = dal_irq_get_rx_source(link->hpd_gpio); @@ -543,6 +547,7 @@ static bool construct_phy(struct dc_link *link, link->irq_source_hpd = DC_IRQ_SOURCE_INVALID; break; default: + link->irq_source_hpd = DC_IRQ_SOURCE_INVALID; break; } } |