kernel_samsung_a53x/drivers/gpu/drm/amd/display/dc/dml
Alex Hung 293de81901 drm/amd/display: Initialize get_bytes_per_element's default to 1
[ Upstream commit 4067f4fa0423a89fb19a30b57231b384d77d2610 ]

Variables, used as denominators and maybe not assigned to other values,
should not be 0. bytes_per_element_y & bytes_per_element_c are
initialized by get_bytes_per_element() which should never return 0.

This fixes 10 DIVIDE_BY_ZERO issues reported by Coverity.

Signed-off-by: Alex Hung <alex.hung@amd.com>
Reviewed-by: Aurabindo Pillai <aurabindo.pillai@amd.com>
Tested-by: Daniel Wheeler <daniel.wheeler@amd.com>
Signed-off-by: Rodrigo Siqueira <rodrigo.siqueira@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-23 23:21:41 +01:00
..
dcn20 drm/amd/display: Initialize get_bytes_per_element's default to 1 2024-11-23 23:21:41 +01:00
dcn21 drm/amd/display: Initialize get_bytes_per_element's default to 1 2024-11-23 23:21:41 +01:00
dcn30 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dc_features.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
display_mode_enums.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
display_mode_lib.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
display_mode_lib.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
display_mode_structs.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
display_mode_vba.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
display_mode_vba.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
display_rq_dlg_helpers.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
display_rq_dlg_helpers.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dml1_display_rq_dlg_calc.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dml1_display_rq_dlg_calc.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dml_inline_defs.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
dml_logger.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00