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).
v2: Use connector->base.name for connector name (Jani) Signed-off-by: Bob Paauwe <bob.j.paa...@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 97922fb..e50dbbd0 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c @@ -10744,6 +10744,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 drm_connector_enum_list + * array to identify the connector. + */ + intel_config_get_integer(to_i915(connector->base.dev), + CFG_CONNECTOR, + connector->base.name, + "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 _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/intel-gfx