From: Matt Atwood <matthew.s.atwood@intel.com>
To: Mika Kahola <mika.kahola@intel.com>, <intel-gfx@lists.freedesktop.org>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH 11/13] drm/i915/mtl: TypeC HPD live status query
Date: Thu, 27 Apr 2023 09:13:21 -0700 [thread overview]
Message-ID: <ZEqfIeAZGQePjpMj@msatwood-mobl> (raw)
In-Reply-To: <20230420124050.3617608-12-mika.kahola@intel.com>
On Thu, Apr 20, 2023 at 03:40:48PM +0300, Mika Kahola wrote:
> From: Imre Deak <imre.deak@intel.com>
>
> The HPD live status for MTL has to be read from different set of
> registers. MTL deserves a new function for this purpose
> and cannot reuse the existing HPD live status detection
>
Reviewed-by: Matt Atwood <matthew.s.atwood@intel.com>
> Signed-off-by: Anusha Srivatsa <anusha.srivatsa@intel.com>
> Signed-off-by: Imre Deak <imre.deak@intel.com>
> Signed-off-by: Mika Kahola <mika.kahola@intel.com>
> ---
> drivers/gpu/drm/i915/display/intel_tc.c | 30 ++++++++++++++++++++++++-
> 1 file changed, 29 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_tc.c b/drivers/gpu/drm/i915/display/intel_tc.c
> index 951b12ac51dc..b192265a3d78 100644
> --- a/drivers/gpu/drm/i915/display/intel_tc.c
> +++ b/drivers/gpu/drm/i915/display/intel_tc.c
> @@ -886,6 +886,34 @@ static const struct intel_tc_phy_ops adlp_tc_phy_ops = {
> * XELPDP TC PHY handlers
> * ----------------------
> */
> +static u32 xelpdp_tc_phy_hpd_live_status(struct intel_tc_port *tc)
> +{
> + struct drm_i915_private *i915 = tc_to_i915(tc);
> + struct intel_digital_port *dig_port = tc->dig_port;
> + enum hpd_pin hpd_pin = dig_port->base.hpd_pin;
> + u32 pica_isr_bits = i915->display.hotplug.hpd[hpd_pin];
> + u32 pch_isr_bit = i915->display.hotplug.pch_hpd[hpd_pin];
> + intel_wakeref_t wakeref;
> + u32 pica_isr;
> + u32 pch_isr;
> + u32 mask = 0;
> +
> + with_intel_display_power(i915, POWER_DOMAIN_DISPLAY_CORE, wakeref) {
> + pica_isr = intel_de_read(i915, PICAINTERRUPT_ISR);
> + pch_isr = intel_de_read(i915, SDEISR);
> + }
> +
> + if (pica_isr & (pica_isr_bits & XELPDP_DP_ALT_HOTPLUG_MASK))
> + mask |= BIT(TC_PORT_DP_ALT);
> + if (pica_isr & (pica_isr_bits & XELPDP_TBT_HOTPLUG_MASK))
> + mask |= BIT(TC_PORT_TBT_ALT);
> +
> + if (tc->legacy_port && (pch_isr & pch_isr_bit))
> + mask |= BIT(TC_PORT_LEGACY);
> +
> + return mask;
> +}
> +
> static bool
> xelpdp_tc_phy_tcss_power_is_enabled(struct intel_tc_port *tc)
> {
> @@ -1039,7 +1067,7 @@ static void xelpdp_tc_phy_disconnect(struct intel_tc_port *tc)
>
> static const struct intel_tc_phy_ops xelpdp_tc_phy_ops = {
> .cold_off_domain = tgl_tc_phy_cold_off_domain,
> - .hpd_live_status = adlp_tc_phy_hpd_live_status,
> + .hpd_live_status = xelpdp_tc_phy_hpd_live_status,
> .is_ready = adlp_tc_phy_is_ready,
> .is_owned = xelpdp_tc_phy_is_owned,
> .get_hw_state = xelpdp_tc_phy_get_hw_state,
> --
> 2.34.1
>
next prev parent reply other threads:[~2023-04-27 16:14 UTC|newest]
Thread overview: 47+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-20 12:40 [Intel-gfx] [PATCH 00/13] drm/i915/mtl: Add support for C20 phy Mika Kahola
2023-04-20 12:40 ` [Intel-gfx] [PATCH 01/13] drm/i915/mtl: C20 PLL programming Mika Kahola
2023-04-21 23:24 ` Radhakrishna Sripada
2023-04-24 8:39 ` Kahola, Mika
2023-04-27 3:22 ` Murthy, Arun R
2023-04-28 9:07 ` Andi Shyti
2023-04-28 9:11 ` Kahola, Mika
2023-04-20 12:40 ` [Intel-gfx] [PATCH 02/13] drm/i915/mtl: C20 HW readout Mika Kahola
2023-04-24 20:56 ` Radhakrishna Sripada
2023-04-26 11:43 ` Kahola, Mika
2023-04-27 16:47 ` Sripada, Radhakrishna
2023-04-27 3:31 ` Murthy, Arun R
2023-04-27 10:25 ` Kahola, Mika
2023-04-28 9:14 ` Andi Shyti
2023-04-20 12:40 ` [Intel-gfx] [PATCH 03/13] drm/i915/mtl: Dump C20 pll hw state Mika Kahola
2023-04-24 21:18 ` Radhakrishna Sripada
2023-04-27 3:37 ` Murthy, Arun R
2023-04-28 9:15 ` Andi Shyti
2023-04-20 12:40 ` [Intel-gfx] [PATCH 04/13] drm/i915/mtl: C20 port clock calculation Mika Kahola
2023-04-25 19:08 ` Radhakrishna Sripada
2023-04-27 3:50 ` Murthy, Arun R
2023-04-20 12:40 ` [Intel-gfx] [PATCH 05/13] drm/i915/mtl: Add voltage swing sequence for C20 Mika Kahola
2023-04-27 4:29 ` Murthy, Arun R
2023-04-20 12:40 ` [Intel-gfx] [PATCH 06/13] drm/i915/mtl: For DP2.0 10G and 20G rates use MPLLA Mika Kahola
2023-04-24 18:09 ` Radhakrishna Sripada
2023-04-27 4:31 ` Murthy, Arun R
2023-04-27 9:14 ` Manna, Animesh
2023-05-03 8:25 ` Jani Nikula
2023-04-20 12:40 ` [Intel-gfx] [PATCH 07/13] drm/i915/mtl: Enabling/disabling sequence Thunderbolt pll Mika Kahola
2023-04-25 19:32 ` Radhakrishna Sripada
2023-04-28 9:20 ` Andi Shyti
2023-04-20 12:40 ` [Intel-gfx] [PATCH 08/13] drm/i915/mtl: Readout Thunderbolt HW state Mika Kahola
2023-04-25 20:11 ` Radhakrishna Sripada
2023-04-20 12:40 ` [Intel-gfx] [PATCH 09/13] drm/i915/mtl: Define mask for DDI AUX interrupts Mika Kahola
2023-04-25 20:29 ` Radhakrishna Sripada
2023-04-20 12:40 ` [Intel-gfx] [PATCH 10/13] drm/i915/mtl: Power up TCSS Mika Kahola
2023-04-27 16:09 ` Matt Atwood
2023-04-20 12:40 ` [Intel-gfx] [PATCH 11/13] drm/i915/mtl: TypeC HPD live status query Mika Kahola
2023-04-27 16:13 ` Matt Atwood [this message]
2023-04-20 12:40 ` [Intel-gfx] [PATCH 12/13] drm/i915/mtl: Pin assignment for TypeC Mika Kahola
2023-04-27 16:17 ` Matt Atwood
2023-04-20 12:40 ` [Intel-gfx] [PATCH 13/13] drm/i915/mtl: Enable TC ports Mika Kahola
2023-04-27 15:49 ` Clint Taylor
2023-04-20 15:36 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for drm/i915/mtl: Add support for C20 phy Patchwork
2023-04-20 15:36 ` [Intel-gfx] ✗ Fi.CI.SPARSE: " Patchwork
2023-04-20 15:53 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2023-04-20 21:38 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " 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=ZEqfIeAZGQePjpMj@msatwood-mobl \
--to=matthew.s.atwood@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=mika.kahola@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox