]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
drm/amd/display: Add check for granularity in dml ceil/floor helpers
authorRoman Li <Roman.Li@amd.com>
Fri, 13 Dec 2024 18:51:07 +0000 (13:51 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 6 Jan 2025 19:44:28 +0000 (14:44 -0500)
commitf6e09701c3eb2ccb8cb0518e0b67f1c69742a4ec
tree56bca1199d443336e2bdd028619b9835d5ccaa1e
parent79a57f9479de9c6fc3a8c4f50e7c853a134f9b41
drm/amd/display: Add check for granularity in dml ceil/floor helpers

[Why]
Wrapper functions for dcn_bw_ceil2() and dcn_bw_floor2()
should check for granularity is non zero to avoid assert and
divide-by-zero error in dcn_bw_ functions.

[How]
Add check for granularity 0.

Cc: Mario Limonciello <mario.limonciello@amd.com>
Reviewed-by: Alvin Lee <alvin.lee2@amd.com>
Signed-off-by: Roman Li <Roman.Li@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/dml/dml_inline_defs.h