drm/amd/display: Call FP Protect Before Mode Programming/Mode Support
authorAustin Zheng <Austin.Zheng@amd.com>
Thu, 17 Apr 2025 14:24:29 +0000 (10:24 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 5 May 2025 16:58:36 +0000 (12:58 -0400)
commitfe3250f10819b411808ab9ae1d824c5fc9b59170
tree4902cbd1f465885f7e07e090bddc3204ff2e79d3
parent94da0735b67b3ada90a3e2e017d306f070306f1d
drm/amd/display: Call FP Protect Before Mode Programming/Mode Support

[Why]
Memory allocation occurs within dml21_validate() for adding phantom planes.
May cause kernel to be tainted due to usage of FP Start.

[How]
Move FP start from dml21_validate to before mode programming/mode support.
Calculations requiring floating point are all done within mode programming
or mode support.

Reviewed-by: Alvin Lee <alvin.lee2@amd.com>
Signed-off-by: Austin Zheng <Austin.Zheng@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/dc/dml2/dml21/dml21_wrapper.c