]> git.ipfire.org Git - thirdparty/linux.git/commit
drm/amd/display: Enable runtime register offset init for DCN32 DMUB
authorAurabindo Pillai <aurabindo.pillai@amd.com>
Tue, 8 Aug 2023 20:25:59 +0000 (16:25 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 30 Aug 2023 18:58:44 +0000 (14:58 -0400)
commit96182df99dadd4b59b7338b29bf45a90ad722625
tree279ff406c8c32e774931c61a4be3ece478484e22
parent45f98fccb1f6895f527bd5f811f23478c2f920f5
drm/amd/display: Enable runtime register offset init for DCN32 DMUB

[Why&How]
DMUB subsystem was continuing to use compile time offset calculation for
register access. Switch this to runtime calculation to stay consistent
with rest of DC code.

To enable this, an additional interface init_reg_offsets() are added to
DMUB's hw_funcs struct. Asics with runtime register offset calculation
enabled shall populate this hook with a fn pointer that will invoke the
necessary macros to calculate the offset.

Reviewed-by: Alvin Lee <alvin.lee2@amd.com>
Acked-by: Wayne Lin <wayne.lin@amd.com>
Signed-off-by: Aurabindo Pillai <aurabindo.pillai@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
drivers/gpu/drm/amd/display/dmub/dmub_srv.h
drivers/gpu/drm/amd/display/dmub/src/dmub_dcn32.c
drivers/gpu/drm/amd/display/dmub/src/dmub_dcn32.h
drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c