Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp1276419ybl; Tue, 3 Dec 2019 04:43:05 -0800 (PST) X-Google-Smtp-Source: APXvYqxxjdOqJ/JGvKjQCd9lfIdYRY80pz8cF2cmzq6WXhwFBd4VdI3X2Qlv8pRfVkMP8dwhrqOL X-Received: by 2002:a9d:53c9:: with SMTP id i9mr2942448oth.172.1575376985394; Tue, 03 Dec 2019 04:43:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1575376985; cv=none; d=google.com; s=arc-20160816; b=Boh89axCRHbCpcyuaQMsT0hS5v3Ug7Sf5mFcF8G3F5VgZa9f25a9pwSyfg/zZi3/G2 DAbPk12PhtYCuFF8QVhBbe9WPx0xxwNQSFVp5unlUVrcihaxKFKj3v1BXNQtucz5XyEP 7NBYoexO6BQv16k6B7WRE6cqJEMVO+LC74KMo+fGsybX+55RXZNc/9JiKWXcOoGkb4SF TadqYLcUeL/8qx/dUMAhYE7fMlUPrxZLnGgQkuhyMTJkT3TycnXCusVZma3PHpwmBpTL NN4QrbOpC4qRgi/tLFhs6612eHJK6RzI1vPQnl2aMCWyvqrN7XtmAT1hyWj+9c1kYd+F B/gw== 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=CcuqVS7P+kgO+AwlllHqSYrML/9jYwiIW303nRukRhQ=; b=FgAlRyMtF5Bgj/FnELcTd8VzOxEOWZeakRKgYMoR4zBrT3oc1QBuY4saDrRM+3+Wu3 x2zLVROqpiVbE0IX9e+GDpj3FYYvyP4OKlSNd3JPf0dgzycEmUqu+xK4XbSZWzX3j8hz AQS3kk6oKR9kJxV12dRGbh0KV/in8fu91EpTWV1WLNqivQ/7nGREq27yFywgugYb1ETr vQs2GxtKT111TAtb35BtqUzrW8BzoG74hmSmFEiFgjtIb1y2ILS1s0J6a74EiiKxIzJR PoyjxXbwK0PAACdMB4KwmIUVncx0iYn4X1vmFD7QYFpQjwRWzk+/O9jgWFJidAZ//9OS ELyw== 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 h22si1107171otn.279.2019.12.03.04.42.52; Tue, 03 Dec 2019 04:43:05 -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 S1726365AbfLCMlt (ORCPT + 99 others); Tue, 3 Dec 2019 07:41:49 -0500 Received: from mga11.intel.com ([192.55.52.93]:50685 "EHLO mga11.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725957AbfLCMlt (ORCPT ); Tue, 3 Dec 2019 07:41:49 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 03 Dec 2019 04:41:49 -0800 X-IronPort-AV: E=Sophos;i="5.69,273,1571727600"; d="scan'208";a="200986464" Received: from jnikula-mobl3.fi.intel.com (HELO localhost) ([10.237.66.161]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 03 Dec 2019 04:41:46 -0800 From: Jani Nikula To: Lyude Paul , intel-gfx@lists.freedesktop.org Cc: Joonas Lahtinen , Rodrigo Vivi , David Airlie , Daniel Vetter , dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 4/5] drm/i915: Auto detect DPCD backlight support by default In-Reply-To: <20191122231616.2574-5-lyude@redhat.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo References: <20191122231616.2574-1-lyude@redhat.com> <20191122231616.2574-5-lyude@redhat.com> Date: Tue, 03 Dec 2019 14:41:44 +0200 Message-ID: <87o8wpinsn.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 Fri, 22 Nov 2019, Lyude Paul wrote: > Turns out we actually already have some companies, such as Lenovo, > shipping machines with AMOLED screens that don't allow controlling the > backlight through the usual PWM interface and only allow controlling it > through the standard EDP DPCD interface. One example of one of these > laptops is the X1 Extreme 2nd Generation. > > Since we've got systems that need this turned on by default now to have > backlight controls working out of the box, let's start auto-detecting it > for systems by default based on what the VBT tells us. We do this by > changing the default value for the enable_dpcd_backlight module param > from 0 to -1. > > Signed-off-by: Lyude Paul Reviewed-by: Jani Nikula > --- > drivers/gpu/drm/i915/i915_params.c | 2 +- > drivers/gpu/drm/i915/i915_params.h | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/i915/i915_params.c b/drivers/gpu/drm/i915/i915_params.c > index 1dd1f3652795..31eed60c167e 100644 > --- a/drivers/gpu/drm/i915/i915_params.c > +++ b/drivers/gpu/drm/i915/i915_params.c > @@ -172,7 +172,7 @@ i915_param_named_unsafe(inject_probe_failure, uint, 0400, > > i915_param_named(enable_dpcd_backlight, int, 0600, > "Enable support for DPCD backlight control" > - "(-1=use per-VBT LFP backlight type setting, 0=disabled [default], 1=enabled)"); > + "(-1=use per-VBT LFP backlight type setting [default], 0=disabled, 1=enabled)"); > > #if IS_ENABLED(CONFIG_DRM_I915_GVT) > i915_param_named(enable_gvt, bool, 0400, > diff --git a/drivers/gpu/drm/i915/i915_params.h b/drivers/gpu/drm/i915/i915_params.h > index 31b88f297fbc..a79d0867f77a 100644 > --- a/drivers/gpu/drm/i915/i915_params.h > +++ b/drivers/gpu/drm/i915/i915_params.h > @@ -64,7 +64,7 @@ struct drm_printer; > param(int, reset, 3) \ > param(unsigned int, inject_probe_failure, 0) \ > param(int, fastboot, -1) \ > - param(int, enable_dpcd_backlight, 0) \ > + param(int, enable_dpcd_backlight, -1) \ > param(char *, force_probe, CONFIG_DRM_I915_FORCE_PROBE) \ > param(unsigned long, fake_lmem_start, 0) \ > /* leave bools at the end to not create holes */ \ -- Jani Nikula, Intel Open Source Graphics Center