All of lore.kernel.org
 help / color / mirror / Atom feed
From: Michael Turquette <mturquette@baylibre.com>
To: linux-clk@vger.kernel.org
Cc: linux-amlogic@lists.infradead.org, khilman@baylibre.com,
	carlo@endlessm.com, victor.wan@amlogic.com,
	jerry.cao@amlogic.com, xing.xu@amlogic.com
Subject: [PATCH 1/7] clk: meson: add peripheral gate macro
Date: Thu,  9 Jun 2016 17:32:48 -0700	[thread overview]
Message-ID: <1465518774-26924-2-git-send-email-mturquette@baylibre.com> (raw)
In-Reply-To: <1465518774-26924-1-git-send-email-mturquette@baylibre.com>

There are a series of peripheral and system gate clocks that fan out
from the clk81 signal. Add a helper macro to statically initialize these
gate clocks.

Signed-off-by: Michael Turquette <mturquette@baylibre.com>
---
 drivers/clk/meson/clkc.h | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/drivers/clk/meson/clkc.h b/drivers/clk/meson/clkc.h
index f3f3961..9436932 100644
--- a/drivers/clk/meson/clkc.h
+++ b/drivers/clk/meson/clkc.h
@@ -73,6 +73,20 @@ struct meson_clk_cpu {
 int meson_clk_cpu_notifier_cb(struct notifier_block *nb, unsigned long event,
 		void *data);
 
+#define MESON_GATE(_name, _reg, _bit)					\
+struct clk_gate gxbb_##_name = { 						\
+	.reg = (void __iomem *) _reg, 					\
+	.bit_idx = (_bit), 						\
+	.lock = &clk_lock,						\
+	.hw.init = &(struct clk_init_data) { 				\
+		.name = #_name,					\
+		.ops = &clk_gate_ops,					\
+		.parent_names = (const char *[]){ "clk81" },		\
+		.num_parents = 1,					\
+		.flags = (CLK_SET_RATE_PARENT | CLK_IGNORE_UNUSED), 	\
+	},								\
+};
+
 /* clk_ops */
 extern const struct clk_ops meson_clk_pll_ro_ops;
 extern const struct clk_ops meson_clk_pll_ops;
-- 
2.1.4

WARNING: multiple messages have this Message-ID (diff)
From: mturquette@baylibre.com (Michael Turquette)
To: linus-amlogic@lists.infradead.org
Subject: [PATCH 1/7] clk: meson: add peripheral gate macro
Date: Thu,  9 Jun 2016 17:32:48 -0700	[thread overview]
Message-ID: <1465518774-26924-2-git-send-email-mturquette@baylibre.com> (raw)
In-Reply-To: <1465518774-26924-1-git-send-email-mturquette@baylibre.com>

There are a series of peripheral and system gate clocks that fan out
from the clk81 signal. Add a helper macro to statically initialize these
gate clocks.

Signed-off-by: Michael Turquette <mturquette@baylibre.com>
---
 drivers/clk/meson/clkc.h | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/drivers/clk/meson/clkc.h b/drivers/clk/meson/clkc.h
index f3f3961..9436932 100644
--- a/drivers/clk/meson/clkc.h
+++ b/drivers/clk/meson/clkc.h
@@ -73,6 +73,20 @@ struct meson_clk_cpu {
 int meson_clk_cpu_notifier_cb(struct notifier_block *nb, unsigned long event,
 		void *data);
 
+#define MESON_GATE(_name, _reg, _bit)					\
+struct clk_gate gxbb_##_name = { 						\
+	.reg = (void __iomem *) _reg, 					\
+	.bit_idx = (_bit), 						\
+	.lock = &clk_lock,						\
+	.hw.init = &(struct clk_init_data) { 				\
+		.name = #_name,					\
+		.ops = &clk_gate_ops,					\
+		.parent_names = (const char *[]){ "clk81" },		\
+		.num_parents = 1,					\
+		.flags = (CLK_SET_RATE_PARENT | CLK_IGNORE_UNUSED), 	\
+	},								\
+};
+
 /* clk_ops */
 extern const struct clk_ops meson_clk_pll_ro_ops;
 extern const struct clk_ops meson_clk_pll_ops;
-- 
2.1.4

  reply	other threads:[~2016-06-10  0:32 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-06-10  0:32 [PATCH 0/7] Add support for AmLogic GXBB clock controller Michael Turquette
2016-06-10  0:32 ` Michael Turquette
2016-06-10  0:32 ` Michael Turquette [this message]
2016-06-10  0:32   ` [PATCH 1/7] clk: meson: add peripheral gate macro Michael Turquette
2016-06-10  0:32 ` [PATCH 2/7] clk: meson: add mpll support Michael Turquette
2016-06-10  0:32   ` Michael Turquette
2016-06-10  0:32 ` [PATCH 3/7] clk: meson: fractional pll support Michael Turquette
2016-06-10  0:32   ` Michael Turquette
2016-06-10  0:32 ` [PATCH 4/7] clk: gxbb: Document bindings for the GXBB clock controller Michael Turquette
2016-06-10  0:32   ` Michael Turquette
2016-06-10  0:32 ` [PATCH 5/7] clk: gxbb: add AmLogic GXBB clk controller driver Michael Turquette
2016-06-10  0:32   ` Michael Turquette
2016-06-10  0:32 ` [PATCH 6/7] arm64: amlogic: select gxbb clk driver Michael Turquette
2016-06-10  0:32   ` Michael Turquette
2016-06-10  0:32 ` [PATCH 7/7] arm64: dts: gxbb clock controller Michael Turquette
2016-06-10  0:32   ` Michael Turquette
2016-06-14 19:01   ` Kevin Hilman
2016-06-14 19:01     ` Kevin Hilman
2016-06-15  1:41     ` Michael Turquette
2016-06-15  1:41       ` Michael Turquette
2016-06-10  9:12 ` [PATCH 0/7] Add support for AmLogic GXBB " Neil Armstrong
2016-06-13 17:55   ` Kevin Hilman
2016-06-14  5:02     ` Neil Armstrong
2016-06-14 18:59 ` Kevin Hilman
2016-06-14 18:59   ` Kevin Hilman
2016-06-15  1:41   ` Michael Turquette
2016-06-15  1:41     ` Michael Turquette

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=1465518774-26924-2-git-send-email-mturquette@baylibre.com \
    --to=mturquette@baylibre.com \
    --cc=carlo@endlessm.com \
    --cc=jerry.cao@amlogic.com \
    --cc=khilman@baylibre.com \
    --cc=linux-amlogic@lists.infradead.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=victor.wan@amlogic.com \
    --cc=xing.xu@amlogic.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.