From patchwork Tue Jun 25 15:35:10 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Lee, Shawn C" X-Patchwork-Id: 11015893 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 7AA4514E5 for ; Tue, 25 Jun 2019 15:07:10 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6E12528671 for ; Tue, 25 Jun 2019 15:07:10 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6243328A3B; Tue, 25 Jun 2019 15:07:10 +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=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, 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 D113E28A02 for ; Tue, 25 Jun 2019 15:07:09 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 4C1316E13A; Tue, 25 Jun 2019 15:07:09 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7CD1A6E13A for ; Tue, 25 Jun 2019 15:07:08 +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 fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 25 Jun 2019 08:07:07 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.63,416,1557212400"; d="scan'208";a="164013694" Received: from shawnle1-cm6330.itwn.intel.com ([10.5.253.127]) by orsmga003.jf.intel.com with ESMTP; 25 Jun 2019 08:07:06 -0700 From: Lee Shawn C To: intel-gfx@lists.freedesktop.org Date: Tue, 25 Jun 2019 08:35:10 -0700 Message-Id: <1561476910-23655-1-git-send-email-shawn.c.lee@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1561087486-19339-1-git-send-email-shawn.c.lee@intel.com> References: <1561087486-19339-1-git-send-email-shawn.c.lee@intel.com> MIME-Version: 1.0 Subject: [Intel-gfx] [PATCH v2] drm/i915: Refine eDP aux backlight enable/disable sequence 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: Jani Nikula , Cooper Chiou Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Virus-Scanned: ClamAV using ClamSMTP Modify aux backlight enable/disable sequence just like what we did for genernal eDP panel. Setup PWM freq and brightness level before enable display backlight. v2: According to spec, it is not necessary to set PWM to 0 if backlight enable already off. Remove intel_dp_aux_set_backlight to 0. Cc: Ville Syrjälä Cc: Jani Nikula Cc: Jose Roberto de Souza Cc: Cooper Chiou Signed-off-by: Lee Shawn C --- drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) 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 6b0b73479fb8..70d9b9c9586f 100644 --- a/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c +++ b/drivers/gpu/drm/i915/display/intel_dp_aux_backlight.c @@ -216,8 +216,8 @@ static void intel_dp_aux_enable_backlight(const struct intel_crtc_state *crtc_st } } - set_aux_backlight_enable(intel_dp, true); intel_dp_aux_set_backlight(conn_state, connector->panel.backlight.level); + set_aux_backlight_enable(intel_dp, true); } static void intel_dp_aux_disable_backlight(const struct drm_connector_state *old_conn_state)