[Intel-gfx] [RFC 03/12] drm/i915/config: Add init-time configuration of bits per color.

Bob Paauwe bob.j.paauwe at intel.com
Thu Feb 12 15:41:29 PST 2015


Allow the init-time configuration to specify the bits per color value
that gets used if bits per color is not present in EDID data (or if EDID
is not present).

Signed-off-by: Bob Paauwe <bob.j.paauwe at intel.com>
---
 drivers/gpu/drm/i915/intel_display.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index de6de83..347dbad 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -9957,6 +9957,20 @@ connected_sink_compute_bpp(struct intel_connector *connector,
 		connector->base.base.id,
 		connector->base.name);
 
+	/* If !bpc then see if one was specified in the static configuation */
+	if (connector->base.display_info.bpc == 0) {
+		/*
+		 * This is making the assumption that the static configuration
+		 * will use the names defined in the intel_output_name()
+		 * function to identify the output.
+		 */
+		intel_config_get_integer(to_i915(connector->base.dev),
+					CFG_CONNECTOR,
+					intel_output_name(connector),
+					"bits_per_color",
+					&connector->base.display_info.bpc);
+	}
+
 	/* Don't use an invalid EDID bpc value */
 	if (connector->base.display_info.bpc &&
 	    connector->base.display_info.bpc * 3 < bpp) {
-- 
2.1.0



More information about the Intel-gfx mailing list