mirror of
https://github.com/Ysurac/openmptcprouter.git
synced 2025-02-13 20:01:55 +00:00
72 lines
2.4 KiB
Diff
72 lines
2.4 KiB
Diff
From fa095b2751309a70d42d9d2f2f0881731b090d18 Mon Sep 17 00:00:00 2001
|
|
From: chunhui dai <chunhui.dai@mediatek.com>
|
|
Date: Wed, 31 Oct 2018 16:59:34 +0800
|
|
Subject: [PATCH 44/77] fix boot up for 720 and 480 but 1080
|
|
|
|
1080 plg in/out with ng/ok
|
|
|
|
[ALPSxxxxxxxx]
|
|
|
|
[Detail]
|
|
|
|
[Solution]
|
|
|
|
Change-Id: Icd395eaf635a6cfe03f8f0508ed97ab40cbf6632
|
|
CR-Id:
|
|
Feature:
|
|
---
|
|
drivers/gpu/drm/mediatek/mtk_hdmi_phy.c | 3 +++
|
|
drivers/gpu/drm/mediatek/mtk_hdmi_phy.h | 1 +
|
|
drivers/gpu/drm/mediatek/mtk_mt2701_hdmi_phy.c | 3 ++-
|
|
3 files changed, 6 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/drivers/gpu/drm/mediatek/mtk_hdmi_phy.c b/drivers/gpu/drm/mediatek/mtk_hdmi_phy.c
|
|
index 4ef9c57ffd44..40e08df57f48 100644
|
|
--- a/drivers/gpu/drm/mediatek/mtk_hdmi_phy.c
|
|
+++ b/drivers/gpu/drm/mediatek/mtk_hdmi_phy.c
|
|
@@ -209,6 +209,9 @@ static int mtk_hdmi_phy_probe(struct platform_device *pdev)
|
|
return PTR_ERR(phy_provider);
|
|
}
|
|
|
|
+ if (hdmi_phy->conf->pll_default_off)
|
|
+ hdmi_phy->conf->hdmi_phy_disable_tmds(hdmi_phy);
|
|
+
|
|
return of_clk_add_provider(dev->of_node, of_clk_src_simple_get,
|
|
hdmi_phy->pll);
|
|
}
|
|
diff --git a/drivers/gpu/drm/mediatek/mtk_hdmi_phy.h b/drivers/gpu/drm/mediatek/mtk_hdmi_phy.h
|
|
index f39b1fc66612..a173a27d7a40 100644
|
|
--- a/drivers/gpu/drm/mediatek/mtk_hdmi_phy.h
|
|
+++ b/drivers/gpu/drm/mediatek/mtk_hdmi_phy.h
|
|
@@ -21,6 +21,7 @@ struct mtk_hdmi_phy;
|
|
|
|
struct mtk_hdmi_phy_conf {
|
|
bool tz_disabled;
|
|
+ bool pll_default_off;
|
|
const struct clk_ops *hdmi_phy_clk_ops;
|
|
void (*hdmi_phy_enable_tmds)(struct mtk_hdmi_phy *hdmi_phy);
|
|
void (*hdmi_phy_disable_tmds)(struct mtk_hdmi_phy *hdmi_phy);
|
|
diff --git a/drivers/gpu/drm/mediatek/mtk_mt2701_hdmi_phy.c b/drivers/gpu/drm/mediatek/mtk_mt2701_hdmi_phy.c
|
|
index fcc42dc6ea7f..534bcbc9f3b7 100644
|
|
--- a/drivers/gpu/drm/mediatek/mtk_mt2701_hdmi_phy.c
|
|
+++ b/drivers/gpu/drm/mediatek/mtk_mt2701_hdmi_phy.c
|
|
@@ -116,7 +116,7 @@ static int mtk_hdmi_pll_set_rate(struct clk_hw *hw, unsigned long rate,
|
|
|
|
if (rate <= 64000000)
|
|
pos_div = 3;
|
|
- else if (rate <= 12800000)
|
|
+ else if (rate <= 128000000)
|
|
pos_div = 1;
|
|
else
|
|
pos_div = 1;
|
|
@@ -202,6 +202,7 @@ static void mtk_hdmi_phy_disable_tmds(struct mtk_hdmi_phy *hdmi_phy)
|
|
|
|
struct mtk_hdmi_phy_conf mtk_hdmi_phy_2701_conf = {
|
|
.tz_disabled = true,
|
|
+ .pll_default_off = true,
|
|
.hdmi_phy_clk_ops = &mtk_hdmi_phy_pll_ops,
|
|
.hdmi_phy_enable_tmds = mtk_hdmi_phy_enable_tmds,
|
|
.hdmi_phy_disable_tmds = mtk_hdmi_phy_disable_tmds,
|
|
--
|
|
2.19.1
|
|
|