Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp489916ybv; Fri, 7 Feb 2020 03:12:56 -0800 (PST) X-Google-Smtp-Source: APXvYqymYrA+o8YvKwaUlq7eT1XZ6lFx/FAH04BnidvpRi1srn8BRhZk8lEkyLleziCDVhWtmzyO X-Received: by 2002:aca:c256:: with SMTP id s83mr1748357oif.57.1581073976515; Fri, 07 Feb 2020 03:12:56 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581073976; cv=none; d=google.com; s=arc-20160816; b=vnIvoLhAFTo31W3aoKMmAkmf+Y7l1IJpqCcLVFXJMTSa7asAJNjXGD4WawnI/OryD/ vIsamBVBfnzVvfcgFnVBY+w/GCxkRigyKXHexwjK04L4MAcZxE2bRCRADwlM/SwVoFBH h+BztbvAJOl6ZUovd+rJek7CNz0VFHorCoOGQ48ivx1wPvRLq15opyS+PEdBEqJxQDO3 eAZHiou72mAKryASOTMNvhZc0NbIaFDWEBd2x6gEbCKoEl+GihXlVZcu37Qk8sKgQ9Ni HIj3U12xKzKgCiufKV0uL3EO2UOEiSW8Q0Gof0rl7MKs4hQeZugW/rDvBWm2CGmNLnAR 9EJA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:references :organization:in-reply-to:subject:cc:to:from; bh=eBj93L5XULY630lQwNgWRBaTJUnoosPLhLMBSK4ExPQ=; b=EapmqpoGpuTQdNyMxw1PSDpzLkt4ABODxCddXAtIsRyz5wqR3J+NuIzC4wAK3SlIrh 0HirJem93PUtHSmFiMOFEXeuujzghtqJOOQKBMa4+dglaw/xRi3lynGGQBY3brzNmf1E z4NY2klvdxrbTPVwG0iB3hVgOeejCMlGhkdCDBS38gdbLEXVI+zFLYYfWAuZYBAbnR+j ZV4H3ojvkjFEKWI/Q28J6qNxgyth5YcUf/CnbVyWuLOPL1rdTzBEMaa7SRLJCF2NYeSz lYAwLy+vjy2Q7ZN8Goag1XwiTC5xQuIXD0ghAaVtooZk40OsztTC1IzEE+LxMPAsfja6 djoA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u12si1566073otq.51.2020.02.07.03.12.44; Fri, 07 Feb 2020 03:12:56 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726936AbgBGLLP (ORCPT + 99 others); Fri, 7 Feb 2020 06:11:15 -0500 Received: from mga12.intel.com ([192.55.52.136]:41962 "EHLO mga12.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726798AbgBGLLO (ORCPT ); Fri, 7 Feb 2020 06:11:14 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga006.jf.intel.com ([10.7.209.51]) by fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 07 Feb 2020 03:11:14 -0800 X-IronPort-AV: E=Sophos;i="5.70,413,1574150400"; d="scan'208";a="236324213" Received: from jnikula-mobl3.fi.intel.com (HELO localhost) ([10.237.66.161]) by orsmga006-auth.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 07 Feb 2020 03:11:10 -0800 From: Jani Nikula To: Lyude Paul , dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org Cc: Joonas Lahtinen , Rodrigo Vivi , David Airlie , Daniel Vetter , Ville =?utf-8?B?U3lyasOkbMOk?= , Chris Wilson , Juha-Pekka Heikkila , Lee Shawn C , linux-kernel@vger.kernel.org Subject: Re: [PATCH 1/4] Revert "drm/i915: Don't use VBT for detecting DPCD backlight controls" In-Reply-To: <20200204192823.111404-2-lyude@redhat.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo References: <20200204192823.111404-1-lyude@redhat.com> <20200204192823.111404-2-lyude@redhat.com> Date: Fri, 07 Feb 2020 13:11:07 +0200 Message-ID: <87r1z61wl0.fsf@intel.com> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 04 Feb 2020, Lyude Paul wrote: > This reverts commit d2a4bb6f8bc8cf2d788adf7e59b5b52fe3a3333c. > > So, turns out that this ended up just breaking things. While many > laptops incorrectly advertise themselves as supporting PWM backlight > controls, they actually will only work with DPCD backlight controls. > Unfortunately, it also seems there are a number of systems which > advertise DPCD backlight controls in their eDP DPCD but don't actually > support them. Talking with some laptop manufacturers has shown it might > be possible to probe this support via the EDID (!?!?) but I haven't been > able to confirm that this would work on any other manufacturer's > systems. > > So in the mean time, we'll just revert this commit for now and go back > to the old way of doing things. The below sentence does not seem to match the patch: > Additionally, let's print out an info > message into the kernel log so that it's a little more obvious if a > system needs DPCD backlight controls enabled through a quirk (which > we'll introduce in the next commit). I've pushed the revert to dinq, with the above removed, thanks for the patch. I'll try to look into the rest of the patches soon... BR, Jani. > > Signed-off-by: Lyude Paul > Cc: Jani Nikula > --- > drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 9 ++++----- > 1 file changed, 4 insertions(+), 5 deletions(-) > > diff --git a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c > index e86feebef299..48276237b362 100644 > --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c > +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c > @@ -328,16 +328,15 @@ intel_dp_aux_display_control_capable(struct intel_connector *connector) > int intel_dp_aux_init_backlight_funcs(struct intel_connector *intel_connector) > { > struct intel_panel *panel = &intel_connector->panel; > - enum intel_backlight_type type = > - to_i915(intel_connector->base.dev)->vbt.backlight.type; > + struct drm_i915_private *dev_priv = to_i915(intel_connector->base.dev); > > if (i915_modparams.enable_dpcd_backlight == 0 || > (i915_modparams.enable_dpcd_backlight == -1 && > - !intel_dp_aux_display_control_capable(intel_connector))) > + dev_priv->vbt.backlight.type != INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE)) > return -ENODEV; > > - if (type != INTEL_BACKLIGHT_VESA_EDP_AUX_INTERFACE) > - DRM_DEBUG_DRIVER("Ignoring VBT backlight type\n"); > + if (!intel_dp_aux_display_control_capable(intel_connector)) > + return -ENODEV; > > panel->backlight.setup = intel_dp_aux_setup_backlight; > panel->backlight.enable = intel_dp_aux_enable_backlight; -- Jani Nikula, Intel Open Source Graphics Center