From: Suraj Kandpal <suraj.kandpal@intel.com>
To: intel-xe@lists.freedesktop.org, intel-gfx@lists.freedesktop.org
Cc: ankit.k.nautiyal@intel.com, Suraj Kandpal <suraj.kandpal@intel.com>
Subject: [PATCH v2 1/2] drm/i915/ltphy: Readout ssc_enabled for LT PHY
Date: Wed, 1 Jul 2026 14:45:02 +0530 [thread overview]
Message-ID: <20260701091503.1302226-2-suraj.kandpal@intel.com> (raw)
In-Reply-To: <20260701091503.1302226-1-suraj.kandpal@intel.com>
We need to readout the ssc_enabled param for LT PHY pll state too.
Create a function that does that, we only need to read SSC Enable PLL A
bit since that is the only one we write Xe3p onwards. While at it
improve the dump using str_yes_or_no.
Bspec: 74667
Signed-off-by: Suraj Kandpal <suraj.kandpal@intel.com>
---
v1 -> v2:
- Fix build error
drivers/gpu/drm/i915/display/intel_lt_phy.c | 14 ++++++++++++--
1 file changed, 12 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/i915/display/intel_lt_phy.c b/drivers/gpu/drm/i915/display/intel_lt_phy.c
index 615ee980470e..956181f80d35 100644
--- a/drivers/gpu/drm/i915/display/intel_lt_phy.c
+++ b/drivers/gpu/drm/i915/display/intel_lt_phy.c
@@ -2178,8 +2178,9 @@ void intel_lt_phy_dump_hw_state(struct drm_printer *p,
{
int i, j;
- drm_printf(p, "lt_phy_pll_hw_state: lane count: %d, ssc enabled: %d, tbt mode: %d\n",
- hw_state->lane_count, hw_state->ssc_enabled, hw_state->tbt_mode);
+ drm_printf(p, "lt_phy_pll_hw_state: lane count: %d, ssc enabled: %s, tbt mode: %s\n",
+ hw_state->lane_count, str_yes_no(hw_state->ssc_enabled),
+ str_yes_no(hw_state->tbt_mode));
for (i = 0; i < 3; i++) {
drm_printf(p, "config[%d] = 0x%.4x,\n",
@@ -2221,6 +2222,14 @@ static bool intel_lt_phy_pll_is_enabled(struct intel_encoder *encoder)
XELPDP_LANE_PCLK_PLL_ACK(0);
}
+static bool readout_ssc_state(struct intel_encoder *encoder)
+{
+ struct intel_display *display = to_intel_display(encoder);
+
+ return intel_de_read(display, XELPDP_PORT_CLOCK_CTL(display, encoder->port)) &
+ XELPDP_SSC_ENABLE_PLLA;
+}
+
bool intel_lt_phy_tbt_pll_readout_hw_state(struct intel_display *display,
struct intel_dpll *pll,
struct intel_dpll_hw_state *hw_state)
@@ -2250,6 +2259,7 @@ bool intel_lt_phy_pll_readout_hw_state(struct intel_encoder *encoder,
owned_lane_mask = intel_lt_phy_get_owned_lane_mask(encoder);
lane = owned_lane_mask & INTEL_LT_PHY_LANE0 ? : INTEL_LT_PHY_LANE1;
wakeref = intel_lt_phy_transaction_begin(encoder);
+ pll_state->ssc_enabled = readout_ssc_state(encoder);
pll_state->lane_count = intel_readout_lane_count(encoder, INTEL_LT_PHY_LANE0,
INTEL_LT_PHY_LANE1);
--
2.34.1
next prev parent reply other threads:[~2026-07-01 9:15 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-01 9:15 [PATCH v2 0/2] Fix LT PHY related SSC writes Suraj Kandpal
2026-07-01 9:15 ` Suraj Kandpal [this message]
2026-07-02 2:51 ` [PATCH v2 1/2] drm/i915/ltphy: Readout ssc_enabled for LT PHY Nautiyal, Ankit K
2026-07-01 9:15 ` [PATCH v2 2/2] drm/i915/ltphy: Fix SSC Enablement bit in PORT_CLOCK_CTL Suraj Kandpal
2026-07-02 2:50 ` Nautiyal, Ankit K
2026-07-01 10:06 ` ✓ CI.KUnit: success for Fix LT PHY related SSC writes (rev2) Patchwork
2026-07-01 11:04 ` ✓ Xe.CI.BAT: " Patchwork
2026-07-01 12:09 ` ✓ i915.CI.BAT: " Patchwork
2026-07-02 0:39 ` ✗ i915.CI.Full: failure " Patchwork
2026-07-02 2:30 ` ✓ Xe.CI.FULL: success " Patchwork
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260701091503.1302226-2-suraj.kandpal@intel.com \
--to=suraj.kandpal@intel.com \
--cc=ankit.k.nautiyal@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=intel-xe@lists.freedesktop.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.