]> git.ipfire.org Git - thirdparty/linux.git/commit
drm/amd/display: Clean up PSR helper functions
authorAlex Hung <alex.hung@amd.com>
Fri, 15 May 2026 22:30:45 +0000 (16:30 -0600)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 3 Jun 2026 17:43:23 +0000 (13:43 -0400)
commit9aef3d167a1c0f1a59ef043ee7b0f525936fbfc6
tree96009d857742c3d05c27b18a9990a884bba8115b
parentbb3ab95ac78671b128314b3515aa007439b7b58d
drm/amd/display: Clean up PSR helper functions

[Why & How]
Use the existing local dc variable in amdgpu_dm_set_psr_caps() instead
of redundantly dereferencing link->ctx->dc.

Simplify amdgpu_dm_psr_is_active_allowed() by replacing with early
return and inlining the intermediate stream variable.

No functional changes.

Assisted-by: Copilot:Claude-Sonnet-4.6
Reviewed-by: Ray Wu <ray.wu@amd.com>
Signed-off-by: Alex Hung <alex.hung@amd.com>
Signed-off-by: Ray Wu <ray.wu@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_psr.c