linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [v1] drm/msm/dsi/pll: call vco set rate explicitly
@ 2020-02-06  9:12 Harigovindan P
  2020-02-06 14:59 ` [Freedreno] " Jeffrey Hugo
  0 siblings, 1 reply; 11+ messages in thread
From: Harigovindan P @ 2020-02-06  9:12 UTC (permalink / raw)
  To: dri-devel, linux-arm-msm, freedreno, devicetree
  Cc: Harigovindan P, linux-kernel, robdclark, seanpaul, hoegsberg,
	kalyan_t, nganji

For a given byte clock, if VCO recalc value is exactly same as
vco set rate value, vco_set_rate does not get called assuming
VCO is already set to required value. But Due to GDSC toggle,
VCO values are erased in the HW. To make sure VCO is programmed
correctly, we forcefully call set_rate from vco_prepare.

Signed-off-by: Harigovindan P <harigovi@codeaurora.org>
---

Changes in v1:
	- Calling set rate from vco_prepare

 drivers/gpu/drm/msm/dsi/pll/dsi_pll_10nm.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/gpu/drm/msm/dsi/pll/dsi_pll_10nm.c b/drivers/gpu/drm/msm/dsi/pll/dsi_pll_10nm.c
index 1c89454..6ac04fc 100644
--- a/drivers/gpu/drm/msm/dsi/pll/dsi_pll_10nm.c
+++ b/drivers/gpu/drm/msm/dsi/pll/dsi_pll_10nm.c
@@ -411,6 +411,12 @@ static int dsi_pll_10nm_vco_prepare(struct clk_hw *hw)
 	if (pll_10nm->slave)
 		dsi_pll_enable_pll_bias(pll_10nm->slave);
 
+	rc = dsi_pll_10nm_vco_set_rate(hw,pll_10nm->vco_current_rate, 0);
+	if (rc) {
+		pr_err("vco_set_rate failed, rc=%d\n", rc);
+		return rc;
+	}
+
 	/* Start PLL */
 	pll_write(pll_10nm->phy_cmn_mmio + REG_DSI_10nm_PHY_CMN_PLL_CNTRL,
 		  0x01);
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2020-02-17 10:42 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-02-06  9:12 [v1] drm/msm/dsi/pll: call vco set rate explicitly Harigovindan P
2020-02-06 14:59 ` [Freedreno] " Jeffrey Hugo
2020-02-07 12:38   ` harigovi
2020-02-07 14:10     ` Jeffrey Hugo
2020-02-11  5:58       ` harigovi
2020-02-11 15:44         ` Rob Clark
2020-02-11 15:59           ` Jeffrey Hugo
2020-02-12  0:28             ` Rob Clark
2020-02-12  4:05               ` Jeffrey Hugo
2020-02-12  5:10                 ` Rob Clark
2020-02-17 10:42                   ` harigovi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).