All of lore.kernel.org
 help / color / mirror / Atom feed
From: Swati Sharma <swati2.sharma@intel.com>
To: intel-gfx@lists.freedesktop.org
Cc: jani.nikula@intel.com, daniel.vetter@ffwll.ch,
	ankit.k.nautiyal@intel.com
Subject: [PATCH 07/11] [v2] drm/i915: Extract bdw_get_color_config()
Date: Mon, 15 Apr 2019 16:03:24 +0530	[thread overview]
Message-ID: <1555324408-26054-8-git-send-email-swati2.sharma@intel.com> (raw)
In-Reply-To: <1555324408-26054-1-git-send-email-swati2.sharma@intel.com>

Signed-off-by: Swati Sharma <swati2.sharma@intel.com>
---
 drivers/gpu/drm/i915/intel_color.c | 16 ++++++++++++++--
 1 file changed, 14 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/i915/intel_color.c b/drivers/gpu/drm/i915/intel_color.c
index 6ccb76f..74f000e 100644
--- a/drivers/gpu/drm/i915/intel_color.c
+++ b/drivers/gpu/drm/i915/intel_color.c
@@ -1407,6 +1407,17 @@ static void glk_get_color_config(struct intel_crtc_state *crtc_state)
 		bdw_get_gamma_config(crtc_state, PAL_PREC_INDEX_VALUE(0));
 }
 
+static void bdw_get_color_config(struct intel_crtc_state *crtc_state)
+{
+	if (crtc_state->gamma_mode == GAMMA_MODE_MODE_8BIT)
+		i9xx_get_color_config(crtc_state);
+	else if (crtc_state->gamma_mode == GAMMA_MODE_MODE_SPLIT)
+		bdw_get_gamma_config(crtc_state, PAL_PREC_SPLIT_MODE |
+				     PAL_PREC_INDEX_VALUE(512));
+	else
+		bdw_get_gamma_config(crtc_state, PAL_PREC_INDEX_VALUE(0));
+}
+
 void intel_color_init(struct intel_crtc *crtc)
 {
 	struct drm_i915_private *dev_priv = to_i915(crtc->base.dev);
@@ -1454,9 +1465,10 @@ void intel_color_init(struct intel_crtc *crtc)
 		} else if (IS_CANNONLAKE(dev_priv) || IS_GEMINILAKE(dev_priv)) {
 			dev_priv->display.load_luts = glk_load_luts;
 			dev_priv->display.get_color_config = glk_get_color_config;
-		}
-		else if (INTEL_GEN(dev_priv) >= 8)
+		} else if (INTEL_GEN(dev_priv) >= 8) {
 			dev_priv->display.load_luts = bdw_load_luts;
+			dev_priv->display.get_color_config = bdw_get_color_config;
+		}
 		else if (INTEL_GEN(dev_priv) >= 7)
 			dev_priv->display.load_luts = ivb_load_luts;
 		else
-- 
1.9.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  parent reply	other threads:[~2019-04-15 10:38 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-04-15 10:33 [PATCH 00/11] drm/i915: adding state checker for gamma lut values Swati Sharma
2019-04-15 10:33 ` [PATCH 01/11] [v3] drm/i915: Introduce vfunc intel_get_color_config to create hw lut Swati Sharma
2019-04-16  9:15   ` Jani Nikula
2019-04-15 10:33 ` [PATCH 02/11] [v2] drm/i915: Extract i9xx_get_color_config() Swati Sharma
2019-04-16 10:42   ` Jani Nikula
2019-04-16 10:45     ` Jani Nikula
2019-04-15 10:33 ` [PATCH 03/11] [v2] drm/i915: Extract cherryview_get_color_config() Swati Sharma
2019-04-15 10:33 ` [PATCH 04/11] [v2] drm/i915: Extract i965_get_color_config() Swati Sharma
2019-04-15 10:33 ` [PATCH 05/11] [v2] drm/i915: Extract icl_get_color_config() Swati Sharma
2019-04-15 10:33 ` [PATCH 06/11] [v2] drm/i915: Extract glk_get_color_config() Swati Sharma
2019-04-15 10:33 ` Swati Sharma [this message]
2019-04-15 10:33 ` [PATCH 08/11] [v2] drm/i915: Extract ivb_get_color_config() Swati Sharma
2019-04-15 10:33 ` [PATCH 09/11] [v2] drm/i915: Extract ilk_get_color_config() Swati Sharma
2019-04-15 10:33 ` [PATCH 10/11] [v2] drm/i915: Enable intel_get_color_config() Swati Sharma
2019-04-16  9:17   ` Jani Nikula
2019-04-15 10:33 ` [PATCH 11/11] [v3] drm/i915: Add intel_compare_color_lut() to compare hw and sw gamma lut values Swati Sharma
2019-04-16  9:29   ` Jani Nikula
2019-04-16 11:42   ` [Intel-gfx] " Dan Carpenter
2019-04-15 10:55 ` ✗ Fi.CI.CHECKPATCH: warning for drm/i915: adding state checker for gamma lut values (rev4) Patchwork
2019-04-15 11:00 ` ✗ Fi.CI.SPARSE: " Patchwork
2019-04-15 11:13 ` ✗ Fi.CI.BAT: failure " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2019-04-09 13:35 [PATCH 00/11] drm/i915: adding state checker for gamma lut values Swati Sharma
2019-04-09 13:35 ` [PATCH 07/11] [v2] drm/i915: Extract bdw_get_color_config() Swati Sharma
2019-04-09 13:32 [PATCH 00/11] adding state checker for gamma lut values Swati Sharma
2019-04-09 13:32 ` [PATCH 07/11] [v2] drm/i915: Extract bdw_get_color_config() Swati Sharma

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1555324408-26054-8-git-send-email-swati2.sharma@intel.com \
    --to=swati2.sharma@intel.com \
    --cc=ankit.k.nautiyal@intel.com \
    --cc=daniel.vetter@ffwll.ch \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=jani.nikula@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.