diff mbox series

drm/i915/display/dg1: Correctly map DPLLs during state readout

Message ID 20210630210522.162674-1-jose.souza@intel.com (mailing list archive)
State New, archived
Headers show
Series drm/i915/display/dg1: Correctly map DPLLs during state readout | expand

Commit Message

Souza, Jose June 30, 2021, 9:05 p.m. UTC
_DG1_DPCLKA0_CFGCR0 maps between DPLL 0 and 1 with one bit for phy A
and B while _DG1_DPCLKA1_CFGCR0 maps between DPLL 2 and 3 with one
bit for phy C and D.

Reusing _cnl_ddi_get_pll() don't take that into cosideration returing
DPLL 0 and 1 for phy C and D.

That is a regression introduced in the refactor done in commit
c9fdceaa64dc ("drm/i915: Move DDI clock readout to encoder->get_config()").
While at it also dropping the macros previously used, not reusing it
to improve readability.

BSpec: 50286
Fixes: c9fdceaa64dc ("drm/i915: Move DDI clock readout to encoder->get_config()")
Cc: Lucas De Marchi <lucas.demarchi@intel.com>
Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
---
 drivers/gpu/drm/i915/display/intel_ddi.c | 19 ++++++++++++++++---
 drivers/gpu/drm/i915/i915_reg.h          |  3 ---
 2 files changed, 16 insertions(+), 6 deletions(-)

Comments

Lucas De Marchi June 30, 2021, 10:50 p.m. UTC | #1
On Wed, Jun 30, 2021 at 02:05:22PM -0700, Jose Souza wrote:
>_DG1_DPCLKA0_CFGCR0 maps between DPLL 0 and 1 with one bit for phy A
>and B while _DG1_DPCLKA1_CFGCR0 maps between DPLL 2 and 3 with one
>bit for phy C and D.
>
>Reusing _cnl_ddi_get_pll() don't take that into cosideration returing
>DPLL 0 and 1 for phy C and D.
>
>That is a regression introduced in the refactor done in commit
>c9fdceaa64dc ("drm/i915: Move DDI clock readout to encoder->get_config()").
>While at it also dropping the macros previously used, not reusing it
>to improve readability.
>
>BSpec: 50286
>Fixes: c9fdceaa64dc ("drm/i915: Move DDI clock readout to encoder->get_config()")
>Cc: Lucas De Marchi <lucas.demarchi@intel.com>
>Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
>Signed-off-by: José Roberto de Souza <jose.souza@intel.com>


Reviewed-by: Lucas De Marchi <lucas.demarchi@intel.com>

thanks
Lucas De Marchi

>---
> drivers/gpu/drm/i915/display/intel_ddi.c | 19 ++++++++++++++++---
> drivers/gpu/drm/i915/i915_reg.h          |  3 ---
> 2 files changed, 16 insertions(+), 6 deletions(-)
>
>diff --git a/drivers/gpu/drm/i915/display/intel_ddi.c b/drivers/gpu/drm/i915/display/intel_ddi.c
>index 91fd85bee1d27..26a3aa73fcc43 100644
>--- a/drivers/gpu/drm/i915/display/intel_ddi.c
>+++ b/drivers/gpu/drm/i915/display/intel_ddi.c
>@@ -1738,10 +1738,23 @@ static struct intel_shared_dpll *dg1_ddi_get_pll(struct intel_encoder *encoder)
> {
> 	struct drm_i915_private *i915 = to_i915(encoder->base.dev);
> 	enum phy phy = intel_port_to_phy(i915, encoder->port);
>+	enum intel_dpll_id id;
>+	u32 val;
>
>-	return _cnl_ddi_get_pll(i915, DG1_DPCLKA_CFGCR0(phy),
>-				DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_MASK(phy),
>-				DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy));
>+	val = intel_de_read(i915, DG1_DPCLKA_CFGCR0(phy));
>+	val &= DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_MASK(phy);
>+	val >>= DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy);
>+	id = val;
>+
>+	/*
>+	 * _DG1_DPCLKA0_CFGCR0 maps between DPLL 0 and 1 with one bit for phy A
>+	 * and B while _DG1_DPCLKA1_CFGCR0 maps between DPLL 2 and 3 with one
>+	 * bit for phy C and D.
>+	 */
>+	if (phy >= PHY_C)
>+		id += DPLL_ID_DG1_DPLL2;
>+
>+	return intel_get_shared_dpll_by_id(i915, id);
> }
>
> static void icl_ddi_combo_enable_clock(struct intel_encoder *encoder,
>diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
>index 65c155b141899..16a19239d86dd 100644
>--- a/drivers/gpu/drm/i915/i915_reg.h
>+++ b/drivers/gpu/drm/i915/i915_reg.h
>@@ -10525,7 +10525,6 @@ enum skl_power_gate {
> #define _DG1_DPCLKA1_CFGCR0				0x16C280
> #define _DG1_DPCLKA_PHY_IDX(phy)			((phy) % 2)
> #define _DG1_DPCLKA_PLL_IDX(pll)			((pll) % 2)
>-#define _DG1_PHY_DPLL_MAP(phy)				((phy) >= PHY_C ? DPLL_ID_DG1_DPLL2 : DPLL_ID_DG1_DPLL0)
> #define DG1_DPCLKA_CFGCR0(phy)				_MMIO_PHY((phy) / 2, \
> 								  _DG1_DPCLKA_CFGCR0, \
> 								  _DG1_DPCLKA1_CFGCR0)
>@@ -10533,8 +10532,6 @@ enum skl_power_gate {
> #define   DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy)	(_DG1_DPCLKA_PHY_IDX(phy) * 2)
> #define   DG1_DPCLKA_CFGCR0_DDI_CLK_SEL(pll, phy)	(_DG1_DPCLKA_PLL_IDX(pll) << DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy))
> #define   DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_MASK(phy)	(0x3 << DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy))
>-#define   DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_DPLL_MAP(clk_sel, phy) \
>-	(((clk_sel) >> DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy)) + _DG1_PHY_DPLL_MAP(phy))
>
> /* ADLS Clocks */
> #define _ADLS_DPCLKA_CFGCR0			0x164280
>-- 
>2.32.0
>
Souza, Jose July 1, 2021, 5:19 p.m. UTC | #2
On Thu, 2021-07-01 at 05:21 +0000, Patchwork wrote:
Patch Details
Series: drm/i915/display/dg1: Correctly map DPLLs during state readout
URL:    https://patchwork.freedesktop.org/series/92086/
State:  failure
Details:        https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/index.html
CI Bug Log - changes from CI_DRM_10295_full -> Patchwork_20499_full
Summary

FAILURE

Serious unknown changes coming with Patchwork_20499_full absolutely need to be
verified manually.

If you think the reported changes have nothing to do with the changes
introduced in Patchwork_20499_full, please notify your bug team to allow them
to document this new failure mode, which will reduce false positives in CI.

Possible new issues

Here are the unknown changes that may have been introduced in Patchwork_20499_full:

IGT changes
Possible regressions

  *   igt@kms_big_fb@yf-tiled-max-hw-stride-32bpp-rotate-180-async-flip:
     *   shard-skl: NOTRUN -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl2/igt@kms_big_fb@yf-tiled-max-hw-stride-32bpp-rotate-180-async-flip.html>

Not related.
Patch pushed, thanks for the review Lucas.

Suppressed

The following results come from untrusted machines, tests, or statuses.
They do not affect the overall result.

  *   igt@i915_pm_dc@dc6-psr:

     *   {shard-rkl}: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@i915_pm_dc@dc6-psr.html> ([i915#2951]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@i915_pm_dc@dc6-psr.html>
  *   igt@kms_big_fb@x-tiled-max-hw-stride-64bpp-rotate-180-hflip-async-flip:

     *   {shard-rkl}: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_big_fb@x-tiled-max-hw-stride-64bpp-rotate-180-hflip-async-flip.html> -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_big_fb@x-tiled-max-hw-stride-64bpp-rotate-180-hflip-async-flip.html> +66 similar issues
  *   igt@kms_ccs@pipe-a-crc-primary-rotation-180-y_tiled_ccs:

     *   {shard-rkl}: NOTRUN -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-2/igt@kms_ccs@pipe-a-crc-primary-rotation-180-y_tiled_ccs.html> +7 similar issues
  *   igt@kms_ccs@pipe-a-missing-ccs-buffer-y_tiled_ccs:

     *   {shard-rkl}: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-5/igt@kms_ccs@pipe-a-missing-ccs-buffer-y_tiled_ccs.html> -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-6/igt@kms_ccs@pipe-a-missing-ccs-buffer-y_tiled_ccs.html> +9 similar issues
  *   igt@kms_ccs@pipe-b-ccs-on-another-bo-y_tiled_gen12_rc_ccs_cc:

     *   {shard-rkl}: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_ccs@pipe-b-ccs-on-another-bo-y_tiled_gen12_rc_ccs_cc.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_ccs@pipe-b-ccs-on-another-bo-y_tiled_gen12_rc_ccs_cc.html> +6 similar issues
  *   igt@kms_ccs@pipe-c-bad-rotation-90-yf_tiled_ccs:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_ccs@pipe-c-bad-rotation-90-yf_tiled_ccs.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-2/igt@kms_ccs@pipe-c-bad-rotation-90-yf_tiled_ccs.html> +9 similar issues
  *   igt@kms_ccs@pipe-d-crc-primary-basic-y_tiled_gen12_rc_ccs:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_ccs@pipe-d-crc-primary-basic-y_tiled_gen12_rc_ccs.html> ([i915#533]) -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-2/igt@kms_ccs@pipe-d-crc-primary-basic-y_tiled_gen12_rc_ccs.html> +4 similar issues
  *   igt@kms_content_protection@atomic:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_content_protection@atomic.html> ([fdo#109300]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-2/igt@kms_content_protection@atomic.html>
  *   igt@kms_cursor_crc@pipe-a-cursor-64x64-rapid-movement:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-5/igt@kms_cursor_crc@pipe-a-cursor-64x64-rapid-movement.html> ([fdo#112022]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_cursor_crc@pipe-a-cursor-64x64-rapid-movement.html> +5 similar issues
  *   igt@kms_cursor_crc@pipe-b-cursor-max-size-onscreen:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_cursor_crc@pipe-b-cursor-max-size-onscreen.html> ([i915#3359]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_cursor_crc@pipe-b-cursor-max-size-onscreen.html> +4 similar issues
  *   igt@kms_cursor_crc@pipe-c-cursor-32x32-offscreen:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_cursor_crc@pipe-c-cursor-32x32-offscreen.html> ([i915#3319]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-2/igt@kms_cursor_crc@pipe-c-cursor-32x32-offscreen.html> +1 similar issue
  *   igt@kms_cursor_crc@pipe-c-cursor-512x512-random:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_cursor_crc@pipe-c-cursor-512x512-random.html> ([fdo#109279] / [i915#3359]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_cursor_crc@pipe-c-cursor-512x512-random.html>
  *   igt@kms_draw_crc@draw-method-xrgb2101010-render-ytiled:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-5/igt@kms_draw_crc@draw-method-xrgb2101010-render-ytiled.html> ([fdo#111314]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_draw_crc@draw-method-xrgb2101010-render-ytiled.html>
  *   igt@kms_flip@single-buffer-flip-vs-dpms-off-vs-modeset:

     *   {shard-rkl}: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_flip@single-buffer-flip-vs-dpms-off-vs-modeset.html> +18 similar issues
  *   igt@kms_flip_scaled_crc@flip-64bpp-ytile-to-32bpp-ytile:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_flip_scaled_crc@flip-64bpp-ytile-to-32bpp-ytile.html> -> INCOMPLETE<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-2/igt@kms_flip_scaled_crc@flip-64bpp-ytile-to-32bpp-ytile.html>
  *   igt@kms_frontbuffer_tracking@fbcpsr-1p-primscrn-spr-indfb-fullscreen:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-5/igt@kms_frontbuffer_tracking@fbcpsr-1p-primscrn-spr-indfb-fullscreen.html> ([i915#1849]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_frontbuffer_tracking@fbcpsr-1p-primscrn-spr-indfb-fullscreen.html> +21 similar issues
  *   igt@kms_frontbuffer_tracking@fbcpsr-2p-scndscrn-indfb-plflip-blt:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_frontbuffer_tracking@fbcpsr-2p-scndscrn-indfb-plflip-blt.html> ([fdo#111825] / [i915#1825]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_frontbuffer_tracking@fbcpsr-2p-scndscrn-indfb-plflip-blt.html> +14 similar issues
  *   igt@kms_multipipe_modeset@basic-max-pipe-crc-check:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_multipipe_modeset@basic-max-pipe-crc-check.html> ([i915#1839]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_multipipe_modeset@basic-max-pipe-crc-check.html>
  *   igt@kms_psr2_sf@overlay-plane-update-sf-dmg-area-3:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-2/igt@kms_psr2_sf@overlay-plane-update-sf-dmg-area-3.html> ([i915#658]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-6/igt@kms_psr2_sf@overlay-plane-update-sf-dmg-area-3.html>
  *   igt@kms_psr@psr2_cursor_mmap_gtt:

     *   {shard-rkl}: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@kms_psr@psr2_cursor_mmap_gtt.html> ([i915#132]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_psr@psr2_cursor_mmap_gtt.html> +1 similar issue
  *   igt@kms_psr@psr2_sprite_mmap_cpu:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-5/igt@kms_psr@psr2_sprite_mmap_cpu.html> ([i915#1072]) -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-1/igt@kms_psr@psr2_sprite_mmap_cpu.html> +1 similar issue

Known issues

Here are the changes found in Patchwork_20499_full that come from known issues:

IGT changes
Issues hit

  *   igt@gem_create@create-massive:

     *   shard-apl: NOTRUN -> DMESG-WARN<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl1/igt@gem_create@create-massive.html> ([i915#3002])
  *   igt@gem_ctx_persistence@legacy-engines-hostile-preempt:

     *   shard-snb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-snb7/igt@gem_ctx_persistence@legacy-engines-hostile-preempt.html> ([fdo#109271] / [i915#1099]) +4 similar issues
  *   igt@gem_ctx_sseu@engines:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@gem_ctx_sseu@engines.html> ([i915#280])
  *   igt@gem_eio@unwedge-stress:

     *   shard-iclb: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-iclb3/igt@gem_eio@unwedge-stress.html> -> TIMEOUT<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-iclb6/igt@gem_eio@unwedge-stress.html> ([i915#2369] / [i915#2481] / [i915#3070])
  *   igt@gem_exec_fair@basic-none-share@rcs0:

     *   shard-tglb: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-tglb5/igt@gem_exec_fair@basic-none-share@rcs0.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb1/igt@gem_exec_fair@basic-none-share@rcs0.html> ([i915#2842])
  *   igt@gem_exec_fair@basic-pace@vcs1:

     *   shard-iclb: NOTRUN -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-iclb2/igt@gem_exec_fair@basic-pace@vcs1.html> ([i915#2842])
  *   igt@gem_exec_fair@basic-throttle@rcs0:

     *   shard-iclb: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-iclb8/igt@gem_exec_fair@basic-throttle@rcs0.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-iclb3/igt@gem_exec_fair@basic-throttle@rcs0.html> ([i915#2849])
  *   igt@gem_huc_copy@huc-copy:

     *   shard-apl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl1/igt@gem_huc_copy@huc-copy.html> ([fdo#109271] / [i915#2190])
  *   igt@gem_pread@exhaustion:

     *   shard-apl: NOTRUN -> WARN<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl7/igt@gem_pread@exhaustion.html> ([i915#2658]) +1 similar issue
  *   igt@gem_pwrite@basic-exhaustion:

     *   shard-snb: NOTRUN -> WARN<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-snb2/igt@gem_pwrite@basic-exhaustion.html> ([i915#2658])
  *   igt@gem_userptr_blits@coherency-sync:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@gem_userptr_blits@coherency-sync.html> ([fdo#110542])
  *   igt@gem_userptr_blits@dmabuf-sync:

     *   shard-apl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl8/igt@gem_userptr_blits@dmabuf-sync.html> ([fdo#109271] / [i915#3323])
  *   igt@gem_userptr_blits@vma-merge:

     *   shard-apl: NOTRUN -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl3/igt@gem_userptr_blits@vma-merge.html> ([i915#3318])
  *   igt@gen9_exec_parse@allowed-single:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@gen9_exec_parse@allowed-single.html> ([fdo#112306])
  *   igt@i915_pm_dc@dc5-psr:

     *   shard-iclb: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-iclb2/igt@i915_pm_dc@dc5-psr.html> -> DMESG-WARN<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-iclb4/igt@i915_pm_dc@dc5-psr.html> ([i915#3698])
  *   igt@i915_pm_lpsp@kms-lpsp@kms-lpsp-dp:

     *   shard-apl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl7/igt@i915_pm_lpsp@kms-lpsp@kms-lpsp-dp.html> ([fdo#109271] / [i915#1937])
  *   igt@kms_big_fb@yf-tiled-64bpp-rotate-270:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@kms_big_fb@yf-tiled-64bpp-rotate-270.html> ([fdo#111615]) +1 similar issue
  *   igt@kms_ccs@pipe-c-bad-rotation-90-yf_tiled_ccs:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@kms_ccs@pipe-c-bad-rotation-90-yf_tiled_ccs.html> ([i915#3689]) +3 similar issues
  *   igt@kms_ccs@pipe-d-bad-pixel-format-y_tiled_ccs:

     *   shard-snb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-snb7/igt@kms_ccs@pipe-d-bad-pixel-format-y_tiled_ccs.html> ([fdo#109271]) +366 similar issues
  *   igt@kms_chamelium@hdmi-mode-timings:

     *   shard-kbl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl6/igt@kms_chamelium@hdmi-mode-timings.html> ([fdo#109271] / [fdo#111827]) +14 similar issues
  *   igt@kms_color_chamelium@pipe-a-ctm-blue-to-red:

     *   shard-snb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-snb7/igt@kms_color_chamelium@pipe-a-ctm-blue-to-red.html> ([fdo#109271] / [fdo#111827]) +16 similar issues
  *   igt@kms_color_chamelium@pipe-b-degamma:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@kms_color_chamelium@pipe-b-degamma.html> ([fdo#109284] / [fdo#111827]) +1 similar issue
  *   igt@kms_color_chamelium@pipe-c-ctm-0-25:

     *   shard-apl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl1/igt@kms_color_chamelium@pipe-c-ctm-0-25.html> ([fdo#109271] / [fdo#111827]) +33 similar issues
  *   igt@kms_color_chamelium@pipe-c-degamma:

     *   shard-skl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl6/igt@kms_color_chamelium@pipe-c-degamma.html> ([fdo#109271] / [fdo#111827]) +4 similar issues
  *   igt@kms_content_protection@atomic:

     *   shard-kbl: NOTRUN -> TIMEOUT<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl7/igt@kms_content_protection@atomic.html> ([i915#1319])
  *   igt@kms_cursor_crc@pipe-b-cursor-32x32-rapid-movement:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@kms_cursor_crc@pipe-b-cursor-32x32-rapid-movement.html> ([i915#3319])
  *   igt@kms_cursor_crc@pipe-b-cursor-64x21-random:

     *   shard-skl: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-skl6/igt@kms_cursor_crc@pipe-b-cursor-64x21-random.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl3/igt@kms_cursor_crc@pipe-b-cursor-64x21-random.html> ([i915#3444])
  *   igt@kms_cursor_crc@pipe-d-cursor-suspend:

     *   shard-kbl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl2/igt@kms_cursor_crc@pipe-d-cursor-suspend.html> ([fdo#109271]) +179 similar issues
  *   igt@kms_cursor_legacy@flip-vs-cursor-atomic-transitions:

     *   shard-skl: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-skl9/igt@kms_cursor_legacy@flip-vs-cursor-atomic-transitions.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl10/igt@kms_cursor_legacy@flip-vs-cursor-atomic-transitions.html> ([i915#2346])
  *   igt@kms_cursor_legacy@pipe-d-torture-bo:

     *   shard-kbl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl6/igt@kms_cursor_legacy@pipe-d-torture-bo.html> ([fdo#109271] / [i915#533]) +2 similar issues
  *   igt@kms_flip@flip-vs-expired-vblank-interruptible@c-edp1:

     *   shard-skl: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-skl7/igt@kms_flip@flip-vs-expired-vblank-interruptible@c-edp1.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl6/igt@kms_flip@flip-vs-expired-vblank-interruptible@c-edp1.html> ([i915#79])
  *   igt@kms_flip@flip-vs-suspend-interruptible@a-dp1:

     *   shard-kbl: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-kbl6/igt@kms_flip@flip-vs-suspend-interruptible@a-dp1.html> -> DMESG-WARN<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl7/igt@kms_flip@flip-vs-suspend-interruptible@a-dp1.html> ([i915#180]) +3 similar issues
  *   igt@kms_flip@plain-flip-fb-recreate-interruptible@c-edp1:

     *   shard-skl: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-skl5/igt@kms_flip@plain-flip-fb-recreate-interruptible@c-edp1.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl9/igt@kms_flip@plain-flip-fb-recreate-interruptible@c-edp1.html> ([i915#2122]) +2 similar issues
  *   igt@kms_frontbuffer_tracking@fbc-2p-primscrn-cur-indfb-draw-render:

     *   shard-glk: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-glk5/igt@kms_frontbuffer_tracking@fbc-2p-primscrn-cur-indfb-draw-render.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-glk5/igt@kms_frontbuffer_tracking@fbc-2p-primscrn-cur-indfb-draw-render.html> ([i915#2546] / [i915#49])
  *   igt@kms_frontbuffer_tracking@psr-2p-scndscrn-spr-indfb-draw-mmap-cpu:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@kms_frontbuffer_tracking@psr-2p-scndscrn-spr-indfb-draw-mmap-cpu.html> ([fdo#111825]) +3 similar issues
  *   igt@kms_pipe_crc_basic@read-crc-pipe-d-frame-sequence:

     *   shard-apl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl2/igt@kms_pipe_crc_basic@read-crc-pipe-d-frame-sequence.html> ([fdo#109271] / [i915#533]) +3 similar issues
  *   igt@kms_pipe_crc_basic@suspend-read-crc-pipe-d:

     *   shard-skl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl6/igt@kms_pipe_crc_basic@suspend-read-crc-pipe-d.html> ([fdo#109271] / [i915#533])
  *   igt@kms_plane_alpha_blend@pipe-b-alpha-basic:

     *   shard-apl: NOTRUN -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl7/igt@kms_plane_alpha_blend@pipe-b-alpha-basic.html> ([fdo#108145] / [i915#265]) +3 similar issues
  *   igt@kms_plane_alpha_blend@pipe-c-alpha-7efc:

     *   shard-kbl: NOTRUN -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl3/igt@kms_plane_alpha_blend@pipe-c-alpha-7efc.html> ([fdo#108145] / [i915#265]) +2 similar issues
  *   igt@kms_plane_alpha_blend@pipe-c-coverage-7efc:

     *   shard-skl: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-skl9/igt@kms_plane_alpha_blend@pipe-c-coverage-7efc.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl10/igt@kms_plane_alpha_blend@pipe-c-coverage-7efc.html> ([fdo#108145] / [i915#265]) +1 similar issue
  *   igt@kms_plane_lowres@pipe-d-tiling-y:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@kms_plane_lowres@pipe-d-tiling-y.html> ([i915#3536])
  *   igt@kms_plane_lowres@pipe-d-tiling-yf:

     *   shard-skl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl6/igt@kms_plane_lowres@pipe-d-tiling-yf.html> ([fdo#109271]) +48 similar issues
  *   igt@kms_properties@plane-properties-legacy:

     *   shard-tglb: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-tglb6/igt@kms_properties@plane-properties-legacy.html> -> DMESG-WARN<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb5/igt@kms_properties@plane-properties-legacy.html> ([i915#2868])
  *   igt@kms_psr2_sf@overlay-plane-update-sf-dmg-area-2:

     *   shard-apl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl2/igt@kms_psr2_sf@overlay-plane-update-sf-dmg-area-2.html> ([fdo#109271] / [i915#658]) +9 similar issues
  *   igt@kms_psr2_sf@overlay-plane-update-sf-dmg-area-3:

     *   shard-kbl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl6/igt@kms_psr2_sf@overlay-plane-update-sf-dmg-area-3.html> ([fdo#109271] / [i915#658]) +3 similar issues
  *   igt@kms_psr@psr2_cursor_plane_move:

     *   shard-iclb: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-iclb2/igt@kms_psr@psr2_cursor_plane_move.html> -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-iclb3/igt@kms_psr@psr2_cursor_plane_move.html> ([fdo#109441]) +3 similar issues
  *   igt@kms_psr@psr2_primary_blt:

     *   shard-tglb: NOTRUN -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@kms_psr@psr2_primary_blt.html> ([i915#132] / [i915#3467])
  *   igt@kms_vblank@pipe-d-wait-forked-hang:

     *   shard-apl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl1/igt@kms_vblank@pipe-d-wait-forked-hang.html> ([fdo#109271]) +370 similar issues
  *   igt@kms_writeback@writeback-check-output:

     *   shard-apl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl1/igt@kms_writeback@writeback-check-output.html> ([fdo#109271] / [i915#2437]) +2 similar issues
  *   igt@kms_writeback@writeback-invalid-parameters:

     *   shard-skl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl6/igt@kms_writeback@writeback-invalid-parameters.html> ([fdo#109271] / [i915#2437])
  *   igt@nouveau_crc@pipe-d-source-rg:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@nouveau_crc@pipe-d-source-rg.html> ([i915#2530])
  *   igt@perf@polling-parameterized:

     *   shard-tglb: PASS<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-tglb5/igt@perf@polling-parameterized.html> -> FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb6/igt@perf@polling-parameterized.html> ([i915#1542])
  *   igt@perf_pmu@rc6-suspend:

     *   shard-apl: NOTRUN -> DMESG-WARN<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl2/igt@perf_pmu@rc6-suspend.html> ([i915#180])
  *   igt@prime_nv_api@i915_nv_import_vs_close:

     *   shard-tglb: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb7/igt@prime_nv_api@i915_nv_import_vs_close.html> ([fdo#109291])
  *   igt@sysfs_clients@fair-0:

     *   shard-apl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-apl2/igt@sysfs_clients@fair-0.html> ([fdo#109271] / [i915#2994]) +3 similar issues
  *   igt@sysfs_clients@fair-3:

     *   shard-skl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-skl6/igt@sysfs_clients@fair-3.html> ([fdo#109271] / [i915#2994])
  *   igt@sysfs_clients@sema-10:

     *   shard-kbl: NOTRUN -> SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl2/igt@sysfs_clients@sema-10.html> ([fdo#109271] / [i915#2994]) +2 similar issues

Possible fixes

  *   igt@fbdev@nullptr:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-5/igt@fbdev@nullptr.html> ([i915#2582]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-6/igt@fbdev@nullptr.html> +1 similar issue
  *   igt@gem_ctx_persistence@many-contexts:

     *   shard-tglb: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-tglb1/igt@gem_ctx_persistence@many-contexts.html> ([i915#2410]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb2/igt@gem_ctx_persistence@many-contexts.html>
  *   igt@gem_exec_fair@basic-flow@rcs0:

     *   shard-tglb: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-tglb7/igt@gem_exec_fair@basic-flow@rcs0.html> ([i915#2842]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb3/igt@gem_exec_fair@basic-flow@rcs0.html>
  *   igt@gem_exec_fair@basic-pace-solo@rcs0:

     *   shard-kbl: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-kbl3/igt@gem_exec_fair@basic-pace-solo@rcs0.html> ([i915#2842]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl1/igt@gem_exec_fair@basic-pace-solo@rcs0.html>
  *   igt@gem_exec_fair@basic-pace@vcs0:

     *   shard-glk: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-glk1/igt@gem_exec_fair@basic-pace@vcs0.html> ([i915#2842]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-glk6/igt@gem_exec_fair@basic-pace@vcs0.html>
  *   igt@gem_exec_fair@basic-pace@vecs0:

     *   shard-kbl: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-kbl1/igt@gem_exec_fair@basic-pace@vecs0.html> ([fdo#109271]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-kbl2/igt@gem_exec_fair@basic-pace@vecs0.html> +1 similar issue
  *   igt@gem_huc_copy@huc-copy:

     *   shard-tglb: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-tglb6/igt@gem_huc_copy@huc-copy.html> ([i915#2190]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-tglb5/igt@gem_huc_copy@huc-copy.html>
  *   igt@gem_mmap_gtt@cpuset-medium-copy:

     *   {shard-rkl}: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-1/igt@gem_mmap_gtt@cpuset-medium-copy.html> ([i915#2428]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-5/igt@gem_mmap_gtt@cpuset-medium-copy.html>
  *   igt@i915_pm_backlight@fade_with_dpms:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-5/igt@i915_pm_backlight@fade_with_dpms.html> ([i915#3012]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-6/igt@i915_pm_backlight@fade_with_dpms.html>
  *   igt@i915_pm_rpm@modeset-lpsp:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-2/igt@i915_pm_rpm@modeset-lpsp.html> ([i915#1397]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-6/igt@i915_pm_rpm@modeset-lpsp.html> +2 similar issues
  *   igt@i915_pm_rpm@system-suspend-execbuf:

     *   {shard-rkl}: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-6/igt@i915_pm_rpm@system-suspend-execbuf.html> ([fdo#103375]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-2/igt@i915_pm_rpm@system-suspend-execbuf.html> +1 similar issue
  *   igt@kms_big_fb@x-tiled-32bpp-rotate-0:

     *   shard-glk: DMESG-WARN<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-glk3/igt@kms_big_fb@x-tiled-32bpp-rotate-0.html> ([i915#118] / [i915#95]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-glk7/igt@kms_big_fb@x-tiled-32bpp-rotate-0.html> +1 similar issue
  *   igt@kms_big_fb@y-tiled-32bpp-rotate-270:

     *   {shard-rkl}: SKIP<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-5/igt@kms_big_fb@y-tiled-32bpp-rotate-270.html> ([fdo#111614]) -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-rkl-6/igt@kms_big_fb@y-tiled-32bpp-rotate-270.html>
  *   igt@kms_ccs@pipe-b-crc-sprite-planes-basic-y_tiled_gen12_rc_ccs_cc:

     *   {shard-rkl}: FAIL<https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_10295/shard-rkl-2/igt@kms_ccs@pipe-b-crc-sprite-planes-basic-y_tiled_gen12_rc_ccs_cc.html> -> PASS<https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_20499/shard-r> +5 similar issues
diff mbox series

Patch

diff --git a/drivers/gpu/drm/i915/display/intel_ddi.c b/drivers/gpu/drm/i915/display/intel_ddi.c
index 91fd85bee1d27..26a3aa73fcc43 100644
--- a/drivers/gpu/drm/i915/display/intel_ddi.c
+++ b/drivers/gpu/drm/i915/display/intel_ddi.c
@@ -1738,10 +1738,23 @@  static struct intel_shared_dpll *dg1_ddi_get_pll(struct intel_encoder *encoder)
 {
 	struct drm_i915_private *i915 = to_i915(encoder->base.dev);
 	enum phy phy = intel_port_to_phy(i915, encoder->port);
+	enum intel_dpll_id id;
+	u32 val;
 
-	return _cnl_ddi_get_pll(i915, DG1_DPCLKA_CFGCR0(phy),
-				DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_MASK(phy),
-				DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy));
+	val = intel_de_read(i915, DG1_DPCLKA_CFGCR0(phy));
+	val &= DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_MASK(phy);
+	val >>= DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy);
+	id = val;
+
+	/*
+	 * _DG1_DPCLKA0_CFGCR0 maps between DPLL 0 and 1 with one bit for phy A
+	 * and B while _DG1_DPCLKA1_CFGCR0 maps between DPLL 2 and 3 with one
+	 * bit for phy C and D.
+	 */
+	if (phy >= PHY_C)
+		id += DPLL_ID_DG1_DPLL2;
+
+	return intel_get_shared_dpll_by_id(i915, id);
 }
 
 static void icl_ddi_combo_enable_clock(struct intel_encoder *encoder,
diff --git a/drivers/gpu/drm/i915/i915_reg.h b/drivers/gpu/drm/i915/i915_reg.h
index 65c155b141899..16a19239d86dd 100644
--- a/drivers/gpu/drm/i915/i915_reg.h
+++ b/drivers/gpu/drm/i915/i915_reg.h
@@ -10525,7 +10525,6 @@  enum skl_power_gate {
 #define _DG1_DPCLKA1_CFGCR0				0x16C280
 #define _DG1_DPCLKA_PHY_IDX(phy)			((phy) % 2)
 #define _DG1_DPCLKA_PLL_IDX(pll)			((pll) % 2)
-#define _DG1_PHY_DPLL_MAP(phy)				((phy) >= PHY_C ? DPLL_ID_DG1_DPLL2 : DPLL_ID_DG1_DPLL0)
 #define DG1_DPCLKA_CFGCR0(phy)				_MMIO_PHY((phy) / 2, \
 								  _DG1_DPCLKA_CFGCR0, \
 								  _DG1_DPCLKA1_CFGCR0)
@@ -10533,8 +10532,6 @@  enum skl_power_gate {
 #define   DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy)	(_DG1_DPCLKA_PHY_IDX(phy) * 2)
 #define   DG1_DPCLKA_CFGCR0_DDI_CLK_SEL(pll, phy)	(_DG1_DPCLKA_PLL_IDX(pll) << DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy))
 #define   DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_MASK(phy)	(0x3 << DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy))
-#define   DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_DPLL_MAP(clk_sel, phy) \
-	(((clk_sel) >> DG1_DPCLKA_CFGCR0_DDI_CLK_SEL_SHIFT(phy)) + _DG1_PHY_DPLL_MAP(phy))
 
 /* ADLS Clocks */
 #define _ADLS_DPCLKA_CFGCR0			0x164280