linux-yocto/drivers/gpu/drm/arm/display/komeda
hongchi.peng 258905cb9a drm: komeda: Fix an issue related to normalized zpos
We use komeda_crtc_normalize_zpos to normalize zpos of affected planes
to their blending zorder in CU. If there's only one slave plane in
affected planes and its layer_split property is enabled, order++ for
its split layer, so that when calculating the normalized_zpos
of master planes, the split layer of the slave plane is included, but
the max_slave_zorder does not include the split layer and keep zero
because there's only one slave plane in affacted planes, although we
actually use two slave layers in this commit.

In most cases, this bug does not result in a commit failure, but assume
the following situation:
    slave_layer 0: zpos = 0, layer split enabled, normalized_zpos =
    0;(use slave_layer 2 as its split layer)
    master_layer 0: zpos = 2, layer_split enabled, normalized_zpos =
    2;(use master_layer 2 as its split layer)
    master_layer 1: zpos = 4, normalized_zpos = 4;
    master_layer 3: zpos = 5, normalized_zpos = 5;
    kcrtc_st->max_slave_zorder = 0;
When we use master_layer 3 as a input of CU in function
komeda_compiz_set_input and check it with function
komeda_component_check_input, the parameter idx is equal to
normailzed_zpos minus max_slave_zorder, the value of idx is 5
and is euqal to CU's max_active_inputs, so that
komeda_component_check_input returns a -EINVAL value.

To fix the bug described above, when calculating the max_slave_zorder
with the layer_split enabled, count the split layer in this calculation
directly.

Signed-off-by: hongchi.peng <hongchi.peng@siengine.com>
Acked-by: Liviu Dudau <liviu.dudau@arm.com>
Signed-off-by: Liviu Dudau <liviu.dudau@arm.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240826024517.3739-1-hongchi.peng@siengine.com
2024-08-30 13:44:12 +01:00
..
d71 drm/komeda: fix missing seq_file includes 2024-04-26 13:55:49 +10:00
komeda_color_mgmt.c drm/komeda: remove unused struct 'gamma_curve_segment' 2024-05-31 12:09:51 +01:00
komeda_color_mgmt.h
komeda_crtc.c drm/arm/komeda: Move pipeline prints to after the entire pipeline has been enabled 2024-05-10 11:26:07 +01:00
komeda_dev.c arm/komeda: Remove all CONFIG_DEBUG_FS conditional compilations 2024-06-14 08:57:28 +02:00
komeda_dev.h
komeda_drv.c drm/arm/komeda: update DMA mask to 40 bits 2024-05-10 11:26:24 +01:00
komeda_event.c
komeda_format_caps.c
komeda_format_caps.h
komeda_framebuffer.c drm/gem: rename struct drm_gem_dma_object.{paddr => dma_addr} 2022-08-03 18:32:27 +02:00
komeda_framebuffer.h
komeda_kms.c drm: komeda: Fix an issue related to normalized zpos 2024-08-30 13:44:12 +01:00
komeda_kms.h drm/arm/komeda: Move pipeline prints to after the entire pipeline has been enabled 2024-05-10 11:26:07 +01:00
komeda_pipeline_state.c drm/komeda: check for error-valued pointer 2024-06-10 13:20:37 +02:00
komeda_pipeline.c drm/arm/komeda: Move pipeline prints to after the entire pipeline has been enabled 2024-05-10 11:26:07 +01:00
komeda_pipeline.h
komeda_plane.c drm: Remove unnecessary include statements of drm_plane_helper.h 2022-07-26 18:42:04 +02:00
komeda_private_obj.c
komeda_wb_connector.c drm: Drop drm_framebuffer.h from drm_crtc.h 2022-06-20 23:53:55 +03:00
Makefile kbuild: use $(src) instead of $(srctree)/$(src) for source directory 2024-05-10 04:34:52 +09:00