From mboxrd@z Thu Jan 1 00:00:00 1970 From: serveralex@gmail.com (=?utf-8?Q?Alexander_M=C3=BCller?=) Date: Thu, 14 Jul 2016 19:09:33 +0200 Subject: [PATCH v2 6/7] gxbb: clk: Move MESON_GATE macro to gxbb In-Reply-To: <146844555421.73491.17534974282265619018@resonance> References: <1468432181-9550-1-git-send-email-serveralex@gmail.com> <1468432181-9550-7-git-send-email-serveralex@gmail.com> <146844555421.73491.17534974282265619018@resonance> Message-ID: <0F4FC964-B9DE-4880-AF38-469A52FE24D2@gmail.com> To: linus-amlogic@lists.infradead.org List-Id: linus-amlogic.lists.infradead.org Hi Mike, What about the clk name set by the macro MESON_GATE (#_name)? That would change too and I guess that's not desired here. Regards, Alex > On 13 Jul 2016, at 23:32, Michael Turquette wrote: > > Hi Alexander, > > Quoting Alexander M?ller (2016-07-13 10:49:40) >> Signed-off-by: Alexander M?ller >> --- >> drivers/clk/meson/clkc.h | 14 ---- >> drivers/clk/meson/gxbb.c | 176 +++++++++++++++++++++++++---------------------- >> 2 files changed, 95 insertions(+), 95 deletions(-) >> >> diff --git a/drivers/clk/meson/clkc.h b/drivers/clk/meson/clkc.h >> index 53326c3..061a01e 100644 >> --- a/drivers/clk/meson/clkc.h >> +++ b/drivers/clk/meson/clkc.h >> @@ -97,20 +97,6 @@ struct meson_clk_mpll { >> spinlock_t *lock; >> }; >> >> -#define MESON_GATE(_name, _reg, _bit) \ >> -struct clk_gate gxbb_##_name = { \ > > Please leave this macro in clkc.h, but change the above line to: > > #define MESON_GATE(_name, _reg, _bit) \ > struct clk_gate _name = { \ > > Note that gxbb_##_name is replaced with _name. I should have done it > like this from the beginning but it's a bit of a brain fart. > >> /* Everything Else (EE) domain gates */ >> -static MESON_GATE(ddr, HHI_GCLK_MPEG0, 0); > > Then reflow the above gxbb gate clock like so: > > static MESON_GATE(gxbb_ddr, HHI_GCLK_MPEG0, 0); > > Then you can re-use the same macro in your meson8b driver by prefixing > all of your gate clocks with "meson8b_". > > Regards, > Mike