Skip to content

Commit fd67288

Browse files
Yongxing Mouvinodkoul
authored andcommitted
phy: qcom: edp: Unify generic DP/eDP swing and pre-emphasis tables
The current eDP and DP swing/pre-emphasis tables do not match the HPG requirements for the supported platforms, correct the table accordingly. The generic tables which can be shared as follows: DP mode: -sa8775p/sc7280/sc8280xp/x1e80100 -glymur -sc8180x eDP mode(low vdiff): -glymur/sa8775p/sc8280xp/x1e80100 -sc7280 -sc8180x The proper tables for SC8180X and SC7280 will be added in a later patch, since they need separate table. Cc: stable@vger.kernel.org Fixes: f199223 ("phy: qcom: Introduce new eDP PHY driver") Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com> Signed-off-by: Yongxing Mou <yongxing.mou@oss.qualcomm.com> Link: https://patch.msgid.link/20260427-edp_phy-v5-1-3bb876824475@oss.qualcomm.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
1 parent 254f496 commit fd67288

1 file changed

Lines changed: 10 additions & 31 deletions

File tree

drivers/phy/qualcomm/phy-qcom-edp.c

Lines changed: 10 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -116,17 +116,17 @@ struct qcom_edp {
116116
};
117117

118118
static const u8 dp_swing_hbr_rbr[4][4] = {
119-
{ 0x08, 0x0f, 0x16, 0x1f },
119+
{ 0x07, 0x0f, 0x16, 0x1f },
120120
{ 0x11, 0x1e, 0x1f, 0xff },
121121
{ 0x16, 0x1f, 0xff, 0xff },
122122
{ 0x1f, 0xff, 0xff, 0xff }
123123
};
124124

125125
static const u8 dp_pre_emp_hbr_rbr[4][4] = {
126-
{ 0x00, 0x0d, 0x14, 0x1a },
126+
{ 0x00, 0x0e, 0x15, 0x1a },
127127
{ 0x00, 0x0e, 0x15, 0xff },
128128
{ 0x00, 0x0e, 0xff, 0xff },
129-
{ 0x03, 0xff, 0xff, 0xff }
129+
{ 0x04, 0xff, 0xff, 0xff }
130130
};
131131

132132
static const u8 dp_swing_hbr2_hbr3[4][4] = {
@@ -158,7 +158,7 @@ static const u8 edp_swing_hbr_rbr[4][4] = {
158158
};
159159

160160
static const u8 edp_pre_emp_hbr_rbr[4][4] = {
161-
{ 0x05, 0x12, 0x17, 0x1d },
161+
{ 0x05, 0x11, 0x17, 0x1d },
162162
{ 0x05, 0x11, 0x18, 0xff },
163163
{ 0x06, 0x11, 0xff, 0xff },
164164
{ 0x00, 0xff, 0xff, 0xff }
@@ -172,10 +172,10 @@ static const u8 edp_swing_hbr2_hbr3[4][4] = {
172172
};
173173

174174
static const u8 edp_pre_emp_hbr2_hbr3[4][4] = {
175-
{ 0x08, 0x11, 0x17, 0x1b },
176-
{ 0x00, 0x0c, 0x13, 0xff },
177-
{ 0x05, 0x10, 0xff, 0xff },
178-
{ 0x00, 0xff, 0xff, 0xff }
175+
{ 0x0c, 0x15, 0x19, 0x1e },
176+
{ 0x0b, 0x15, 0x19, 0xff },
177+
{ 0x0e, 0x14, 0xff, 0xff },
178+
{ 0x0d, 0xff, 0xff, 0xff }
179179
};
180180

181181
static const struct qcom_edp_swing_pre_emph_cfg edp_phy_swing_pre_emph_cfg = {
@@ -193,27 +193,6 @@ static const u8 edp_phy_vco_div_cfg_v4[4] = {
193193
0x01, 0x01, 0x02, 0x00,
194194
};
195195

196-
static const u8 edp_pre_emp_hbr_rbr_v5[4][4] = {
197-
{ 0x05, 0x11, 0x17, 0x1d },
198-
{ 0x05, 0x11, 0x18, 0xff },
199-
{ 0x06, 0x11, 0xff, 0xff },
200-
{ 0x00, 0xff, 0xff, 0xff }
201-
};
202-
203-
static const u8 edp_pre_emp_hbr2_hbr3_v5[4][4] = {
204-
{ 0x0c, 0x15, 0x19, 0x1e },
205-
{ 0x0b, 0x15, 0x19, 0xff },
206-
{ 0x0e, 0x14, 0xff, 0xff },
207-
{ 0x0d, 0xff, 0xff, 0xff }
208-
};
209-
210-
static const struct qcom_edp_swing_pre_emph_cfg edp_phy_swing_pre_emph_cfg_v5 = {
211-
.swing_hbr_rbr = &edp_swing_hbr_rbr,
212-
.swing_hbr3_hbr2 = &edp_swing_hbr2_hbr3,
213-
.pre_emphasis_hbr_rbr = &edp_pre_emp_hbr_rbr_v5,
214-
.pre_emphasis_hbr3_hbr2 = &edp_pre_emp_hbr2_hbr3_v5,
215-
};
216-
217196
static const u8 edp_phy_aux_cfg_v5[DP_AUX_CFG_SIZE] = {
218197
0x00, 0x13, 0xa4, 0x00, 0x0a, 0x26, 0x0a, 0x03, 0x37, 0x03, 0x02, 0x02, 0x00,
219198
};
@@ -564,7 +543,7 @@ static const struct qcom_edp_phy_cfg sa8775p_dp_phy_cfg = {
564543
.is_edp = false,
565544
.aux_cfg = edp_phy_aux_cfg_v5,
566545
.vco_div_cfg = edp_phy_vco_div_cfg_v4,
567-
.swing_pre_emph_cfg = &edp_phy_swing_pre_emph_cfg_v5,
546+
.swing_pre_emph_cfg = &edp_phy_swing_pre_emph_cfg,
568547
.ver_ops = &qcom_edp_phy_ops_v4,
569548
};
570549

@@ -945,7 +924,7 @@ static const struct phy_ver_ops qcom_edp_phy_ops_v8 = {
945924
static struct qcom_edp_phy_cfg glymur_phy_cfg = {
946925
.aux_cfg = edp_phy_aux_cfg_v8,
947926
.vco_div_cfg = edp_phy_vco_div_cfg_v8,
948-
.swing_pre_emph_cfg = &edp_phy_swing_pre_emph_cfg_v5,
927+
.swing_pre_emph_cfg = &edp_phy_swing_pre_emph_cfg,
949928
.ver_ops = &qcom_edp_phy_ops_v8,
950929
};
951930

0 commit comments

Comments
 (0)