]> git.ipfire.org Git - thirdparty/linux.git/commit
drm/amd/display: Do not elevate mem_type change to full update
authorLeo Li <sunpeng.li@amd.com>
Wed, 11 Dec 2024 17:06:24 +0000 (12:06 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 10 Jan 2025 17:10:08 +0000 (12:10 -0500)
commit4caacd1671b7a013ad04cd8b6398f002540bdd4d
treeb08aa6ce2cf66d3d0ce1b8330cc836e09f08897c
parentaa6713fa2046f4c09bf3013dd1420ae15603ca6f
drm/amd/display: Do not elevate mem_type change to full update

[Why]

There should not be any need to revalidate bandwidth on memory placement
change, since the fb is expected to be pinned to DCN-accessable memory
before scanout. For APU it's DRAM, and DGPU, it's VRAM. However, async
flips + memory type change needs to be rejected.

[How]

Do not set lock_and_validation_needed on mem_type change. Instead,
reject an async_flip request if the crtc's buffer(s) changed mem_type.

This may fix stuttering/corruption experienced with PSR SU and PSR1
panels, if the compositor allocates fbs in both VRAM carveout and GTT
and flips between them.

Fixes: a7c0cad0dc06 ("drm/amd/display: ensure async flips are only accepted for fast updates")
Reviewed-by: Tom Chung <chiahsuan.chung@amd.com>
Signed-off-by: Leo Li <sunpeng.li@amd.com>
Signed-off-by: Tom Chung <chiahsuan.chung@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c