linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Neil Armstrong <narmstrong@baylibre.com>
To: mturquette@baylibre.com, sboyd@codeaurora.org, carlo@caione.org,
	khilman@baylibre.com
Cc: Neil Armstrong <narmstrong@baylibre.com>,
	linux-clk@vger.kernel.org, linux-amlogic@lists.infradead.org,
	linux-arm-kernel@lists.infradead.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH 2/5] clk: meson-gxbb: Add GP0 PLL init parameters
Date: Mon, 13 Mar 2017 14:26:41 +0100	[thread overview]
Message-ID: <1489411604-18700-3-git-send-email-narmstrong@baylibre.com> (raw)
In-Reply-To: <1489411604-18700-1-git-send-email-narmstrong@baylibre.com>

Tha Amlogic GXBB SoC GP0 PLL needs some vendor provided parameters to be
initializated in the the GP0 control registers before configuring the rate
with the rate table provided parameters.

GXBB GP0 PLL tweaks are also selected to respect the vendor init procedure.

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
---
 drivers/clk/meson/gxbb.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/drivers/clk/meson/gxbb.c b/drivers/clk/meson/gxbb.c
index 1c1ec13..5e1a7dc4 100644
--- a/drivers/clk/meson/gxbb.c
+++ b/drivers/clk/meson/gxbb.c
@@ -352,6 +352,13 @@
 	},
 };
 
+struct pll_params_table gxbb_gp0_params_table[] = {
+	PLL_PARAM(HHI_GP0_PLL_CNTL, 0x6a000228),
+	PLL_PARAM(HHI_GP0_PLL_CNTL2, 0x69c80000),
+	PLL_PARAM(HHI_GP0_PLL_CNTL3, 0x0a5590c4),
+	PLL_PARAM(HHI_GP0_PLL_CNTL4, 0x0000500d),
+};
+
 static struct meson_clk_pll gxbb_gp0_pll = {
 	.m = {
 		.reg_off = HHI_GP0_PLL_CNTL,
@@ -368,6 +375,12 @@
 		.shift   = 16,
 		.width   = 2,
 	},
+	.params = {
+		.params_table = gxbb_gp0_params_table,
+		.params_count =	ARRAY_SIZE(gxbb_gp0_params_table),
+		.no_init_reset = true,
+		.unreset_for_lock = true,
+	},
 	.rate_table = gp0_pll_rate_table,
 	.rate_count = ARRAY_SIZE(gp0_pll_rate_table),
 	.lock = &clk_lock,
-- 
1.9.1

  parent reply	other threads:[~2017-03-13 13:28 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-13 13:26 [PATCH 0/5] clk: meson: Fix GXBB and GXL/GXM GP0 PLL Neil Armstrong
2017-03-13 13:26 ` [PATCH 1/5] clk: meson: Add support for parameters for specific PLLs Neil Armstrong
2017-03-21 23:43   ` Michael Turquette
2017-03-22  9:17     ` Neil Armstrong
2017-03-22 10:23     ` Neil Armstrong
2017-03-13 13:26 ` Neil Armstrong [this message]
2017-03-13 13:26 ` [PATCH 3/5] clk: meson-gxbb: Add GXL/GXM GP0 Variant Neil Armstrong
2017-03-21 23:49   ` Michael Turquette
2017-03-22  9:22     ` Neil Armstrong
2017-03-23  1:40       ` Michael Turquette
2017-03-13 13:26 ` [PATCH 4/5] clk: meson-gxbb: Expose GP0 dt-bindings clock id Neil Armstrong
2017-03-13 13:26 ` [PATCH 5/5] dt-bindings: clock: gxbb-clkc: Add GXL compatible variant Neil Armstrong
2017-03-20 21:17   ` Rob Herring

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1489411604-18700-3-git-send-email-narmstrong@baylibre.com \
    --to=narmstrong@baylibre.com \
    --cc=carlo@caione.org \
    --cc=khilman@baylibre.com \
    --cc=linux-amlogic@lists.infradead.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=sboyd@codeaurora.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).