From patchwork Thu Feb 22 01:36:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Mustamin B Mustaffa X-Patchwork-Id: 10234467 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 0BFDA602A7 for ; Thu, 22 Feb 2018 01:36:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 09A8A27F60 for ; Thu, 22 Feb 2018 01:36:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id F267F286E1; Thu, 22 Feb 2018 01:36:58 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 8708A27F60 for ; Thu, 22 Feb 2018 01:36:57 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 7AFC86E6A9; Thu, 22 Feb 2018 01:36:57 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by gabe.freedesktop.org (Postfix) with ESMTPS id C0E7B6E6A9 for ; Thu, 22 Feb 2018 01:36:55 +0000 (UTC) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga003.jf.intel.com ([10.7.209.27]) by fmsmga107.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 21 Feb 2018 17:36:55 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.47,376,1515484800"; d="scan'208";a="29733403" Received: from kmsmsx152.gar.corp.intel.com ([172.21.73.87]) by orsmga003.jf.intel.com with ESMTP; 21 Feb 2018 17:36:53 -0800 Received: from pgsmsx111.gar.corp.intel.com ([169.254.2.203]) by KMSMSX152.gar.corp.intel.com ([169.254.11.139]) with mapi id 14.03.0319.002; Thu, 22 Feb 2018 09:36:52 +0800 From: "Mustaffa, Mustamin B" To: =?iso-8859-1?Q?Ville_Syrj=E4l=E4?= Thread-Topic: [Intel-gfx] [V4] drm/i915: Enable VBT based BL control for DP Thread-Index: AQHTqi8YocETw6ZE4kCSDPRN4c671qOs0wQAgAEnjkCAAFgNgIABVAlg Date: Thu, 22 Feb 2018 01:36:52 +0000 Message-ID: <605678218D4AE343AA40E888647A6D691AEAF2B5@PGSMSX111.gar.corp.intel.com> References: <1519109569-13211-1-git-send-email-mustamin.b.mustaffa@intel.com> <1519119779-144332-1-git-send-email-mustamin.b.mustaffa@intel.com> <20180220142608.GF5453@intel.com> <605678218D4AE343AA40E888647A6D691AEAEE60@PGSMSX111.gar.corp.intel.com> <20180221131907.GL5453@intel.com> In-Reply-To: <20180221131907.GL5453@intel.com> Accept-Language: en-MY, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ctpclassification: CTP_NT x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiZTQ0YmZmZGMtMDlmMS00NjdhLWExZGUtMWIzY2Y4OTYxODIwIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjIuNS4xOCIsIlRydXN0ZWRMYWJlbEhhc2giOiJPSlczbk9qcEZTVzk0NDNwYXY5amliTlZFXC9rajBsZER6V3B4cGpic1BINVwvKzJVeWFZNVRFbUVhRUtPemNwa1UifQ== dlp-product: dlpe-windows dlp-version: 11.0.0.116 dlp-reaction: no-action x-originating-ip: [172.30.20.206] MIME-Version: 1.0 Subject: Re: [Intel-gfx] [V4] drm/i915: Enable VBT based BL control for DP X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "intel-gfx@lists.freedesktop.org" Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Virus-Scanned: ClamAV using ClamSMTP Hi Ville, I already resubmit the patch https://patchwork.freedesktop.org/patch/205823/ > > Can you point out what makes you says the git diff is broken? > > Best regard > > Mustamin > > > -----Original Message----- > From: Ville Syrjälä [mailto:ville.syrjala@linux.intel.com] > Sent: Tuesday, February 20, 2018 10:26 PM > To: Mustaffa, Mustamin B > Cc: intel-gfx@lists.freedesktop.org > Subject: Re: [Intel-gfx] [V4] drm/i915: Enable VBT based BL control > for DP > > On Tue, Feb 20, 2018 at 05:42:59PM +0800, Mustamin B Mustaffa wrote: > > Currently, BXT_PP is hardcoded with value '0'. > > It practically disabled eDP backlight on MRB (BXT) platform. > > > > This patch will tell which BXT_PP registers (there are two set of > > PP_CONTROL in the spec) to be used as defined in VBT (Video Bios > > Timing > > table) and this will enabled eDP backlight controller on MRB (BXT) > > platform. > > > > v2: > > - Remove unnecessary information in commit message. > > - Assign vbt.backlight.controller to a backlight_controller variable and > > return the variable value. > > v3: > > - Rebased to latest code base. > > - updated commit title. > > V4: > > - Use sanitized panel backlight controller instead of vbt backlight > > controller > > > > Signed-off-by: Mustamin B Mustaffa > > --- > > drivers/gpu/drm/i915/intel_dp.c | 11 ++++------- > > 1 file changed, 4 insertions(+), 7 deletions(-) > > > > diff --git a/drivers/gpu/drm/i915/intel_dp.c > > b/drivers/gpu/drm/i915/intel_dp.c index 1868f73..f9b922d 100644 > > --- a/drivers/gpu/drm/i915/intel_dp.c > > +++ b/drivers/gpu/drm/i915/intel_dp.c > > @@ -655,18 +655,15 @@ static enum pipe vlv_find_free_pps(struct ^^^^^^^^^^^^^^^^^ That is not the function you're patching here. > > drm_i915_private *dev_priv) > > Your git diff is clearly broken. This makes patch review harder than it has to be. Please consider updating to a non-broken version. > > > { > > struct drm_i915_private *dev_priv = > > to_i915(intel_dp_to_dev(intel_dp)); > > > > + int backlight_controller = > > +intel_dp->attached_connector->panel.backlight.controller; > > + > > lockdep_assert_held(&dev_priv->pps_mutex); > > > > /* We should never land here with regular DP ports */ > > WARN_ON(!intel_dp_is_edp(intel_dp)); > > > > - /* > > - * TODO: BXT has 2 PPS instances. The correct port->PPS instance > > - * mapping needs to be retrieved from VBT, for now just hard-code to > > - * use instance #0 always. > > - */ > > if (!intel_dp->pps_reset) > > - return 0; > > + return backlight_controller; > > > > intel_dp->pps_reset = false; > > > > @@ -676,7 +673,7 @@ static enum pipe vlv_find_free_pps(struct drm_i915_private *dev_priv) > > */ > > intel_dp_init_panel_power_sequencer_registers(intel_dp, false); > > > > - return 0; > > + return backlight_controller; > > } > > > > typedef bool (*vlv_pipe_check)(struct drm_i915_private *dev_priv, > > -- > > 1.9.1 > > > > _______________________________________________ > > Intel-gfx mailing list > > Intel-gfx@lists.freedesktop.org > > https://lists.freedesktop.org/mailman/listinfo/intel-gfx > > -- > Ville Syrjälä > Intel OTC diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c index 1868f73f730c..b9068bd1943f 100644 --- a/drivers/gpu/drm/i915/intel_dp.c +++ b/drivers/gpu/drm/i915/intel_dp.c @@ -655,18 +655,16 @@ bxt_power_sequencer_idx(struct intel_dp *intel_dp) { struct drm_i915_private *dev_priv = to_i915(intel_dp_to_dev(intel_dp)); + int backlight_controller = + intel_dp->attached_connector->panel.backlight.controller; + Best regard Mustamin -----Original Message----- From: Ville Syrjälä [mailto:ville.syrjala@linux.intel.com] Sent: Wednesday, February 21, 2018 9:19 PM To: Mustaffa, Mustamin B Cc: intel-gfx@lists.freedesktop.org Subject: Re: [Intel-gfx] [V4] drm/i915: Enable VBT based BL control for DP On Wed, Feb 21, 2018 at 12:04:43AM +0000, Mustaffa, Mustamin B wrote: > Hi Ville,