Register color callbacks for ADL and beyond. While we have to register new callbacks for pre-blending color operations, re-use callbacks for post-blend operations. Co-developed-by: Chaitanya Kumar Borah <chaitanya.kumar.borah@xxxxxxxxx> Signed-off-by: Chaitanya Kumar Borah <chaitanya.kumar.borah@xxxxxxxxx> Signed-off-by: Uma Shankar <uma.shankar@xxxxxxxxx> --- drivers/gpu/drm/i915/display/intel_color.c | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_color.c b/drivers/gpu/drm/i915/display/intel_color.c index df2fc8f98dc9..3f3c1ac10330 100644 --- a/drivers/gpu/drm/i915/display/intel_color.c +++ b/drivers/gpu/drm/i915/display/intel_color.c @@ -3704,6 +3704,16 @@ static const struct intel_color_funcs i9xx_color_funcs = { .get_config = i9xx_get_config, }; +static const struct intel_color_funcs xelpd_color_funcs = { + .color_check = icl_color_check, + .color_commit_noarm = icl_color_commit_noarm, + .color_commit_arm = icl_color_commit_arm, + .load_luts = icl_load_luts, + .read_luts = icl_read_luts, + .lut_equal = icl_lut_equal, + .read_csc = icl_read_csc, +}; + static const struct intel_color_funcs tgl_color_funcs = { .color_check = icl_color_check, .color_commit_noarm = icl_color_commit_noarm, @@ -4141,7 +4151,9 @@ void intel_color_init_hooks(struct drm_i915_private *i915) else i915->display.funcs.color = &i9xx_color_funcs; } else { - if (DISPLAY_VER(i915) >= 12) + if (DISPLAY_VER(i915) >= 13) + i915->display.funcs.color = &xelpd_color_funcs; + else if (DISPLAY_VER(i915) == 12) i915->display.funcs.color = &tgl_color_funcs; else if (DISPLAY_VER(i915) == 11) i915->display.funcs.color = &icl_color_funcs; -- 2.38.1