[Intel-gfx] [PATCH 1/2] drm/i915: Report the origin of the LVDS fixed panel mode

Jani Nikula jani.nikula at linux.intel.com
Thu Nov 22 17:10:07 CET 2012


Reviewed-by: Jani Nikula <jani.nikula at intel.com>


On Wed, 21 Nov 2012, Chris Wilson <chris at chris-wilson.co.uk> wrote:
> Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
> ---
>  drivers/gpu/drm/i915/intel_lvds.c |   11 ++++++++++-
>  1 file changed, 10 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/intel_lvds.c b/drivers/gpu/drm/i915/intel_lvds.c
> index 860fa71..5b38c17 100644
> --- a/drivers/gpu/drm/i915/intel_lvds.c
> +++ b/drivers/gpu/drm/i915/intel_lvds.c
> @@ -1083,6 +1083,9 @@ bool intel_lvds_init(struct drm_device *dev)
>  
>  	list_for_each_entry(scan, &connector->probed_modes, head) {
>  		if (scan->type & DRM_MODE_TYPE_PREFERRED) {
> +			DRM_DEBUG_KMS("using preferred mode from EDID: ");
> +			drm_mode_debug_printmodeline(scan);
> +
>  			fixed_mode = drm_mode_duplicate(dev, scan);
>  			intel_find_lvds_downclock(dev, fixed_mode, connector);
>  			goto out;
> @@ -1091,6 +1094,9 @@ bool intel_lvds_init(struct drm_device *dev)
>  
>  	/* Failed to get EDID, what about VBT? */
>  	if (dev_priv->lfp_lvds_vbt_mode) {
> +		DRM_DEBUG_KMS("using mode from VBT: ");
> +		drm_mode_debug_printmodeline(dev_priv->lfp_lvds_vbt_mode);
> +
>  		fixed_mode = drm_mode_duplicate(dev, dev_priv->lfp_lvds_vbt_mode);
>  		if (fixed_mode) {
>  			fixed_mode->type |= DRM_MODE_TYPE_PREFERRED;
> @@ -1115,8 +1121,11 @@ bool intel_lvds_init(struct drm_device *dev)
>  	if (crtc && (lvds & LVDS_PORT_EN)) {
>  		struct drm_display_mode mode;
>  
> -		if (intel_crtc_get_mode(crtc, &mode))
> +		if (intel_crtc_get_mode(crtc, &mode)) {
> +			DRM_DEBUG_KMS("using current (BIOS) mode: ");
> +			drm_mode_debug_printmodeline(&mode);
>  			fixed_mode = drm_mode_duplicate(dev, &mode);
> +		}
>  		if (fixed_mode) {
>  			fixed_mode->type |= DRM_MODE_TYPE_PREFERRED;
>  			fixed_mode->flags = intel_lvds_get_mode_flags(intel_encoder);
> -- 
> 1.7.10.4
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx



More information about the Intel-gfx mailing list