Skip to content

Commit f9d4185

Browse files
committed
drm/i915/cx0_phy: Fix C10 pll programming sequence
According to spec VDR_CUSTOM_WIDTH register gets programmed after pll specific VDR registers and TX Lane programming registers are done. Moreover we only program into C10_VDR_CONTROL1 to update config and setup master lane once all VDR registers are written into. Bspec: 67636 Fixes: 51390cc ("drm/i915/mtl: Add Support for C10 PHY message bus and pll programming") Signed-off-by: Suraj Kandpal <suraj.kandpal@intel.com> Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20241216181554.2861381-1-suraj.kandpal@intel.com
1 parent 1e28fbf commit f9d4185

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

drivers/gpu/drm/i915/display/intel_cx0_phy.c

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2117,14 +2117,6 @@ static void intel_c10_pll_program(struct intel_display *display,
21172117
0, C10_VDR_CTRL_MSGBUS_ACCESS,
21182118
MB_WRITE_COMMITTED);
21192119

2120-
/* Custom width needs to be programmed to 0 for both the phy lanes */
2121-
intel_cx0_rmw(encoder, INTEL_CX0_BOTH_LANES, PHY_C10_VDR_CUSTOM_WIDTH,
2122-
C10_VDR_CUSTOM_WIDTH_MASK, C10_VDR_CUSTOM_WIDTH_8_10,
2123-
MB_WRITE_COMMITTED);
2124-
intel_cx0_rmw(encoder, INTEL_CX0_BOTH_LANES, PHY_C10_VDR_CONTROL(1),
2125-
0, C10_VDR_CTRL_UPDATE_CFG,
2126-
MB_WRITE_COMMITTED);
2127-
21282120
/* Program the pll values only for the master lane */
21292121
for (i = 0; i < ARRAY_SIZE(pll_state->pll); i++)
21302122
intel_cx0_write(encoder, INTEL_CX0_LANE0, PHY_C10_VDR_PLL(i),
@@ -2134,6 +2126,10 @@ static void intel_c10_pll_program(struct intel_display *display,
21342126
intel_cx0_write(encoder, INTEL_CX0_LANE0, PHY_C10_VDR_CMN(0), pll_state->cmn, MB_WRITE_COMMITTED);
21352127
intel_cx0_write(encoder, INTEL_CX0_LANE0, PHY_C10_VDR_TX(0), pll_state->tx, MB_WRITE_COMMITTED);
21362128

2129+
/* Custom width needs to be programmed to 0 for both the phy lanes */
2130+
intel_cx0_rmw(encoder, INTEL_CX0_BOTH_LANES, PHY_C10_VDR_CUSTOM_WIDTH,
2131+
C10_VDR_CUSTOM_WIDTH_MASK, C10_VDR_CUSTOM_WIDTH_8_10,
2132+
MB_WRITE_COMMITTED);
21372133
intel_cx0_rmw(encoder, INTEL_CX0_LANE0, PHY_C10_VDR_CONTROL(1),
21382134
0, C10_VDR_CTRL_MASTER_LANE | C10_VDR_CTRL_UPDATE_CFG,
21392135
MB_WRITE_COMMITTED);

0 commit comments

Comments
 (0)