From patchwork Mon May 27 07:22:01 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674678 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 36B61C25B78 for ; Mon, 27 May 2024 07:22:52 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id CCFF510F91C; Mon, 27 May 2024 07:22:48 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="TVEvXrC6"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id CC1F78922E for ; Mon, 27 May 2024 07:22:37 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794558; x=1748330558; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=RLj46Ba31EOgofb0ldGfcd2r5JXgRYwl0oEvOXj0D5A=; b=TVEvXrC6cWdE26pDSFHhXKGdcq/7WE0nwG0Bv3afnYE9yC+4DsLnofZU 6O/b3uVw9/0Wm3HurPia8eQH7h9r1xIuMSZq0qyMsMrhlIntaN4yL0PUz Ve/QPxEZXhJ01lHtIEypM0ggul0wx0QZ3DNfXZPtYy8gGPcz4W/WGbynl dBgbKMFwYjiIon6EOFm57QhaPoOUnAMeNWZzuOLyLbsVo4SJciPmiHoQb nDNIEbM+GuQBc1HfKgGppIcHOHr73Mc57HyKIfGe8VaJEeA5Z6BHADfJ0 8CozscmVqM2us/qzOnrYNcr5SQhV81a21HEsCoA5Z1icWcVRHKPuvG3h7 g==; X-CSE-ConnectionGUID: +an8HY0RRJWLSr5SiUpZuQ== X-CSE-MsgGUID: REe6Bt9uSnym6naAtype+w== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930410" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930410" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:38 -0700 X-CSE-ConnectionGUID: Z8uRVvNQSa+bwdEqzbVKIg== X-CSE-MsgGUID: scPqXOrASjGTlLVlsogAvg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753380" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:37 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 01/20] drm/i915/psr: Store pr_dpcd in intel_dp Date: Mon, 27 May 2024 10:22:01 +0300 Message-Id: <20240527072220.3294769-2-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" We need pr_dpcd contents for early transport validity check on eDP Panel Replay and in debugfs interface to dump out panel early transport capability. Also remove unnecessarily printing out "Panel replay is not supported by panel" v2: commit message modified Signed-off-by: Jouni Högander Reviewed-by: Animesh Manna --- .../drm/i915/display/intel_display_types.h | 1 + drivers/gpu/drm/i915/display/intel_psr.c | 19 ++++++------------- 2 files changed, 7 insertions(+), 13 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_display_types.h b/drivers/gpu/drm/i915/display/intel_display_types.h index 9678c2b157f6..6fbfe8a18f45 100644 --- a/drivers/gpu/drm/i915/display/intel_display_types.h +++ b/drivers/gpu/drm/i915/display/intel_display_types.h @@ -1743,6 +1743,7 @@ struct intel_dp { bool use_max_params; u8 dpcd[DP_RECEIVER_CAP_SIZE]; u8 psr_dpcd[EDP_PSR_RECEIVER_CAP_SIZE]; + u8 pr_dpcd; u8 downstream_ports[DP_MAX_DOWNSTREAM_PORTS]; u8 edp_dpcd[EDP_DISPLAY_CTL_CAP_SIZE]; u8 lttpr_common_caps[DP_LTTPR_COMMON_CAP_SIZE]; diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index f59238d3d484..08d3c8c81585 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -559,20 +559,10 @@ static void intel_dp_get_su_granularity(struct intel_dp *intel_dp) static void _panel_replay_init_dpcd(struct intel_dp *intel_dp) { struct drm_i915_private *i915 = dp_to_i915(intel_dp); - u8 pr_dpcd = 0; - - intel_dp->psr.sink_panel_replay_support = false; - drm_dp_dpcd_readb(&intel_dp->aux, DP_PANEL_REPLAY_CAP, &pr_dpcd); - - if (!(pr_dpcd & DP_PANEL_REPLAY_SUPPORT)) { - drm_dbg_kms(&i915->drm, - "Panel replay is not supported by panel\n"); - return; - } intel_dp->psr.sink_panel_replay_support = true; - if (pr_dpcd & DP_PANEL_REPLAY_SU_SUPPORT) + if (intel_dp->pr_dpcd & DP_PANEL_REPLAY_SU_SUPPORT) intel_dp->psr.sink_panel_replay_su_support = true; drm_dbg_kms(&i915->drm, @@ -630,10 +620,13 @@ static void _psr_init_dpcd(struct intel_dp *intel_dp) void intel_psr_init_dpcd(struct intel_dp *intel_dp) { - _panel_replay_init_dpcd(intel_dp); - drm_dp_dpcd_read(&intel_dp->aux, DP_PSR_SUPPORT, intel_dp->psr_dpcd, sizeof(intel_dp->psr_dpcd)); + drm_dp_dpcd_readb(&intel_dp->aux, DP_PANEL_REPLAY_CAP, + &intel_dp->pr_dpcd); + + if (intel_dp->pr_dpcd & DP_PANEL_REPLAY_SUPPORT) + _panel_replay_init_dpcd(intel_dp); if (intel_dp->psr_dpcd[0]) _psr_init_dpcd(intel_dp); From patchwork Mon May 27 07:22:02 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674692 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id EFDAAC25B78 for ; Mon, 27 May 2024 07:23:40 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2782710F7F5; Mon, 27 May 2024 07:23:40 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="KcB94fny"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 9626810F914 for ; Mon, 27 May 2024 07:22:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794560; x=1748330560; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=fP4NKzC2aG67DdePUMpLYHiqwHRI4vt+/BJotmd6ZwQ=; b=KcB94fnyOmxE6HEW6PzWnNtVLBnxn+qLOzlTtHwLXlow8Rz13UEr6kbY ypMuBuzLZW36Y8Qng0AOCIxv95oMDyA2jjEAGtGvFTAHasUpKfWQVORsf NYQHuVZoNLxsTdQnsRqaHPL5jfOO5UuIG/WPs2aQ5jR0uXFqRDu8w9U4W BNVKuUyf3mwzIQExFbwjCUYOt9o0sl0ulunY/yOcyZuOzBC/XVXGh2dgO OoQlBMnzJhW5vFHAcH4WkzGa+s62DP0SURCCGXxiegenUbjThvGQeBTmu 8M+lrsPn8Rc+oLztGzcx8C26UJaJgc9iaZ8YEzVgfBLRnVG90f7mr9/7O g==; X-CSE-ConnectionGUID: e6sTca2zQXSA/AnFWnu/VA== X-CSE-MsgGUID: dF2oKICYRIqZvKLnKsurlA== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930419" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930419" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:39 -0700 X-CSE-ConnectionGUID: hmaeiQ2NSXKG+pRcexqzdw== X-CSE-MsgGUID: iQ6yWQ3ES6GoJsyTX6YRCQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753383" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:38 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 02/20] drm/panel replay: Add edp1.5 Panel Replay bits and register Date: Mon, 27 May 2024 10:22:02 +0300 Message-Id: <20240527072220.3294769-3-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Add PANEL_REPLAY_CONFIGURATION_2 register and some missing Panel Replay bits. Signed-off-by: Jouni Högander Reviewed-by: Animesh Manna Acked-by: Maarten Lankhorst --- include/drm/display/drm_dp.h | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/include/drm/display/drm_dp.h b/include/drm/display/drm_dp.h index 906949ca3cee..79bde372b152 100644 --- a/include/drm/display/drm_dp.h +++ b/include/drm/display/drm_dp.h @@ -544,9 +544,10 @@ /* DFP Capability Extension */ #define DP_DFP_CAPABILITY_EXTENSION_SUPPORT 0x0a3 /* 2.0 */ -#define DP_PANEL_REPLAY_CAP 0x0b0 /* DP 2.0 */ -# define DP_PANEL_REPLAY_SUPPORT (1 << 0) -# define DP_PANEL_REPLAY_SU_SUPPORT (1 << 1) +#define DP_PANEL_REPLAY_CAP 0x0b0 /* DP 2.0 */ +# define DP_PANEL_REPLAY_SUPPORT (1 << 0) +# define DP_PANEL_REPLAY_SU_SUPPORT (1 << 1) +# define DP_PANEL_REPLAY_EARLY_TRANSPORT_SUPPORT (1 << 2) /* eDP 1.5 */ #define DP_PANEL_PANEL_REPLAY_CAPABILITY 0xb1 # define DP_PANEL_PANEL_REPLAY_SU_GRANULARITY_REQUIRED (1 << 5) @@ -734,11 +735,20 @@ #define PANEL_REPLAY_CONFIG 0x1b0 /* DP 2.0 */ # define DP_PANEL_REPLAY_ENABLE (1 << 0) +# define DP_PANEL_REPLAY_VSC_SDP_CRC_EN (1 << 1) /* eDP 1.5 */ # define DP_PANEL_REPLAY_UNRECOVERABLE_ERROR_EN (1 << 3) # define DP_PANEL_REPLAY_RFB_STORAGE_ERROR_EN (1 << 4) # define DP_PANEL_REPLAY_ACTIVE_FRAME_CRC_ERROR_EN (1 << 5) # define DP_PANEL_REPLAY_SU_ENABLE (1 << 6) +#define PANEL_REPLAY_CONFIG2 0x1b1 /* eDP 1.5 */ +# define DP_PANEL_REPLAY_SINK_REFRESH_RATE_UNLOCK_GRANTED (1 << 0) +# define DP_PANEL_REPLAY_CRC_VERIFICATION (1 << 1) +# define DP_PANEL_REPLAY_SU_Y_GRANULARITY_EXTENDED_EN (1 << 2) +# define DP_PANEL_REPLAY_SU_Y_GRANULARITY_EXTENDED_VAL_SEL_SHIFT 3 +# define DP_PANEL_REPLAY_SU_Y_GRANULARITY_EXTENDED_VAL_SEL_MASK (0xf << 3) +# define DP_PANEL_REPLAY_SU_REGION_SCANLINE_CAPTURE (1 << 7) + #define DP_PAYLOAD_ALLOCATE_SET 0x1c0 #define DP_PAYLOAD_ALLOCATE_START_TIME_SLOT 0x1c1 #define DP_PAYLOAD_ALLOCATE_TIME_SLOT_COUNT 0x1c2 From patchwork Mon May 27 07:22:03 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674680 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 067CFC25B78 for ; Mon, 27 May 2024 07:22:56 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id D774F10F92C; Mon, 27 May 2024 07:22:51 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="lXodHorV"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 82D7D8922E for ; Mon, 27 May 2024 07:22:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794561; x=1748330561; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=o5eLC2++dAbsavnApGbXUnJOwgIzWtLIO5v1eW2KgLQ=; b=lXodHorVrh3MH2KxNVD6IZELgVQNfu8ztViq6k1XBqzVntcQGbK0XLM7 MENLX1Q9es/IxuP1wjwiL9UhzAW/IQRVgsSwsHBBc9U7VgKFvhvutAZ7I 4tUCvVEUmf3fh0d2qKP+g5QowQ+7Ws58++ltskLI7tL5Dn3jnFUy+Bou1 qLHTZqjCrtA2PDZcaH9D0b6bSO+PWyfEoLAfJGBhnrV9ymq+6ixsJ6d3G OznXr5qmDL1QmCXXWOp7tgqDFBOtT0TkG0gi4MgoSzvqIlHP0nCOjmf2d gHICe5WezKsa+/k3jaM3/b4SNaFfHt7HLyD7DvUUSgNZiCTabLMHQ93ak w==; X-CSE-ConnectionGUID: H0rfLAO4S/ipk+UeXWT8pA== X-CSE-MsgGUID: UCL2U9sPQmW/Mkc3XfH90Q== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930422" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930422" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:41 -0700 X-CSE-ConnectionGUID: qDKkOuZoS46RDxXAz4p49g== X-CSE-MsgGUID: K3JRb1D2Sr+A+9aJEW0w5A== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753386" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:40 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 03/20] drm/i915/psr: Move printing sink PSR support to own function Date: Mon, 27 May 2024 10:22:03 +0300 Message-Id: <20240527072220.3294769-4-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" intel_psr_status has grown and is about to grow even. Let's split it a bit and move printing sink psr support to an own function. Signed-off-by: Jouni Högander Reviewed-by: Animesh Manna --- drivers/gpu/drm/i915/display/intel_psr.c | 22 +++++++++++++++------- 1 file changed, 15 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 08d3c8c81585..943de3ca39c2 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -3590,15 +3590,10 @@ psr_source_status(struct intel_dp *intel_dp, struct seq_file *m) seq_printf(m, "Source PSR/PanelReplay status: %s [0x%08x]\n", status, val); } -static int intel_psr_status(struct seq_file *m, struct intel_dp *intel_dp) +static void intel_psr_sink_capability(struct intel_dp *intel_dp, + struct seq_file *m) { - struct drm_i915_private *dev_priv = dp_to_i915(intel_dp); - enum transcoder cpu_transcoder = intel_dp->psr.transcoder; struct intel_psr *psr = &intel_dp->psr; - intel_wakeref_t wakeref; - const char *status; - bool enabled; - u32 val; seq_printf(m, "Sink support: PSR = %s", str_yes_no(psr->sink_support)); @@ -3608,6 +3603,19 @@ static int intel_psr_status(struct seq_file *m, struct intel_dp *intel_dp) seq_printf(m, ", Panel Replay = %s", str_yes_no(psr->sink_panel_replay_support)); seq_printf(m, ", Panel Replay Selective Update = %s\n", str_yes_no(psr->sink_panel_replay_su_support)); +} + +static int intel_psr_status(struct seq_file *m, struct intel_dp *intel_dp) +{ + struct drm_i915_private *dev_priv = dp_to_i915(intel_dp); + enum transcoder cpu_transcoder = intel_dp->psr.transcoder; + struct intel_psr *psr = &intel_dp->psr; + intel_wakeref_t wakeref; + const char *status; + bool enabled; + u32 val; + + intel_psr_sink_capability(intel_dp, m); if (!(psr->sink_support || psr->sink_panel_replay_support)) return 0; From patchwork Mon May 27 07:22:04 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674679 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7A590C25B74 for ; Mon, 27 May 2024 07:22:54 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 932B010F666; Mon, 27 May 2024 07:22:50 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="SqGQE5lO"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3C03610EDC6 for ; Mon, 27 May 2024 07:22:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794563; x=1748330563; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=QcBPK68KS8gbMJeG8BSF5j1EbQzZS9gPUWXZtj3To2w=; b=SqGQE5lOL3Z/z1gy0+MipzD7alKGjKmSTzWZaOA+vtEThZ9iy6WWYgrl SAHW9hk6z4oZJPQTfS43or5I+x24rcD4vRVjzvaiA5zQZ+oolVZA80Fn1 Pkq9RvueT1eubpp3U4Dmuz5Oeo1ZYjlfGPGaOiff6EEPro+u+kRYZxwZ6 3dBkc5ivH5+pLUCMbX3/cadLGUunwdzho8y77tA5k/CRIThkmeQEQ5ra1 SOWz8X0QodJDfzA/mW/MUap46ukF4ozBv8GrI5pwx31Uchl9LhMwjFPZX 1a2nxAEOSDKSW/uQOZU9JbwYbNvB5hDHGYcqV0IBT6mHMsaOoUNbJ6ewG A==; X-CSE-ConnectionGUID: W9z1oBsGSjK8b61arGYaHg== X-CSE-MsgGUID: GqgCaYbVTnupfm6Kx0CHrQ== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930426" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930426" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:43 -0700 X-CSE-ConnectionGUID: FyNy0QO8TJ6yZSJSG6cVdg== X-CSE-MsgGUID: r5fbYG/fSbGP40ogiz8OoQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753389" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:42 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 04/20] drm/i915/psr: Move printing PSR mode to own function Date: Mon, 27 May 2024 10:22:04 +0300 Message-Id: <20240527072220.3294769-5-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" intel_psr_status has grown and is about to grow even. Let's split it a bit and move printing PSR mode to an own function. v2: s/intel_psr_psr_mode/intel_psr_print_mode/ Signed-off-by: Jouni Högander Reviewed-by: Animesh Manna --- drivers/gpu/drm/i915/display/intel_psr.c | 26 ++++++++++++++++-------- 1 file changed, 17 insertions(+), 9 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 943de3ca39c2..dfd45f6d7edd 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -3605,13 +3605,28 @@ static void intel_psr_sink_capability(struct intel_dp *intel_dp, str_yes_no(psr->sink_panel_replay_su_support)); } +static void intel_psr_print_mode(struct intel_dp *intel_dp, + struct seq_file *m) +{ + struct intel_psr *psr = &intel_dp->psr; + const char *status; + + if (psr->panel_replay_enabled) + status = psr->sel_update_enabled ? "Panel Replay Selective Update Enabled" : + "Panel Replay Enabled"; + else if (psr->enabled) + status = psr->sel_update_enabled ? "PSR2" : "PSR1"; + else + status = "disabled"; + seq_printf(m, "PSR mode: %s\n", status); +} + static int intel_psr_status(struct seq_file *m, struct intel_dp *intel_dp) { struct drm_i915_private *dev_priv = dp_to_i915(intel_dp); enum transcoder cpu_transcoder = intel_dp->psr.transcoder; struct intel_psr *psr = &intel_dp->psr; intel_wakeref_t wakeref; - const char *status; bool enabled; u32 val; @@ -3623,14 +3638,7 @@ static int intel_psr_status(struct seq_file *m, struct intel_dp *intel_dp) wakeref = intel_runtime_pm_get(&dev_priv->runtime_pm); mutex_lock(&psr->lock); - if (psr->panel_replay_enabled) - status = psr->sel_update_enabled ? "Panel Replay Selective Update Enabled" : - "Panel Replay Enabled"; - else if (psr->enabled) - status = psr->sel_update_enabled ? "PSR2" : "PSR1"; - else - status = "disabled"; - seq_printf(m, "PSR mode: %s\n", status); + intel_psr_print_mode(intel_dp, m); if (!psr->enabled) { seq_printf(m, "PSR sink not reliable: %s\n", From patchwork Mon May 27 07:22:05 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674681 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 79EA6C25B74 for ; Mon, 27 May 2024 07:22:57 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E9BE610F8EA; Mon, 27 May 2024 07:22:54 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="Mofberu7"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 9CD3410E201 for ; Mon, 27 May 2024 07:22:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794566; x=1748330566; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=9Dg/EILPwsWq4Rf99L0/rkNijPK+e0Qjdvjyvs9NCKI=; b=Mofberu7KYduFQiemHLrc35y0UCem2n/kZx8PXn0tlupKVHpaI2DJKZb S/+rG+9hk8xNKZxXtFdLrk5wsthVdHj89L33U9s/9WEYP+qHmAEnIi65M 5HECDeVVBsdsK95Be+oZJcOcMtemikonVnx9oQe/P8Uy3NaqgFKg706Cl 7LHGioP8nCje9P3UR9fQoVmsGQfg2q1yGFOqWkMMZqzUy5yQSnOwo4rZ0 mO3Tj6sLby3dFX0HXXg6EqCMB8lEveeD28Ot1H8pDuCvbeSj4sNuflw+y 6CRVHCeNMX0j/jeR3X/3v2lRF9q8FIJO1HlqH9m7vbo/dne22J4o+HgUb w==; X-CSE-ConnectionGUID: cOLFXBwtQvGRrAEUEKewQA== X-CSE-MsgGUID: 0F1GyEk8TiC+7+pz9Eqnlw== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930428" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930428" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:45 -0700 X-CSE-ConnectionGUID: U4YcBL9ZQN2Fgm6BDQl1Zw== X-CSE-MsgGUID: +232Pg9QT4qDz3uFDx0vhw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753392" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:44 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 05/20] drm/i915/psr: modify psr status debugfs to support eDP Panel Replay Date: Mon, 27 May 2024 10:22:05 +0300 Message-Id: <20240527072220.3294769-6-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Some PSR2_CTL bits are applicable for eDP panel replay as well. Dump this register for eDP Panel Replay as well. Bspec: 68920 Signed-off-by: Jouni Högander Reviewed-by: Animesh Manna --- drivers/gpu/drm/i915/display/intel_psr.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index dfd45f6d7edd..19f8ac12f995 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -3628,7 +3628,7 @@ static int intel_psr_status(struct seq_file *m, struct intel_dp *intel_dp) struct intel_psr *psr = &intel_dp->psr; intel_wakeref_t wakeref; bool enabled; - u32 val; + u32 val, psr2_ctl; intel_psr_sink_capability(intel_dp, m); @@ -3649,6 +3649,12 @@ static int intel_psr_status(struct seq_file *m, struct intel_dp *intel_dp) if (psr->panel_replay_enabled) { val = intel_de_read(dev_priv, TRANS_DP2_CTL(cpu_transcoder)); + + if (intel_dp_is_edp(intel_dp)) + psr2_ctl = intel_de_read(dev_priv, + EDP_PSR2_CTL(dev_priv, + cpu_transcoder)); + enabled = val & TRANS_DP2_PANEL_REPLAY_ENABLE; } else if (psr->sel_update_enabled) { val = intel_de_read(dev_priv, @@ -3660,6 +3666,9 @@ static int intel_psr_status(struct seq_file *m, struct intel_dp *intel_dp) } seq_printf(m, "Source PSR/PanelReplay ctl: %s [0x%08x]\n", str_enabled_disabled(enabled), val); + if (psr->panel_replay_enabled && intel_dp_is_edp(intel_dp)) + seq_printf(m, "PSR2_CTL: 0x%08x\n", + psr2_ctl); psr_source_status(intel_dp, m); seq_printf(m, "Busy frontbuffer bits: 0x%08x\n", psr->busy_frontbuffer_bits); From patchwork Mon May 27 07:22:06 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674686 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 60A03C25B78 for ; Mon, 27 May 2024 07:23:21 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3366A10F2F7; Mon, 27 May 2024 07:23:20 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="g2ZyWotW"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id B531B10EE5B for ; Mon, 27 May 2024 07:22:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794567; x=1748330567; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=J3AocDUqkpM5zVkgqQSDZnenYV0aq0zjp3ICYAWNsoE=; b=g2ZyWotWFiAsQmK94J83kDYGH4r3bUXtQOB7bY7DTcbsfKJ3QQneDoEh cqoLlF/6jKKrPNbRPYECSIi7I6r+rmD/lWtjCaKwPo+9rftUUXoxFSdI9 9pzdQMgS5+FZz/vUHymREPbBsi5lN582j2zbNNm53J7b8q/REdu79+E6B IZrIt663ki6hrXRm3FhsNRCC08+Qqd7E7PBlwhuTPDRFDpKLi2kgOuYH4 Mf5J28x8nuiLpjE9NGEo/tXURbEfaKK5WXf7nYK5MnZZncKPRM9HXR+5C r/379Twk11/60ObL2lmpHvFc1/P+v8rxryalL02noNuC2VG6dqLCJP9IG A==; X-CSE-ConnectionGUID: 56JcRBTcT5KhCMusHa4T/Q== X-CSE-MsgGUID: Vj5yTdxsQ9ODgOVOYCpJYQ== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930430" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930430" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:46 -0700 X-CSE-ConnectionGUID: +8PLsUwJT1yU5OSU6Swr8Q== X-CSE-MsgGUID: xkR1lmjYTZu1x4xG6m4ShQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753395" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:46 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 06/20] drm/i915/psr: Add Panel Replay support to intel_psr2_config_et_valid Date: Mon, 27 May 2024 10:22:06 +0300 Message-Id: <20240527072220.3294769-7-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Early Transport is possible and in our HW mandatory on eDP Panel Replay. Add parameter to intel_psr2_config_et_valid to differentiate validity check for Panel Replay. Signed-off-by: Jouni Högander Reviewed-by: Animesh Manna --- drivers/gpu/drm/i915/display/intel_psr.c | 21 ++++++++++++--------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 19f8ac12f995..a01c2173a2e5 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -673,16 +673,17 @@ static void hsw_psr_setup_aux(struct intel_dp *intel_dp) aux_ctl); } -static bool psr2_su_region_et_valid(struct intel_dp *intel_dp) +static bool psr2_su_region_et_valid(struct intel_dp *intel_dp, bool panel_replay) { struct drm_i915_private *i915 = dp_to_i915(intel_dp); - if (DISPLAY_VER(i915) >= 20 && - intel_dp->psr_dpcd[0] == DP_PSR2_WITH_Y_COORD_ET_SUPPORTED && - !(intel_dp->psr.debug & I915_PSR_DEBUG_SU_REGION_ET_DISABLE)) - return true; + if (DISPLAY_VER(i915) < 20 || !intel_dp_is_edp(intel_dp) || + intel_dp->psr.debug & I915_PSR_DEBUG_SU_REGION_ET_DISABLE) + return false; - return false; + return panel_replay ? + intel_dp->pr_dpcd & DP_PANEL_REPLAY_EARLY_TRANSPORT_SUPPORT : + intel_dp->psr_dpcd[0] != DP_PSR2_WITH_Y_COORD_ET_SUPPORTED; } static unsigned int intel_psr_get_enable_sink_offset(struct intel_dp *intel_dp) @@ -709,7 +710,8 @@ void intel_psr_enable_sink(struct intel_dp *intel_dp, DP_ALPM_ENABLE | DP_ALPM_LOCK_ERROR_IRQ_HPD_ENABLE); - if (psr2_su_region_et_valid(intel_dp)) + if (psr2_su_region_et_valid(intel_dp, + intel_dp->psr.panel_replay_enabled)) dpcd_val |= DP_PSR_ENABLE_SU_REGION_ET; } @@ -978,7 +980,8 @@ static void hsw_activate_psr2(struct intel_dp *intel_dp) PSR2_MAN_TRK_CTL(dev_priv, cpu_transcoder), 0); } - if (psr2_su_region_et_valid(intel_dp)) + if (psr2_su_region_et_valid(intel_dp, + intel_dp->psr.panel_replay_enabled)) val |= LNL_EDP_PSR2_SU_REGION_ET_ENABLE; /* @@ -1587,7 +1590,7 @@ static bool intel_psr2_config_valid(struct intel_dp *intel_dp, tgl_dc3co_exitline_compute_config(intel_dp, crtc_state); - if (psr2_su_region_et_valid(intel_dp)) + if (psr2_su_region_et_valid(intel_dp, false)) crtc_state->enable_psr2_su_region_et = true; return true; From patchwork Mon May 27 07:22:07 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674687 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 08E69C27C42 for ; Mon, 27 May 2024 07:23:22 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 23ABF10EE5B; Mon, 27 May 2024 07:23:21 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="Xy1HzRg9"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 93FBD10F917 for ; Mon, 27 May 2024 07:22:48 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794569; x=1748330569; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=D2mRHtTK1OzJr+0uK0m9sGwt34QCCMy4VtyOXvXHaE4=; b=Xy1HzRg9de2JVSPa70p5mOZeXqrWnNSrt3paUOUrwcm5TlAZ8J6j9y2r 0kMjAOIm46gzQ5eSZzX9q2JZJ12NTe1MmVXUv0b25Cuze9oYmsPgmYcyE dfEWWs78clVAAb4cmrACwbrMUgOHH1pp+clbQZ6SL+rtTsEoGYbInc9Op 1YT8vrRZfMecnMdQUqp5XDyEneopBM2O6diXiSd8rgYbN4WOiE/UlqAq/ MazXDngUTH0m5OAVkVY7YjJOhf92McS5sYI4T1KkWVw1fXJdMppadLMIH +xk7EkZjzzgdJCjmEicnafVcKSEJ5+TEVN6byWpGuiYyTs4DG38Jfvcpd g==; X-CSE-ConnectionGUID: 6/xxQUbUS8qqxp71AbGdFg== X-CSE-MsgGUID: n9Ugr1P1SxSNUHCH/VBPmA== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930434" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930434" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:48 -0700 X-CSE-ConnectionGUID: fvQDgoeTRG210WEVqb4wtw== X-CSE-MsgGUID: 2VUMvApJSGG9PR7B8en0Gw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753398" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:47 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 07/20] drm/i915/psr: Add Early Transport into psr debugfs interface Date: Mon, 27 May 2024 10:22:07 +0300 Message-Id: <20240527072220.3294769-8-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" We want to have sink Early Transport capability and usage in our psr debugfs status interface. v3: remove extra space from "PSR mode: disabled" v2: printout "Selective Update enabled (Early Transport)" instead of "Selective Update Early Transport enabled" Signed-off-by: Jouni Högander Reviewed-by: Animesh Manna --- drivers/gpu/drm/i915/display/intel_psr.c | 36 ++++++++++++++++++------ 1 file changed, 28 insertions(+), 8 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index a01c2173a2e5..fa12267f851f 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -3603,25 +3603,45 @@ static void intel_psr_sink_capability(struct intel_dp *intel_dp, if (psr->sink_support) seq_printf(m, " [0x%02x]", intel_dp->psr_dpcd[0]); + if (intel_dp->psr_dpcd[0] == DP_PSR2_WITH_Y_COORD_ET_SUPPORTED) + seq_printf(m, " (Early Transport)"); seq_printf(m, ", Panel Replay = %s", str_yes_no(psr->sink_panel_replay_support)); - seq_printf(m, ", Panel Replay Selective Update = %s\n", + seq_printf(m, ", Panel Replay Selective Update = %s", str_yes_no(psr->sink_panel_replay_su_support)); + if (intel_dp->pr_dpcd & DP_PANEL_REPLAY_EARLY_TRANSPORT_SUPPORT) + seq_printf(m, " (Early Transport)"); + seq_printf(m, "\n"); } static void intel_psr_print_mode(struct intel_dp *intel_dp, struct seq_file *m) { struct intel_psr *psr = &intel_dp->psr; - const char *status; + const char *status, *mode, *region_et; - if (psr->panel_replay_enabled) - status = psr->sel_update_enabled ? "Panel Replay Selective Update Enabled" : - "Panel Replay Enabled"; - else if (psr->enabled) - status = psr->sel_update_enabled ? "PSR2" : "PSR1"; + if (psr->enabled) + status = " enabled"; else status = "disabled"; - seq_printf(m, "PSR mode: %s\n", status); + + if (psr->panel_replay_enabled && psr->sel_update_enabled) + mode = "Panel Replay Selective Update"; + else if (psr->panel_replay_enabled) + mode = "Panel Replay"; + else if (psr->sel_update_enabled) + mode = "PSR2"; + else if (psr->enabled) + mode = "PSR1"; + else + mode = ""; + + if (psr->sel_update_enabled && + (psr2_su_region_et_valid(intel_dp, psr->panel_replay_enabled))) + region_et = " (Early Transport)"; + else + region_et = ""; + + seq_printf(m, "PSR mode: %s%s%s\n", mode, status, region_et); } static int intel_psr_status(struct seq_file *m, struct intel_dp *intel_dp) From patchwork Mon May 27 07:22:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674697 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CDC0EC25B78 for ; Mon, 27 May 2024 07:24:09 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 4F8CD10F3E7; Mon, 27 May 2024 07:24:09 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="iJfkyh17"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4192B10F917 for ; Mon, 27 May 2024 07:22:50 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794570; x=1748330570; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=+szKxTSOgEIDRM/429ev80DKLMC3HChQWpJUPkuTqXg=; b=iJfkyh17EMUsNYVhoHgBuNUfmZi55Gle3KGfARamAZyFkFxHzYsgKiTa JCzcu6/V9By5LhD146s6EH9AAkEilILseLulNDekn00bOQ2cyS5yXuAo0 dkLsSM+1t5gj1cCfTUPcS1BPenHXoIvi6Rs9BHYM6hSlsn8Vf3GjBPkZg TXHm4ubsVpf/N5ynS61gh7NqtgWv9NVKtTLwBWK82RnGyVy6Fe5dmf/mp Z25PgCmEodu4oBrJSSWNKXrBjUUNCX0yhMlPNYkyQIJXM3VuveEqeoVmK TNcOTV/n6RSCZyrumnvFJOoglxPPRtr9nGCBNE/FpNGdmVSjVlYbiyRah w==; X-CSE-ConnectionGUID: 8w6M+alBTSC1N3ZGjD/DCA== X-CSE-MsgGUID: 5UY8PWdPTuyNURQitiuCIA== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930443" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930443" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:50 -0700 X-CSE-ConnectionGUID: F0x1VJKDRVa9M2pf8zbqMw== X-CSE-MsgGUID: AhwEhNR8RdKoy+Xva8Lkeg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753402" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:49 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 08/20] drm/display: Add missing aux less alpm wake related bits Date: Mon, 27 May 2024 10:22:08 +0300 Message-Id: <20240527072220.3294769-9-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" eDP1.5 adds some more bits into DP_RECEIVER_ALPM_CAP and DP_RECEIVER_ALPM_CONFIG registers. Add definitions for these. Signed-off-by: Jouni Högander --- include/drm/display/drm_dp.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/drm/display/drm_dp.h b/include/drm/display/drm_dp.h index 79bde372b152..f3ce8c483659 100644 --- a/include/drm/display/drm_dp.h +++ b/include/drm/display/drm_dp.h @@ -232,6 +232,8 @@ #define DP_RECEIVER_ALPM_CAP 0x02e /* eDP 1.4 */ # define DP_ALPM_CAP (1 << 0) +# define DP_ALPM_PM_STATE_2A_SUPPORT (1 << 1) /* eDP 1.5 */ +# define DP_ALPM_AUX_LESS_CAP (1 << 2) /* eDP 1.5 */ #define DP_SINK_DEVICE_AUX_FRAME_SYNC_CAP 0x02f /* eDP 1.4 */ # define DP_AUX_FRAME_SYNC_CAP (1 << 0) @@ -685,6 +687,7 @@ #define DP_RECEIVER_ALPM_CONFIG 0x116 /* eDP 1.4 */ # define DP_ALPM_ENABLE (1 << 0) # define DP_ALPM_LOCK_ERROR_IRQ_HPD_ENABLE (1 << 1) +# define DP_ALPM_MODE_AUX_LESS (1 << 2) /* eDP 1.5 */ #define DP_SINK_DEVICE_AUX_FRAME_SYNC_CONF 0x117 /* eDP 1.4 */ # define DP_AUX_FRAME_SYNC_ENABLE (1 << 0) From patchwork Mon May 27 07:22:09 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674682 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 5B6AAC25B78 for ; Mon, 27 May 2024 07:22:58 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id D041810EE63; Mon, 27 May 2024 07:22:56 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="OZnsGehY"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3F9038922E for ; Mon, 27 May 2024 07:22:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794572; x=1748330572; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=uqT1klJq9JChwcgi+tEF2zMYFezz9s1x7UsoBJ1XAwk=; b=OZnsGehYoak7D00Eak0L8BVQ5R9MQTCRjKSQTjAyq7uuyqUjQn/fSvmT jkSLzYZYwOHXrG26bmAThoStwl8nM9WXm/Ff37PiP1Y+XqNFa8iBuRYL+ BsRXKhHhK4yNjcW/fU2G/Fdh6KHP5vGMPqraMvANdAGTNUz6QpUEtifGy XuA3BQTrdUrWL6w8e+X7lkaoy6mhvxXCiCkZremtZb0gYYLmBDyMc4IeQ KZk5hOZ0kOMlGL1BgXHREvuYU7L0N7NP91uKCXLamro6pduJlBDaTAnM/ VUoyOPz48DVeKY+rcx4snP0s8lL1OZMia4+SdR5Ik/pCwbZ3QdXnba5HX Q==; X-CSE-ConnectionGUID: TQ8hWk7GRha1Rc/KVctZKA== X-CSE-MsgGUID: lOEVXCohT4WB+anAYQ0Kog== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930447" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930447" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:52 -0700 X-CSE-ConnectionGUID: wr/6K5zjQgGTm8pb53oMHA== X-CSE-MsgGUID: EegKbbOMS4mkLpiE8qyWww== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753405" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:51 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 09/20] drm/i915/psr: Check panel ALPM capability for eDP Panel Replay Date: Mon, 27 May 2024 10:22:09 +0300 Message-Id: <20240527072220.3294769-10-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Our HW doesn't support Panel Replay without AUX_LESS ALPM on eDP. Check panel support for this and prevent eDP panel replay if it doesn't exits. Bspec: 68920 Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 32 ++++++++++++------------ 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index fa12267f851f..7df9182657ac 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -445,16 +445,6 @@ void intel_psr_irq_handler(struct intel_dp *intel_dp, u32 psr_iir) } } -static bool intel_dp_get_alpm_status(struct intel_dp *intel_dp) -{ - u8 alpm_caps = 0; - - if (drm_dp_dpcd_readb(&intel_dp->aux, DP_RECEIVER_ALPM_CAP, - &alpm_caps) != 1) - return false; - return alpm_caps & DP_ALPM_CAP; -} - static u8 intel_dp_get_sink_sync_latency(struct intel_dp *intel_dp) { struct drm_i915_private *i915 = dp_to_i915(intel_dp); @@ -556,10 +546,18 @@ static void intel_dp_get_su_granularity(struct intel_dp *intel_dp) intel_dp->psr.su_y_granularity = y; } -static void _panel_replay_init_dpcd(struct intel_dp *intel_dp) +static void _panel_replay_init_dpcd(struct intel_dp *intel_dp, u8 alpm_caps) { struct drm_i915_private *i915 = dp_to_i915(intel_dp); + if (intel_dp_is_edp(intel_dp) && + (!(alpm_caps & DP_ALPM_CAP) || + !(alpm_caps & DP_ALPM_AUX_LESS_CAP))) { + drm_dbg_kms(&i915->drm, + "Panel doesn't support AUX-less ALPM, eDP Panel Replay not possible\n"); + return; + } + intel_dp->psr.sink_panel_replay_support = true; if (intel_dp->pr_dpcd & DP_PANEL_REPLAY_SU_SUPPORT) @@ -571,7 +569,7 @@ static void _panel_replay_init_dpcd(struct intel_dp *intel_dp) "selective_update " : ""); } -static void _psr_init_dpcd(struct intel_dp *intel_dp) +static void _psr_init_dpcd(struct intel_dp *intel_dp, u8 alpm_caps) { struct drm_i915_private *i915 = to_i915(dp_to_dig_port(intel_dp)->base.base.dev); @@ -599,7 +597,6 @@ static void _psr_init_dpcd(struct intel_dp *intel_dp) intel_dp->psr_dpcd[0] >= DP_PSR2_WITH_Y_COORD_IS_SUPPORTED) { bool y_req = intel_dp->psr_dpcd[1] & DP_PSR2_SU_Y_COORDINATE_REQUIRED; - bool alpm = intel_dp_get_alpm_status(intel_dp); /* * All panels that supports PSR version 03h (PSR2 + @@ -612,7 +609,7 @@ static void _psr_init_dpcd(struct intel_dp *intel_dp) * Y-coordinate requirement panels we would need to enable * GTC first. */ - intel_dp->psr.sink_psr2_support = y_req && alpm; + intel_dp->psr.sink_psr2_support = y_req && alpm_caps & DP_ALPM_CAP; drm_dbg_kms(&i915->drm, "PSR2 %ssupported\n", intel_dp->psr.sink_psr2_support ? "" : "not "); } @@ -620,16 +617,19 @@ static void _psr_init_dpcd(struct intel_dp *intel_dp) void intel_psr_init_dpcd(struct intel_dp *intel_dp) { + u8 alpm_caps = 0; + drm_dp_dpcd_read(&intel_dp->aux, DP_PSR_SUPPORT, intel_dp->psr_dpcd, sizeof(intel_dp->psr_dpcd)); drm_dp_dpcd_readb(&intel_dp->aux, DP_PANEL_REPLAY_CAP, &intel_dp->pr_dpcd); + drm_dp_dpcd_readb(&intel_dp->aux, DP_RECEIVER_ALPM_CAP, &alpm_caps); if (intel_dp->pr_dpcd & DP_PANEL_REPLAY_SUPPORT) - _panel_replay_init_dpcd(intel_dp); + _panel_replay_init_dpcd(intel_dp, alpm_caps); if (intel_dp->psr_dpcd[0]) - _psr_init_dpcd(intel_dp); + _psr_init_dpcd(intel_dp, alpm_caps); if (intel_dp->psr.sink_psr2_support || intel_dp->psr.sink_panel_replay_su_support) From patchwork Mon May 27 07:22:10 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674691 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id B5146C25B74 for ; Mon, 27 May 2024 07:23:38 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id F3B6510F91E; Mon, 27 May 2024 07:23:37 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="ZwhUwRWy"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 09EFE10E6ED for ; Mon, 27 May 2024 07:22:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794574; x=1748330574; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=V4wB/0Q1b+gsTxM234QyR2n0b4qnY5qDmUHdYaLlIy0=; b=ZwhUwRWyP/kemvR8eFZ+s0iW5Z6SbwXuGYe+Gggr4jPaAqUZ37JYusF2 X8j3M0wyl2K6HModHbFCbrQE65TfRcrImmkN6EQ70nkQfTVfQbKIl4yYD 2HBB8/u+ViWKIHD6+z2sztjz2bJnuLJfX5I7q5KEPxcrYMyM5M81QEklh 0lLOI4pldQT9K5SHh/q2we2qjEwp2unk/RWqKPJ/HpcZRZoIj5AXmULkH z07BGPiFwVl6Qdj5q4GUUiM0D/oWZJCjH6hH/O+lhFSbEAl2q3i5lXgPp fl/s1hmSL8HCLRH/jc/zeiy/QVtLLcxie12gDqNMwGTcd5L0QjPEiJrTc g==; X-CSE-ConnectionGUID: qwHbWh4TQ4KlWugKtiScLQ== X-CSE-MsgGUID: TFLyfTjORby2dszVMJslkQ== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930451" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930451" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:53 -0700 X-CSE-ConnectionGUID: ndRSc+ivQXeR+koUE2mgkQ== X-CSE-MsgGUID: DAg4y5F7QYmmYmF2bwp+JQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753411" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:53 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 10/20] drm/i915/psr: Inform Panel Replay source support on eDP as well Date: Mon, 27 May 2024 10:22:10 +0300 Message-Id: <20240527072220.3294769-11-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Display version >= 20 support eDP 1.5. Inform Panel Replay source support on eDP for display version >= 20. Bspec: 68920 Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 7df9182657ac..fcf73a5cbfc2 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -3321,9 +3321,11 @@ void intel_psr_init(struct intel_dp *intel_dp) return; } - if (HAS_DP20(dev_priv) && !intel_dp_is_edp(intel_dp)) + if ((HAS_DP20(dev_priv) && !intel_dp_is_edp(intel_dp)) || + DISPLAY_VER(dev_priv) >= 20) intel_dp->psr.source_panel_replay_support = true; - else + + if (HAS_PSR(dev_priv) && intel_dp_is_edp(intel_dp)) intel_dp->psr.source_support = true; /* Disable early transport for now */ From patchwork Mon May 27 07:22:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674685 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 81180C25B7C for ; Mon, 27 May 2024 07:23:20 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A16B410E6ED; Mon, 27 May 2024 07:23:19 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="aFjR/qKV"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 9F6A810F8FE for ; Mon, 27 May 2024 07:22:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794576; x=1748330576; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=asr1vpiPDL5LgqFnQLqi5GmvCzkVtPqMuTlDBR8vXRs=; b=aFjR/qKVGID1cz52CQE1GOXqRUyk/MbBmDoPew0CSqcXYuEq0ELVl4su 65PZHGEqo6kHzeNMNgFrebwHIxIsEgW4VlP6YNTjOJs81N4Bf2nqlZzkw O9DUD8amHKgOus+avz6riDhfqDL33p47SQWKO1zZ/Do24yx8pdawk+AuZ u935PLWUrwDE3RcUDvt3TCv720JlXvPrKL9YatM9qtY7IlBGjiMsDoQLh 7zdvTvJv9IkRQZ/PuJJ6f4KrbsRPTODYqf2aJP2NlYdsZQUfdIPlNWR6d uoZCKptyVurRcjeP4VQVdplyvRDOJiJBZmH4ME9mxUmM5hSMngalwLPmj Q==; X-CSE-ConnectionGUID: VSsojqU1QFWSg+DICr8WEw== X-CSE-MsgGUID: JbXk3r0qQ+qQIYEaFytJwg== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930457" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930457" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:55 -0700 X-CSE-ConnectionGUID: wUOXImTcSOSuwnmNBFuQxw== X-CSE-MsgGUID: DRUsOnIETP2rzNDPPftpmg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753431" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:54 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 11/20] drm/i915/psr: enable sink for eDP1.5 Panel Replay Date: Mon, 27 May 2024 10:22:11 +0300 Message-Id: <20240527072220.3294769-12-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" eDP1.5 allows Panel Replay on eDP as well. Take this into account when enabling sink PSR/Panel Replay. Write also PANEL_REPLAY_CONFIG2 register accordingly. Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 63 +++++++++++++++++------- 1 file changed, 46 insertions(+), 17 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index fcf73a5cbfc2..16e06312a8be 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -692,6 +692,23 @@ static unsigned int intel_psr_get_enable_sink_offset(struct intel_dp *intel_dp) PANEL_REPLAY_CONFIG : DP_PSR_EN_CFG; } +static void intel_psr_enable_sink_alpm(struct intel_dp *intel_dp, + const struct intel_crtc_state *crtc_state) +{ + u32 val; + + if (!crtc_state->has_sel_update && (!crtc_state->has_panel_replay || + !intel_dp_is_edp(intel_dp))) + return; + + val = DP_ALPM_ENABLE | DP_ALPM_LOCK_ERROR_IRQ_HPD_ENABLE; + + if (crtc_state->has_panel_replay) + val |= DP_ALPM_MODE_AUX_LESS; + + drm_dp_dpcd_writeb(&intel_dp->aux, DP_RECEIVER_ALPM_CONFIG, val); +} + /* * Note: Most of the bits are same in PANEL_REPLAY_CONFIG and DP_PSR_EN_CFG. We * are relying on PSR definitions on these "common" bits. @@ -700,43 +717,55 @@ void intel_psr_enable_sink(struct intel_dp *intel_dp, const struct intel_crtc_state *crtc_state) { struct drm_i915_private *dev_priv = dp_to_i915(intel_dp); - u8 dpcd_val = DP_PSR_ENABLE; + u8 enable_val = DP_PSR_ENABLE; + u8 panel_replay_config2 = 0; + + intel_psr_enable_sink_alpm(intel_dp, crtc_state); if (crtc_state->has_sel_update) { - /* Enable ALPM at sink for psr2 */ - if (!crtc_state->has_panel_replay) { - drm_dp_dpcd_writeb(&intel_dp->aux, - DP_RECEIVER_ALPM_CONFIG, - DP_ALPM_ENABLE | - DP_ALPM_LOCK_ERROR_IRQ_HPD_ENABLE); + /* PSR2 and Panel Replay SU on eDP */ + if (intel_dp_is_edp(intel_dp)) { + if (crtc_state->req_psr2_sdp_prior_scanline) { + if (crtc_state->has_panel_replay) + panel_replay_config2 |= + DP_PANEL_REPLAY_SU_REGION_SCANLINE_CAPTURE; + else + enable_val |= DP_PSR_SU_REGION_SCANLINE_CAPTURE; + } if (psr2_su_region_et_valid(intel_dp, intel_dp->psr.panel_replay_enabled)) - dpcd_val |= DP_PSR_ENABLE_SU_REGION_ET; + enable_val |= DP_PSR_ENABLE_SU_REGION_ET; } - dpcd_val |= DP_PSR_ENABLE_PSR2 | DP_PSR_IRQ_HPD_WITH_CRC_ERRORS; + enable_val |= DP_PSR_ENABLE_PSR2 | DP_PSR_IRQ_HPD_WITH_CRC_ERRORS; } else { + /* PSR2 and Panel Replay Full Frame Update */ if (intel_dp->psr.link_standby) - dpcd_val |= DP_PSR_MAIN_LINK_ACTIVE; + enable_val |= DP_PSR_MAIN_LINK_ACTIVE; if (!crtc_state->has_panel_replay && DISPLAY_VER(dev_priv) >= 8) - dpcd_val |= DP_PSR_CRC_VERIFICATION; + enable_val |= DP_PSR_CRC_VERIFICATION; } - if (crtc_state->has_panel_replay) - dpcd_val |= DP_PANEL_REPLAY_UNRECOVERABLE_ERROR_EN | + if (crtc_state->has_panel_replay) { + enable_val |= DP_PANEL_REPLAY_UNRECOVERABLE_ERROR_EN | DP_PANEL_REPLAY_RFB_STORAGE_ERROR_EN; - if (crtc_state->req_psr2_sdp_prior_scanline) - dpcd_val |= DP_PSR_SU_REGION_SCANLINE_CAPTURE; + if (intel_dp_is_edp(intel_dp)) + enable_val |= DP_PANEL_REPLAY_VSC_SDP_CRC_EN; + } if (intel_dp->psr.entry_setup_frames > 0) - dpcd_val |= DP_PSR_FRAME_CAPTURE; + enable_val |= DP_PSR_FRAME_CAPTURE; drm_dp_dpcd_writeb(&intel_dp->aux, intel_psr_get_enable_sink_offset(intel_dp), - dpcd_val); + enable_val); + + if (crtc_state->has_panel_replay && intel_dp_is_edp(intel_dp)) + drm_dp_dpcd_writeb(&intel_dp->aux, PANEL_REPLAY_CONFIG2, + panel_replay_config2); if (intel_dp_is_edp(intel_dp)) drm_dp_dpcd_writeb(&intel_dp->aux, DP_SET_POWER, DP_SET_POWER_D0); From patchwork Mon May 27 07:22:12 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674684 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A26C2C25B74 for ; Mon, 27 May 2024 07:23:19 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0631110EDC6; Mon, 27 May 2024 07:23:19 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="Pi50Qwx+"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 8FBE810E6ED for ; Mon, 27 May 2024 07:22:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794579; x=1748330579; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=mTNx8tiab/AOUZzDhwIRrm/3Y4KeoY75g6fyDVkFq2c=; b=Pi50Qwx+outq5ijtCwTxqOrO6dCLCk4egnj/br0IZix0EEn5IF72BB7m bd7iFOAwv3po/csO3A06KkgnlJYsvURhSmVan36YGOtEqEV1mvvpl4Q++ 6i77KNnpIC1C54+Bk6V5aAfvZv0jgz+kHNHgm7NaoZNhj7cg5dYZ4XSSc +j0nTzScno/HMIcv+MIB3D+zHidBqUzWuEGdiugcIJHQKZmvv1r7/hMGK xXfpIqbyVKpsMdR8Nklr4zWjOJ8vza7CcuByFCjtHLiAw7S6Ey2xdjyhT yJb41bhq2aoKMLLQ7z0x0Ws/kAt0+e7jdeUueAKNuu4rFIuDvFDJpJ8l0 Q==; X-CSE-ConnectionGUID: xi/8cPqiTTaCGbo6a6icIQ== X-CSE-MsgGUID: MXYc5FakRaKY+Yb4Zkcf6A== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930461" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930461" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:58 -0700 X-CSE-ConnectionGUID: jecyYiRRR4i8BLiFHrzIBg== X-CSE-MsgGUID: ZLML2h4TSoyItoV1oyt7tg== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753441" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:56 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 12/20] drm/i915/psr: Check panel Early Transport capability for eDP PR Date: Mon, 27 May 2024 10:22:12 +0300 Message-Id: <20240527072220.3294769-13-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Our HW doesn't support panel replay without Early Transport on eDP. Bspec: 68920 Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 16e06312a8be..a96e03cd68ea 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -550,12 +550,19 @@ static void _panel_replay_init_dpcd(struct intel_dp *intel_dp, u8 alpm_caps) { struct drm_i915_private *i915 = dp_to_i915(intel_dp); - if (intel_dp_is_edp(intel_dp) && - (!(alpm_caps & DP_ALPM_CAP) || - !(alpm_caps & DP_ALPM_AUX_LESS_CAP))) { - drm_dbg_kms(&i915->drm, - "Panel doesn't support AUX-less ALPM, eDP Panel Replay not possible\n"); - return; + if (intel_dp_is_edp(intel_dp)) { + if (!(alpm_caps & DP_ALPM_CAP) || + !(alpm_caps & DP_ALPM_AUX_LESS_CAP)) { + drm_dbg_kms(&i915->drm, + "Panel doesn't support AUX-less ALPM, eDP Panel Replay not possible\n"); + return; + } + + if (!(intel_dp->pr_dpcd & DP_PANEL_REPLAY_EARLY_TRANSPORT_SUPPORT)) { + drm_dbg_kms(&i915->drm, + "Panel doesn't support early transport, eDP Panel Replay not possible\n"); + return; + } } intel_dp->psr.sink_panel_replay_support = true; From patchwork Mon May 27 07:22:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674696 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 499DEC25B78 for ; Mon, 27 May 2024 07:23:57 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 42F2910F903; Mon, 27 May 2024 07:23:56 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="h6U/b7oy"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 18D6010EE5B for ; Mon, 27 May 2024 07:22:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794579; x=1748330579; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=qyfubewv70ONxJotxe1erxl2MHXd00C2xucv7WLmtUQ=; b=h6U/b7oyp5VoHqGvWm9lAiqL53G+amWrJXVJ/dnvYIKoF/EwwYt2OYAZ N6w7nlv07rNDPIThV7DNVR2W413JPcfvOy8v8Cd4euZBiPGwHAU40+KMe IGGq15hHApM4z6b57pP4VnvuPNh4lJmvMVEugNuJDlsxnbJRUKh29IQfX oxFT3D4qNf02COOTfXNhYymkO6zErJwO5h4DKtUJbmk6yYzbJmNQseG4y /6glanPSOv2xZDLfzIMnrRinBrCw/ol6pCKIQwK094NGCP6dxFSZUAmZW Rb7N+cTexj/vj5rpULFLNNHgpYb+M8k3EafjrovEZvUwTKWTetzUKeh8Q Q==; X-CSE-ConnectionGUID: 9h9Dd3pRRHau4AEMfaPwvw== X-CSE-MsgGUID: X3zifpBfT7y52dmo5Dkv3Q== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930464" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930464" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:59 -0700 X-CSE-ConnectionGUID: 3E0wtRi8R5yIGYwoHrr6DA== X-CSE-MsgGUID: lrg/40p5SDOmqkJZZ59bXw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753462" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:22:58 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 13/20] drm/i915/psr: Perfrom psr2 checks related to ALPM for Panel Replay Date: Mon, 27 May 2024 10:22:13 +0300 Message-Id: <20240527072220.3294769-14-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" eDP1.5 support ALPM with Panel Replay as well. We need to check ALPM related things for Panel Replay as well. Bspec: 68920 Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 45 +++++++++++++----------- 1 file changed, 24 insertions(+), 21 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index a96e03cd68ea..7c92a63188bc 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -1594,27 +1594,6 @@ static bool intel_psr2_config_valid(struct intel_dp *intel_dp, return false; } - if (!_compute_psr2_sdp_prior_scanline_indication(intel_dp, crtc_state)) { - drm_dbg_kms(&dev_priv->drm, - "PSR2 not enabled, PSR2 SDP indication do not fit in hblank\n"); - return false; - } - - if (!_compute_alpm_params(intel_dp, crtc_state)) { - drm_dbg_kms(&dev_priv->drm, - "PSR2 not enabled, Unable to use long enough wake times\n"); - return false; - } - - /* Vblank >= PSR2_CTL Block Count Number maximum line count */ - if (crtc_state->hw.adjusted_mode.crtc_vblank_end - - crtc_state->hw.adjusted_mode.crtc_vblank_start < - psr2_block_count_lines(intel_dp)) { - drm_dbg_kms(&dev_priv->drm, - "PSR2 not enabled, too short vblank time\n"); - return false; - } - if (!crtc_state->enable_psr2_sel_fetch && (crtc_hdisplay > psr_max_h || crtc_vdisplay > psr_max_v)) { drm_dbg_kms(&dev_priv->drm, @@ -1653,6 +1632,30 @@ static bool intel_sel_update_config_valid(struct intel_dp *intel_dp, if (!crtc_state->has_panel_replay && !intel_psr2_config_valid(intel_dp, crtc_state)) goto unsupported; + if (intel_dp_is_edp(intel_dp)) { + if (!_compute_psr2_sdp_prior_scanline_indication(intel_dp, + crtc_state)) { + drm_dbg_kms(&dev_priv->drm, + "Selective update not enabled, SDP indication do not fit in hblank\n"); + goto unsupported; + } + + if (!_compute_alpm_params(intel_dp, crtc_state)) { + drm_dbg_kms(&dev_priv->drm, + "Selective update not enabled, Unable to use long enough wake times\n"); + goto unsupported; + } + + /* Vblank >= PSR2_CTL Block Count Number maximum line count */ + if (crtc_state->hw.adjusted_mode.crtc_vblank_end - + crtc_state->hw.adjusted_mode.crtc_vblank_start < + psr2_block_count_lines(intel_dp)) { + drm_dbg_kms(&dev_priv->drm, + "Selective update not enabled, too short vblank time\n"); + goto unsupported; + } + } + if (crtc_state->has_panel_replay && (DISPLAY_VER(dev_priv) < 14 || !intel_dp->psr.sink_panel_replay_su_support)) goto unsupported; From patchwork Mon May 27 07:22:14 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674683 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A5394C25B78 for ; Mon, 27 May 2024 07:23:15 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id B7FEC10E201; Mon, 27 May 2024 07:23:14 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="AwB2krKy"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id C55BF10F332 for ; Mon, 27 May 2024 07:23:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794581; x=1748330581; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Gk/qT+jZypFXibN4EEgzODRvnBTaOjbDHIoZYnmiAM8=; b=AwB2krKySVOj6/uFMy6d6ipcKInwyarA/3IV7JT6jI1jTeaVYjTv12va SQlF6Sy4qQdcy0MtHEaDPuWS6B5t7ry3XJgA9iN16v/5KziKQGM7rq99o b4vKe5/EeZn4hwLnjvtbAkMQlahp2gD/jLsSAIbTmge2kNmD5YBMD11/i XPa5M6hBUKRWqzKnSSKc0eGJ4GzVPTyWq4K88lPraxOdfu6nxp79YEsj2 W4fhyG9MZBKRY7Y2ETJwk50GKWp0NiflmyIK18dpVfop1S0th3Gpsej4J 5ZBAj3HH3L/4ysgT37iP4dB2fv+1fBI4Z8mDbyn9kvPb+Aiwg/EvwVnCe g==; X-CSE-ConnectionGUID: Pwh8DzEJRt2YOZQypqS8dQ== X-CSE-MsgGUID: idLrowQQRTeQcWUIFi0rtQ== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930468" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930468" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:00 -0700 X-CSE-ConnectionGUID: vh9yYD1HR7WQcNhEZW8FAg== X-CSE-MsgGUID: dOWxJZvQSfq0GeJ2+5sepA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753467" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:00 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 14/20] drm/i915/psr: Add Panel Replay compute_config helper Date: Mon, 27 May 2024 10:22:14 +0300 Message-Id: <20240527072220.3294769-15-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" We are about to add more checks for Panel Replay. Due to that it makes sense to add now Panel Replay compute config helper. Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 7c92a63188bc..7cc7cdddc8b3 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -1709,6 +1709,14 @@ static bool _psr_compute_config(struct intel_dp *intel_dp, return true; } +static bool _panel_replay_compute_config(struct intel_dp *intel_dp) +{ + if (!CAN_PANEL_REPLAY(intel_dp)) + return false; + + return true; +} + void intel_psr_compute_config(struct intel_dp *intel_dp, struct intel_crtc_state *crtc_state, struct drm_connector_state *conn_state) @@ -1744,8 +1752,7 @@ void intel_psr_compute_config(struct intel_dp *intel_dp, return; } - if (CAN_PANEL_REPLAY(intel_dp)) - crtc_state->has_panel_replay = true; + crtc_state->has_panel_replay = _panel_replay_compute_config(intel_dp); crtc_state->has_psr = crtc_state->has_panel_replay ? true : _psr_compute_config(intel_dp, crtc_state); From patchwork Mon May 27 07:22:15 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674694 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 22098C25B78 for ; Mon, 27 May 2024 07:23:55 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 545B010F88A; Mon, 27 May 2024 07:23:54 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="ezJHp+5u"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id B230010E201 for ; Mon, 27 May 2024 07:23:02 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794583; x=1748330583; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=czmrTICOUbwIYRUuMcwjyjbeKc/mKDbAEj8+80BErjI=; b=ezJHp+5ubVdI98mED5x4D+Drw3mcggNYlSHVCdwT8DYaJBTrkHwkLHdK 9CiEEQ52KlKj1jPoYmbzM/wO5+c4ubxKeIDdX5QPDS2X8ryoATHTJS8I4 tsbWorv5m1mg8wlPzxng65pSkvbEh2H040BkBwZFLm70tbIlBPWixvAT2 ue0B2V8a+eoV4+3NpahsMqESWPQkdnkb59T/vD0YOEG1QJ/XwC7aIM6z9 vjuOv6co4jrbOa8eJcj/Zl2T8GKwOoPT1SHG0baG9tanstQQc08QOJ5qv W/B+jkgZNbG+s5eauKlg270SUaNK++9HhTCmDPhyCYMdgu0qHFw0DhGsH A==; X-CSE-ConnectionGUID: yQUwNOHPSZ6p3gsHY1UCQA== X-CSE-MsgGUID: Acsu+/z3TE6rrmv6pukQ8Q== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930470" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930470" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:02 -0700 X-CSE-ConnectionGUID: wkcuwLLRR06OfA3h4+JTrQ== X-CSE-MsgGUID: 7L8aV3jvRvWazKIyuESBMQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753483" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:01 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 15/20] drm/i915/psr: 128b/132b Panel Replay is not supported on eDP Date: Mon, 27 May 2024 10:22:15 +0300 Message-Id: <20240527072220.3294769-16-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Take into account that 128b/132b Panel Replay is not supported on eDP. Bspec: 68920 Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 7cc7cdddc8b3..ed2c23e8ce55 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -1709,11 +1709,22 @@ static bool _psr_compute_config(struct intel_dp *intel_dp, return true; } -static bool _panel_replay_compute_config(struct intel_dp *intel_dp) +static bool +_panel_replay_compute_config(struct intel_dp *intel_dp, + const struct intel_crtc_state *crtc_state) { if (!CAN_PANEL_REPLAY(intel_dp)) return false; + if (!intel_dp_is_edp(intel_dp)) + return true; + + /* Remaining checks are for eDP only */ + + /* 128b/132b Panel Replay is not supported on eDP */ + if (intel_dp_is_uhbr(crtc_state)) + return false; + return true; } @@ -1752,7 +1763,8 @@ void intel_psr_compute_config(struct intel_dp *intel_dp, return; } - crtc_state->has_panel_replay = _panel_replay_compute_config(intel_dp); + crtc_state->has_panel_replay = _panel_replay_compute_config(intel_dp, + crtc_state); crtc_state->has_psr = crtc_state->has_panel_replay ? true : _psr_compute_config(intel_dp, crtc_state); From patchwork Mon May 27 07:22:16 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674689 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id AE6C2C25B74 for ; Mon, 27 May 2024 07:23:35 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id EE76510F805; Mon, 27 May 2024 07:23:34 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="ZLRdjgCn"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 5691E10EDC6 for ; Mon, 27 May 2024 07:23:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794585; x=1748330585; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=+bkpg4o3KVNXgWKNuRAwTNWCYeDj0oDn6v0pTwQjRR4=; b=ZLRdjgCndTMTD5sSuACbnyz/Uyn8WbPEHXStmZgHRQmYLYuiMTc1McEY IjPeNCYFGnw6KyRj94AK6AaAKRH3Ckwk6vm28Eh+4LrWl2q18iguQdP4y OlA7nG8ejmAWf3cAkXYpIJLUDh5MCMu1oNq6FBO6WYg5V5EaEiG1z7ELe HJdwE7EpXAl1f3jNDABTgcWca4MPFKhxmXVK25eF0o9TNntFvxCAWDYRa 6Cst+vKXJNa9C3FtmE2Vs7ZDKMqYvlnDfFGTkX/vJaikwGtGoMvjdGKFI l53mfyzGDLz4o0SXg7/jY3M0Svs5A/zdz4hrj4+KyFfcYiCsCtTq8iBDD Q==; X-CSE-ConnectionGUID: bHufzvYdSwqP6DNN8Am7lw== X-CSE-MsgGUID: dG4Dbt6sQeehVOeI4XEcYA== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930476" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930476" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:04 -0700 X-CSE-ConnectionGUID: 6b010+LNQR+JwoJj1ejUkg== X-CSE-MsgGUID: SidQEJc+Qv+Nu9eN7FKIPQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753496" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:03 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 16/20] drm/i915/psr: HW will not allow PR on eDP when HDCP enabled Date: Mon, 27 May 2024 10:22:16 +0300 Message-Id: <20240527072220.3294769-17-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Take into account in Panel Replay compute config that HW will not allow PR on eDP when HDCP enabled. Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index ed2c23e8ce55..455ad13d9903 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -1711,8 +1711,13 @@ static bool _psr_compute_config(struct intel_dp *intel_dp, static bool _panel_replay_compute_config(struct intel_dp *intel_dp, - const struct intel_crtc_state *crtc_state) + const struct intel_crtc_state *crtc_state, + const struct drm_connector_state *conn_state) { + struct intel_connector *connector = + to_intel_connector(conn_state->connector); + struct intel_hdcp *hdcp = &connector->hdcp; + if (!CAN_PANEL_REPLAY(intel_dp)) return false; @@ -1725,6 +1730,14 @@ _panel_replay_compute_config(struct intel_dp *intel_dp, if (intel_dp_is_uhbr(crtc_state)) return false; + /* HW will not allow Panel Replay on eDP when HDCP enabled */ + if (conn_state->content_protection == + DRM_MODE_CONTENT_PROTECTION_DESIRED || + (conn_state->content_protection == + DRM_MODE_CONTENT_PROTECTION_ENABLED && hdcp->value == + DRM_MODE_CONTENT_PROTECTION_UNDESIRED)) + return false; + return true; } @@ -1764,7 +1777,8 @@ void intel_psr_compute_config(struct intel_dp *intel_dp, } crtc_state->has_panel_replay = _panel_replay_compute_config(intel_dp, - crtc_state); + crtc_state, + conn_state); crtc_state->has_psr = crtc_state->has_panel_replay ? true : _psr_compute_config(intel_dp, crtc_state); From patchwork Mon May 27 07:22:17 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674695 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 92058C25B74 for ; Mon, 27 May 2024 07:23:56 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id AE25510F3C7; Mon, 27 May 2024 07:23:55 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="dcyGfQpW"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7C76D10EE5B for ; Mon, 27 May 2024 07:23:06 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794586; x=1748330586; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=FrYbC7SqScy2GfGD6wj+P4eZNwmTUFn7zfjhyOAX0u8=; b=dcyGfQpWxIcy/JFHkrsHwaQ8w+spZpi5N0hcmfR5kSdpuf+Att5SWSFs ebtZR/LiTPW/EQBYoGPjHTB2fn548oMFdDjuDxeZ73aggeeYF54ijChoy 4IymB+gvjNGnT/kBQm3xa6lEENaodWB8rbCxfhc/wgXpx1d+dnuDmn2/b aoBU9k8Jz2IhgK4Ila4oZh76mVJgyRHZ+rtoUjTEeMVd9iS5+3a8KQbtF Xmt6kaxpt1JG1eM0BdsWfsCfpFEo4QNLfoumIdyWl89Yuz/b5I2L15Lyw nQ7kPC5GpQHmZs03B4/tK2e1sIvDQPCfqbyaGqhSQaVNXd+GKHIqnr5Kd w==; X-CSE-ConnectionGUID: FCxM+kcmQzGoUbB87ILPPA== X-CSE-MsgGUID: XF+JWAdRRIiUKydh9kcMKQ== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930482" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930482" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:06 -0700 X-CSE-ConnectionGUID: I7DR6LMjQaK9c7JR7nQRZg== X-CSE-MsgGUID: ZVDtuBR7TbG+g58yXhOaZQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753509" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:05 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 17/20] drm/i915/psr: Check Early Transport for Panel Replay as well Date: Mon, 27 May 2024 10:22:17 +0300 Message-Id: <20240527072220.3294769-18-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Move Early Transport validity check to be performed for Panel Replay as well and use Early Transport for eDP Panel Replay always. Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 455ad13d9903..50021e797120 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -1605,9 +1605,6 @@ static bool intel_psr2_config_valid(struct intel_dp *intel_dp, tgl_dc3co_exitline_compute_config(intel_dp, crtc_state); - if (psr2_su_region_et_valid(intel_dp, false)) - crtc_state->enable_psr2_su_region_et = true; - return true; } @@ -1672,6 +1669,9 @@ static bool intel_sel_update_config_valid(struct intel_dp *intel_dp, goto unsupported; } + if (psr2_su_region_et_valid(intel_dp, crtc_state->has_panel_replay)) + crtc_state->enable_psr2_su_region_et = true; + return true; unsupported: From patchwork Mon May 27 07:22:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674690 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 29F68C25B78 for ; Mon, 27 May 2024 07:23:37 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id C64B310F8FE; Mon, 27 May 2024 07:23:35 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="SU40JnQD"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id AB45310E6ED for ; Mon, 27 May 2024 07:23:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794599; x=1748330599; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=pAq7PcxjUhfRrhpuMNFJYEXbKMY1vdYdp4CUyWE3IlU=; b=SU40JnQDOSNemJZnN8Ivk9JIVeoNapedUvI1TALCJ/43rEssn2vPsusN u/u/PY74l2oNG7m9uTvu5UpvRayL8l+INKN1tqwTr2Vp5gRRuoj4nCjQd NJ2Lg74SGDldRw/pZdbnq/1fDEiEIjehz1cXindInvMvx45iR2A/555a0 UD9Jx81dzU1uT92X6IZcL15mGeEeT3UPViD0BFWGW/w4VHyWIMN+TGg/k 7nfyeyqm0kP5BoK2/TtMb2zkyfVBftLvXgb4CUL1RDwADWZfR0HJoIAMP t+lC65s5IWjdFJR1PJLrHwxYG4QffGb4BYe5qgEIgBBhB5kxGCbgKRQFs w==; X-CSE-ConnectionGUID: HV5k1VoOR4O9jmzVeg8+ew== X-CSE-MsgGUID: dKncb8n+TKeAIoUHQnt8sg== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930484" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930484" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:08 -0700 X-CSE-ConnectionGUID: HloxjfPRST6Rvs7c8I0yrw== X-CSE-MsgGUID: +OAfaoSmSkWDCepDSCHxKQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753517" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:07 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 18/20] drm/i915/psr: Modify dg2_activate_panel_replay to support eDP Date: Mon, 27 May 2024 10:22:18 +0300 Message-Id: <20240527072220.3294769-19-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" There are couple of bits in PSR2_CTL which needs to be written in case of eDP Panel Replay Bspec: 68920 Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 50021e797120..38874ca46c16 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -929,6 +929,18 @@ static u8 frames_before_su_entry(struct intel_dp *intel_dp) static void dg2_activate_panel_replay(struct intel_dp *intel_dp) { struct drm_i915_private *dev_priv = dp_to_i915(intel_dp); + struct intel_psr *psr = &intel_dp->psr; + enum transcoder cpu_transcoder = intel_dp->psr.transcoder; + + if (intel_dp_is_edp(intel_dp) && psr->sel_update_enabled) { + u32 val = LNL_EDP_PSR2_SU_REGION_ET_ENABLE; + + if (intel_dp->psr.req_psr2_sdp_prior_scanline) + val |= EDP_PSR2_SU_SDP_SCANLINE; + + intel_de_write(dev_priv, EDP_PSR2_CTL(dev_priv, cpu_transcoder), + val); + } intel_de_rmw(dev_priv, PSR2_MAN_TRK_CTL(dev_priv, intel_dp->psr.transcoder), From patchwork Mon May 27 07:22:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674693 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 9A96FC25B74 for ; Mon, 27 May 2024 07:23:41 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id BD0A510F918; Mon, 27 May 2024 07:23:40 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="Wm5ANQmG"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 3799610EE5B for ; Mon, 27 May 2024 07:23:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794599; x=1748330599; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=AKTE/TGMJeSk4XMHEkOMClAhIjp6u/l1t1eUNvS3R3s=; b=Wm5ANQmGhQxRobTA/aEkJ5FFEsdRtGkEV0GF4kOp3Bh3ZPq4T0tVf1nK 9bchByT/A8ke60vCShf+/M8bxRlkbXj+XsCzgdGaWnf6RaPQpdIddnKW/ EspZVByNxQijObxfER25KaGOuuo0iAiT34Sz8XQw5Hmu5kPTmrkHHXidG 3Idz75gJDYToH8beLvuGmaDqz55ZNnH1JlCJCxFp0gud4txS9juutXwTV sWwsi9UIpF5L6jo8r7g2x9jYZmCUIAmT/Oj9xWhkpYdSN/qHWC2rL5s/S MAyP6wJf8U/dRzZ586aufZyp1lpmEN5dab/g4F48nL1AZXJy2E3IkWzrG w==; X-CSE-ConnectionGUID: mgI1IUBYR3m2rqdC8r1CGw== X-CSE-MsgGUID: nUHelcNNSYm2mdMTQfRM/A== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930490" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930490" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:09 -0700 X-CSE-ConnectionGUID: 0lC5/ctCQwixShF5DZuZjA== X-CSE-MsgGUID: kMo7TTVIT8uHSOuWEZhopw== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753528" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:09 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 19/20] drm/i915/psr: Add new debug bit to disable Panel Replay Date: Mon, 27 May 2024 10:22:19 +0300 Message-Id: <20240527072220.3294769-20-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" Currently there is no way to disable Panel Replay without disabling PSR. Add new debug bit to be used with i915_edp_psr_debug debugfs interface. v2: ensure that fastset is performed when the bit changes Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_display_types.h | 1 + drivers/gpu/drm/i915/display/intel_psr.c | 13 ++++++++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_display_types.h b/drivers/gpu/drm/i915/display/intel_display_types.h index 6fbfe8a18f45..f8863510e722 100644 --- a/drivers/gpu/drm/i915/display/intel_display_types.h +++ b/drivers/gpu/drm/i915/display/intel_display_types.h @@ -1687,6 +1687,7 @@ struct intel_psr { #define I915_PSR_DEBUG_ENABLE_SEL_FETCH 0x4 #define I915_PSR_DEBUG_IRQ 0x10 #define I915_PSR_DEBUG_SU_REGION_ET_DISABLE 0x20 +#define I915_PSR_DEBUG_PANEL_REPLAY_DISABLE 0x40 u32 debug; bool sink_support; diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index 38874ca46c16..c7934cdfe418 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -1733,6 +1733,9 @@ _panel_replay_compute_config(struct intel_dp *intel_dp, if (!CAN_PANEL_REPLAY(intel_dp)) return false; + if (intel_dp->psr.debug & I915_PSR_DEBUG_PANEL_REPLAY_DISABLE) + return false; + if (!intel_dp_is_edp(intel_dp)) return true; @@ -3097,10 +3100,12 @@ int intel_psr_debug_set(struct intel_dp *intel_dp, u64 val) { struct drm_i915_private *dev_priv = dp_to_i915(intel_dp); const u32 mode = val & I915_PSR_DEBUG_MODE_MASK; - u32 old_mode; + const u32 disable_bits = val & I915_PSR_DEBUG_PANEL_REPLAY_DISABLE; + u32 old_mode, old_disable_bits; int ret; - if (val & ~(I915_PSR_DEBUG_IRQ | I915_PSR_DEBUG_MODE_MASK) || + if (val & ~(I915_PSR_DEBUG_IRQ | I915_PSR_DEBUG_PANEL_REPLAY_DISABLE | + I915_PSR_DEBUG_MODE_MASK) || mode > I915_PSR_DEBUG_ENABLE_SEL_FETCH) { drm_dbg_kms(&dev_priv->drm, "Invalid debug mask %llx\n", val); return -EINVAL; @@ -3111,6 +3116,8 @@ int intel_psr_debug_set(struct intel_dp *intel_dp, u64 val) return ret; old_mode = intel_dp->psr.debug & I915_PSR_DEBUG_MODE_MASK; + old_disable_bits = intel_dp->psr.debug & + I915_PSR_DEBUG_PANEL_REPLAY_DISABLE; intel_dp->psr.debug = val; /* @@ -3122,7 +3129,7 @@ int intel_psr_debug_set(struct intel_dp *intel_dp, u64 val) mutex_unlock(&intel_dp->psr.lock); - if (old_mode != mode) + if (old_mode != mode || old_disable_bits != disable_bits) ret = intel_psr_fastset_force(dev_priv); return ret; From patchwork Mon May 27 07:22:20 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: "Hogander, Jouni" X-Patchwork-Id: 13674688 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 09D15C25B74 for ; Mon, 27 May 2024 07:23:32 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 68A7810F332; Mon, 27 May 2024 07:23:31 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=intel.com header.i=@intel.com header.b="YrKaE+XH"; dkim-atps=neutral Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.12]) by gabe.freedesktop.org (Postfix) with ESMTPS id 8327610F332 for ; Mon, 27 May 2024 07:23:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1716794599; x=1748330599; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=iebx7aMALIYnimGDrzWu8TqAfJxaofjsKe3ex90199U=; b=YrKaE+XHOvuP6rrHldZkYpS+To/NH2otoxL80wpGkpDkrYN40urFhiL1 LnWQwF5MjpcEOlKQdG5Yk/GcXm7qQdDKYo2yBUA3SVFOs1VcyRXoGbYn1 9RCR0t8uxxCXH8dk+6lemQqMII59vmcYmhgYffGHu19obbcLuDuPUQqUN pTbT6jXb6ROQ6pJXnjas/1z+f7/poZNJUcOk8dSuWWrpPCU6ogEGtUpJD LNWQY8xCBqIXN46IeILWwUnVJ6gkHixxaI83awWwWmyf3rSX1Rqbw6H9R fyHrogI+7WAYI2xq4MEsyuUGROjrZexLgJlGM1XZ9QW0LTTEfUsUyAw3D g==; X-CSE-ConnectionGUID: 0FeT/xX6TBWhOJcvnemJ7A== X-CSE-MsgGUID: 9azt3hvZR2ehC6htHztkkA== X-IronPort-AV: E=McAfee;i="6600,9927,11084"; a="16930494" X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="16930494" Received: from orviesa009.jf.intel.com ([10.64.159.149]) by fmvoesa106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:11 -0700 X-CSE-ConnectionGUID: +yGqjrLpQv2fkLqvJK8H7w== X-CSE-MsgGUID: 4KXUKSkvRP+Y0Cpixx8fIQ== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,192,1712646000"; d="scan'208";a="34753534" Received: from gcusmai-mobl.ger.corp.intel.com (HELO jhogande-mobl1.intel.com) ([10.249.36.101]) by orviesa009-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 May 2024 00:23:10 -0700 From: =?utf-8?q?Jouni_H=C3=B6gander?= To: intel-gfx@lists.freedesktop.org Cc: animesh.manna@intel.com, mika.kahola@intel.com, =?utf-8?q?Jouni_H=C3=B6g?= =?utf-8?q?ander?= Subject: [PATCH v3 20/20] Revert "drm/i915/psr: Disable early transport by default" Date: Mon, 27 May 2024 10:22:20 +0300 Message-Id: <20240527072220.3294769-21-jouni.hogander@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240527072220.3294769-1-jouni.hogander@intel.com> References: <20240527072220.3294769-1-jouni.hogander@intel.com> MIME-Version: 1.0 Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.29 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" This reverts commit f3c2031db7dfdf470a2d9bf3bd1efa6edfa72d8d. We want to notice possible issues faced with PSR2 Region Early Transport as early as possible -> let's revert patch disabling Region Early Transport by default. Also eDP 1.5 Panel Replay requires Early Transport. Signed-off-by: Jouni Högander --- drivers/gpu/drm/i915/display/intel_psr.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/gpu/drm/i915/display/intel_psr.c b/drivers/gpu/drm/i915/display/intel_psr.c index c7934cdfe418..67cc6a2b1fdf 100644 --- a/drivers/gpu/drm/i915/display/intel_psr.c +++ b/drivers/gpu/drm/i915/display/intel_psr.c @@ -3419,9 +3419,6 @@ void intel_psr_init(struct intel_dp *intel_dp) if (HAS_PSR(dev_priv) && intel_dp_is_edp(intel_dp)) intel_dp->psr.source_support = true; - /* Disable early transport for now */ - intel_dp->psr.debug |= I915_PSR_DEBUG_SU_REGION_ET_DISABLE; - /* Set link_standby x link_off defaults */ if (DISPLAY_VER(dev_priv) < 12) /* For new platforms up to TGL let's respect VBT back again */