From: Martin Tsai Date: Fri, 2 Feb 2024 06:39:29 +0000 (+0800) Subject: drm/amd/display: should support dmub hw lock on Replay X-Git-Tag: microblaze-v6.10~28^2~22^2~29 X-Git-Url: http://git.monstr.eu/?a=commitdiff_plain;h=bfeefe6ea5f18cabb8fda55364079573804623f9;p=linux-2.6-microblaze.git drm/amd/display: should support dmub hw lock on Replay [Why] Without acquiring DMCUB hw lock, a race condition is caused with Panel Replay feature, which will trigger a hang. Indicate that a lock is necessary to prevent this when replay feature is enabled. [How] To allow dmub hw lock on Replay. Reviewed-by: Robin Chen Acked-by: Aurabindo Pillai Signed-off-by: Martin Tsai Tested-by: Daniel Wheeler Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/display/dc/dce/dmub_hw_lock_mgr.c b/drivers/gpu/drm/amd/display/dc/dce/dmub_hw_lock_mgr.c index ba1fec3016d5..bf636b28e3e1 100644 --- a/drivers/gpu/drm/amd/display/dc/dce/dmub_hw_lock_mgr.c +++ b/drivers/gpu/drm/amd/display/dc/dce/dmub_hw_lock_mgr.c @@ -65,5 +65,9 @@ bool should_use_dmub_lock(struct dc_link *link) { if (link->psr_settings.psr_version == DC_PSR_VERSION_SU_1) return true; + + if (link->replay_settings.replay_feature_enabled) + return true; + return false; }