|
|
@@ -122,6 +122,66 @@ static const struct dw_hdmi_phy_config sun50i_h6_phy_config[] = { |
|
|
{ ~0UL, 0x0000, 0x0000, 0x0000} |
|
|
}; |
|
|
|
|
|
static const struct dw_hdmi_mpll_config sun50i_h616_mpll_cfg[] = { |
|
|
{ |
|
|
27000000, { |
|
|
{ 0x00b3, 0x0003 }, |
|
|
{ 0x2153, 0x0003 }, |
|
|
{ 0x40f3, 0x0003 }, |
|
|
}, |
|
|
}, { |
|
|
74250000, { |
|
|
{ 0x0072, 0x0003 }, |
|
|
{ 0x2145, 0x0003 }, |
|
|
{ 0x4061, 0x0003 }, |
|
|
}, |
|
|
}, { |
|
|
148500000, { |
|
|
{ 0x0051, 0x0003 }, |
|
|
{ 0x214c, 0x0003 }, |
|
|
{ 0x4064, 0x0003 }, |
|
|
}, |
|
|
}, { |
|
|
297000000, { |
|
|
{ 0x0040, 0x0003 }, |
|
|
{ 0x3b4c, 0x0003 }, |
|
|
{ 0x5a64, 0x0003 }, |
|
|
}, |
|
|
}, { |
|
|
594000000, { |
|
|
{ 0x1a40, 0x0003 }, |
|
|
{ 0x3b4c, 0x0003 }, |
|
|
{ 0x5a64, 0x0003 }, |
|
|
}, |
|
|
}, { |
|
|
~0UL, { |
|
|
{ 0x0000, 0x0000 }, |
|
|
{ 0x0000, 0x0000 }, |
|
|
{ 0x0000, 0x0000 }, |
|
|
}, |
|
|
} |
|
|
}; |
|
|
|
|
|
static const struct dw_hdmi_curr_ctrl sun50i_h616_cur_ctr[] = { |
|
|
/* pixelclk bpp8 bpp10 bpp12 */ |
|
|
{ 27000000, { 0x0012, 0x0000, 0x0000 }, }, |
|
|
{ 74250000, { 0x0013, 0x0013, 0x0013 }, }, |
|
|
{ 148500000, { 0x0019, 0x0019, 0x0019 }, }, |
|
|
{ 297000000, { 0x0019, 0x001b, 0x0019 }, }, |
|
|
{ 594000000, { 0x0010, 0x0010, 0x0010 }, }, |
|
|
{ ~0UL, { 0x0000, 0x0000, 0x0000 }, } |
|
|
}; |
|
|
|
|
|
static const struct dw_hdmi_phy_config sun50i_h616_phy_config[] = { |
|
|
/*pixelclk symbol term vlev*/ |
|
|
{ 27000000, 0x8009, 0x0007, 0x02b0}, |
|
|
{ 74250000, 0x8019, 0x0004, 0x0290}, |
|
|
{ 148500000, 0x8019, 0x0004, 0x0290}, |
|
|
{ 297000000, 0x8039, 0x0004, 0x022b}, |
|
|
{ 594000000, 0x8029, 0x0000, 0x008a}, |
|
|
{ ~0UL, 0x0000, 0x0000, 0x0000} |
|
|
}; |
|
|
|
|
|
static int sun8i_hdmi_phy_config_a83t(struct dw_hdmi *hdmi, |
|
|
struct sun8i_hdmi_phy *phy, |
|
|
unsigned int clk_rate) |
|
|
@@ -573,6 +633,13 @@ static const struct sun8i_hdmi_phy_variant sun50i_h6_hdmi_phy = { |
|
|
.phy_init = &sun50i_hdmi_phy_init_h6, |
|
|
}; |
|
|
|
|
|
static const struct sun8i_hdmi_phy_variant sun50i_h616_hdmi_phy = { |
|
|
.cur_ctr = sun50i_h616_cur_ctr, |
|
|
.mpll_cfg = sun50i_h616_mpll_cfg, |
|
|
.phy_cfg = sun50i_h616_phy_config, |
|
|
.phy_init = &sun50i_hdmi_phy_init_h6, |
|
|
}; |
|
|
|
|
|
static const struct of_device_id sun8i_hdmi_phy_of_table[] = { |
|
|
{ |
|
|
.compatible = "allwinner,sun8i-a83t-hdmi-phy", |
|
|
@@ -594,6 +661,10 @@ static const struct of_device_id sun8i_hdmi_phy_of_table[] = { |
|
|
.compatible = "allwinner,sun50i-h6-hdmi-phy", |
|
|
.data = &sun50i_h6_hdmi_phy, |
|
|
}, |
|
|
{ |
|
|
.compatible = "allwinner,sun50i-h616-hdmi-phy", |
|
|
.data = &sun50i_h616_hdmi_phy, |
|
|
}, |
|
|
{ /* sentinel */ } |
|
|
}; |
|
|
|
|
|
|