diff options
Diffstat (limited to 'common/recipes-kernel/linux/linux-yocto-4.19.8/1539-drm-amd-display-Re-add-custom-degamma-support.patch')
-rw-r--r-- | common/recipes-kernel/linux/linux-yocto-4.19.8/1539-drm-amd-display-Re-add-custom-degamma-support.patch | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/linux-yocto-4.19.8/1539-drm-amd-display-Re-add-custom-degamma-support.patch b/common/recipes-kernel/linux/linux-yocto-4.19.8/1539-drm-amd-display-Re-add-custom-degamma-support.patch new file mode 100644 index 00000000..35412614 --- /dev/null +++ b/common/recipes-kernel/linux/linux-yocto-4.19.8/1539-drm-amd-display-Re-add-custom-degamma-support.patch @@ -0,0 +1,39 @@ +From 42add52df35a3eb337a2d1b26874f5cf633a3245 Mon Sep 17 00:00:00 2001 +From: David Francis <David.Francis@amd.com> +Date: Mon, 11 Feb 2019 14:15:19 -0500 +Subject: [PATCH 1539/2940] drm/amd/display: Re-add custom degamma support + +[Why] +The dc_gamma_type CUSTOM_GAMMA is used to represent degamma +mappings passed in by drm. This type of gamma must be interpolated +into a transfer function by apply_1d_lut. The line in +mod_color_calculate_degamma_params that handled this case +was erroneously removed. + +[How] +For CUSTOM_GAMMA degamma, calculate the lut as before. + +Change-Id: I3d75fa94e19fdb25294a0784e949946cc8c58e4b +Signed-off-by: David Francis <David.Francis@amd.com> +Reviewed-by: Krunoslav Kovac <Krunoslav.Kovac@amd.com> +Acked-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com> +--- + drivers/gpu/drm/amd/display/modules/color/color_gamma.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/drivers/gpu/drm/amd/display/modules/color/color_gamma.c b/drivers/gpu/drm/amd/display/modules/color/color_gamma.c +index 0fbc8fbc3541..a1055413bade 100644 +--- a/drivers/gpu/drm/amd/display/modules/color/color_gamma.c ++++ b/drivers/gpu/drm/amd/display/modules/color/color_gamma.c +@@ -1854,6 +1854,8 @@ bool mod_color_calculate_degamma_params(struct dc_transfer_func *input_tf, + coordinates_x, axis_x, curve, + MAX_HW_POINTS, tf_pts, + mapUserRamp && ramp && ramp->type == GAMMA_RGB_256); ++ if (ramp->type == GAMMA_CUSTOM) ++ apply_lut_1d(ramp, MAX_HW_POINTS, tf_pts); + + ret = true; + +-- +2.17.1 + |