From patchwork Mon Oct 30 22:21:56 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Dhinakaran Pandiyan X-Patchwork-Id: 10033327 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 17482600C5 for ; Mon, 30 Oct 2017 22:22:09 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0965828976 for ; Mon, 30 Oct 2017 22:22:09 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id F22C42898F; Mon, 30 Oct 2017 22:22:08 +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 533FE28976 for ; Mon, 30 Oct 2017 22:22:07 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 812696E17B; Mon, 30 Oct 2017 22:22:06 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga06.intel.com (mga06.intel.com [134.134.136.31]) by gabe.freedesktop.org (Postfix) with ESMTPS id 435086E17B; Mon, 30 Oct 2017 22:22:05 +0000 (UTC) Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga104.jf.intel.com with ESMTP; 30 Oct 2017 15:22:02 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.44,321,1505804400"; d="scan'208";a="329800062" Received: from dk-thinkpad-x260.jf.intel.com (HELO localhost.localdomain) ([10.54.75.38]) by fmsmga004.fm.intel.com with ESMTP; 30 Oct 2017 15:22:01 -0700 From: Dhinakaran Pandiyan To: dri-devel@lists.freedesktop.org Date: Mon, 30 Oct 2017 15:21:56 -0700 Message-Id: <20171030222156.23218-1-dhinakaran.pandiyan@intel.com> X-Mailer: git-send-email 2.11.0 MIME-Version: 1.0 Cc: Jani Nikula , intel-gfx@lists.freedesktop.org, Dhinakaran Pandiyan Subject: [Intel-gfx] [PATCH] drm/dp: Update SET_POWER_MASK to include the D3 Aux-On state too. X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Virus-Scanned: ClamAV using ClamSMTP Updating the mask is needed to clear all the three power state bits before setting the required power state. Also add a comment documenting that D3 Aux-On state has been available DPCD v1.2 onwards. Thanks to Ville for pointing this out. Cc: Ville Syrjälä Cc: Jani Nikula Signed-off-by: Dhinakaran Pandiyan --- include/drm/drm_dp_helper.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/drm/drm_dp_helper.h b/include/drm/drm_dp_helper.h index 9049ef133d69..aea10f85dd4c 100644 --- a/include/drm/drm_dp_helper.h +++ b/include/drm/drm_dp_helper.h @@ -617,8 +617,8 @@ #define DP_SET_POWER 0x600 # define DP_SET_POWER_D0 0x1 # define DP_SET_POWER_D3 0x2 -# define DP_SET_POWER_MASK 0x3 -# define DP_SET_POWER_D3_AUX_ON 0x5 +# define DP_SET_POWER_D3_AUX_ON 0x5 /* DPCD >= 1.2 */ +# define DP_SET_POWER_MASK 0x7 #define DP_EDP_DPCD_REV 0x700 /* eDP 1.2 */ # define DP_EDP_11 0x00