All of lore.kernel.org
 help / color / mirror / Atom feed
From: LW@KARO-electronics.de (Lothar Waßmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 2/2] ARM: i.MX25 clk: Use of_clk_init() for DT case
Date: Wed, 25 Jun 2014 09:06:39 +0200	[thread overview]
Message-ID: <20140625090639.7eabbf70@ipc1.ka-ro> (raw)
In-Reply-To: <20140625062423.GH15686@pengutronix.de>

Hi,

Sascha Hauer wrote:
> On Mon, Jun 23, 2014 at 03:25:27PM +0200, Denis Carikli wrote:
[...]
> > @@ -93,134 +91,136 @@ static struct clk *clk[clk_max];
> >  
> >  static int __init __mx25_clocks_init(unsigned long osc_rate)
> >  {
> > +	BUG_ON(!ccm);
> > +
> >  	clk[dummy] = imx_clk_fixed("dummy", 0);
> >  	clk[osc] = imx_clk_fixed("osc", osc_rate);
> > -	clk[mpll] = imx_clk_pllv1("mpll", "osc", ccm(CCM_MPCTL));
> > -	clk[upll] = imx_clk_pllv1("upll", "osc", ccm(CCM_UPCTL));
> > +	clk[mpll] = imx_clk_pllv1("mpll", "osc", CCM_MPCTL);
> > +	clk[upll] = imx_clk_pllv1("upll", "osc", CCM_UPCTL);
> 
> This huge diffstat could be avoided by doing:
> 
> #define ccm(x)	((ccm_base) + (x))
> 
> And passing ccm_base as argument to __mx25_clocks_init.
> 
<nit>the parens around ccm_base are useless</nit>


Lothar Wa?mann
-- 
___________________________________________________________

Ka-Ro electronics GmbH | Pascalstra?e 22 | D - 52076 Aachen
Phone: +49 2408 1402-0 | Fax: +49 2408 1402-10
Gesch?ftsf?hrer: Matthias Kaussen
Handelsregistereintrag: Amtsgericht Aachen, HRB 4996

www.karo-electronics.de | info at karo-electronics.de
___________________________________________________________

  reply	other threads:[~2014-06-25  7:06 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-23 13:25 [PATCH v2 1/2] ARM: dts: i.MX25: Fix gpt timers clocks Denis Carikli
2014-06-23 13:25 ` [PATCH v2 2/2] ARM: i.MX25 clk: Use of_clk_init() for DT case Denis Carikli
2014-06-25  6:24   ` Sascha Hauer
2014-06-25  7:06     ` Lothar Waßmann [this message]
2014-06-25  6:20 ` [PATCH v2 1/2] ARM: dts: i.MX25: Fix gpt timers clocks Sascha Hauer
2014-06-25  6:20 ` Shawn Guo

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=20140625090639.7eabbf70@ipc1.ka-ro \
    --to=lw@karo-electronics.de \
    --cc=linux-arm-kernel@lists.infradead.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 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.