Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/amd/display: using cm structure for lut3d related info

[Why]
Using the alternative implementation via cm structure of config
lut3d data

Reviewed-by: Austin Zheng <austin.zheng@amd.com>
Signed-off-by: Dillon Varone <Dillon.Varone@amd.com>
Signed-off-by: ChuanYu Tseng <ChuanYu.Tseng@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>

authored by

Dillon Varone and committed by
Alex Deucher
0b577cd6 add9aee8

+16 -10
+16 -10
drivers/gpu/drm/amd/display/dc/dml2_0/dml21/dml21_translation_helper.c
··· 601 601 602 602 plane->composition.viewport.stationary = false; 603 603 604 - if (plane_state->cm.flags.bits.lut3d_dma_enable) { 604 + if (plane_state->mcm_luts.lut3d_data.lut3d_src == DC_CM2_TRANSFER_FUNC_SOURCE_VIDMEM) { 605 605 plane->tdlut.setup_for_tdlut = true; 606 606 607 - switch (plane_state->cm.lut3d_dma.swizzle) { 608 - case CM_LUT_3D_SWIZZLE_LINEAR_RGB: 609 - case CM_LUT_3D_SWIZZLE_LINEAR_BGR: 607 + switch (plane_state->mcm_luts.lut3d_data.gpu_mem_params.layout) { 608 + case DC_CM2_GPU_MEM_LAYOUT_3D_SWIZZLE_LINEAR_RGB: 609 + case DC_CM2_GPU_MEM_LAYOUT_3D_SWIZZLE_LINEAR_BGR: 610 610 plane->tdlut.tdlut_addressing_mode = dml2_tdlut_sw_linear; 611 611 break; 612 - case CM_LUT_1D_PACKED_LINEAR: 613 - default: 612 + case DC_CM2_GPU_MEM_LAYOUT_1D_PACKED_LINEAR: 614 613 plane->tdlut.tdlut_addressing_mode = dml2_tdlut_simple_linear; 615 614 break; 616 615 } 617 616 618 - switch (plane_state->cm.lut3d_dma.size) { 619 - case CM_LUT_SIZE_333333: 617 + switch (plane_state->mcm_luts.lut3d_data.gpu_mem_params.size) { 618 + case DC_CM2_GPU_MEM_SIZE_171717: 619 + plane->tdlut.tdlut_width_mode = dml2_tdlut_width_17_cube; 620 + break; 621 + case DC_CM2_GPU_MEM_SIZE_333333: 620 622 plane->tdlut.tdlut_width_mode = dml2_tdlut_width_33_cube; 621 623 break; 622 - case CM_LUT_SIZE_171717: 624 + // handling when use case and HW support available 625 + case DC_CM2_GPU_MEM_SIZE_454545: 626 + case DC_CM2_GPU_MEM_SIZE_656565: 627 + break; 628 + case DC_CM2_GPU_MEM_SIZE_TRANSFORMED: 623 629 default: 624 - plane->tdlut.tdlut_width_mode = dml2_tdlut_width_17_cube; 630 + //plane->tdlut.tdlut_width_mode = dml2_tdlut_width_flatten; // dml2_tdlut_width_flatten undefined 625 631 break; 626 632 } 627 633 }