From: Tony Lindgren <tony@atomide.com>
To: Jean Pihet <jean.pihet@newoldbits.com>
Cc: linux-omap@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
Anton Vorontsov <cbou@mail.ru>, Kevin Hilman <khilman@ti.com>,
J Keerthy <j-keerthy@ti.com>, Jean Pihet <j-pihet@ti.com>
Subject: Re: [PATCH 2/2] ARM: OMAP: SmartReflex: pass device dependent data via platform data
Date: Fri, 21 Sep 2012 12:07:11 -0700 [thread overview]
Message-ID: <20120921190710.GG28835@atomide.com> (raw)
In-Reply-To: <CAORVsuXS=zk6SEqo=qhyaAFyYQbhLA8CY9TTMMhEQtMZf7p21Q@mail.gmail.com>
* Jean Pihet <jean.pihet@newoldbits.com> [120920 23:31]:
> On Fri, Sep 21, 2012 at 12:15 AM, Tony Lindgren <tony@atomide.com> wrote:
> >
> > You should be able to make this even simpler and not have to pass
> > the clock name around at all. Just do:
> >
> > syc_ck = clk_get(NULL, "fck);
> > ...
> The problem is that the system has multiple instances of the
> smartreflex module, each having its own fck. On OMAP3/4 the fck's are
> derived from sys_clk via muxes and latches.
> The proposed code uses the fck's as defined in the .main_clk field of
> the hwmod entries, so that it takes the muxes and latches into account
> and also has a consistent clock naming.
If the same system has multiple clocks, then you could have them matched
by the smartreflex driver instance number.
Or if you mean different source clocks for various omaps, then
you just need to set multiple aliases for those clocks.
> > In the driver, and add the necessary entries to the clock alias
> > table. That way it's up to the SoC to set up the necessary clocks
> > and the driver stays generic.
> Got it. The only solution would be to use an unique fck for all
> smartreflex modules in all configurations. Is that acceptable?
Hmm maybe I don't follow you, but sounds like you just need to
use the driver instance like we do for timers:
$ grep omap_timer arch/arm/mach-omap2/clock*data*.c
arch/arm/mach-omap2/clock44xx_data.c: CLK("omap_timer.1", "timer_sys_ck", &sys_clkin_ck, CK_443X),
arch/arm/mach-omap2/clock44xx_data.c: CLK("omap_timer.2", "timer_sys_ck", &sys_clkin_ck, CK_443X),
arch/arm/mach-omap2/clock44xx_data.c: CLK("omap_timer.3", "timer_sys_ck", &sys_clkin_ck, CK_443X),
...
If you need multiple clocks for a driver instance, then they
typically are just "fck" and "ick".
Regards,
Tony
next prev parent reply other threads:[~2012-09-21 19:07 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-20 14:47 [PATCH 0/2] ARM: OMAP: SmartReflex: pass device dependent data via platform data Jean Pihet
2012-09-20 14:47 ` [PATCH 1/2] ARM: OMAP: SmartReflex: fix error path in init function Jean Pihet
2012-09-20 14:47 ` [PATCH 2/2] ARM: OMAP: SmartReflex: pass device dependent data via platform data Jean Pihet
2012-09-20 22:15 ` Tony Lindgren
2012-09-21 6:30 ` Jean Pihet
2012-09-21 19:07 ` Tony Lindgren [this message]
2012-09-24 14:10 ` Jean Pihet
2012-09-24 14:16 ` [PATCH 0/2] " Jean Pihet
2012-09-24 14:16 ` [PATCH 1/2] ARM: OMAP: SmartReflex: fix error path in init function Jean Pihet
2012-10-02 21:59 ` Kevin Hilman
2012-09-24 14:16 ` [PATCH 2/2] ARM: OMAP: SmartReflex: pass device dependent data via platform data Jean Pihet
2012-10-02 22:21 ` Kevin Hilman
2012-10-03 13:05 ` Jean Pihet
2012-10-03 13:32 ` jean.pihet
2012-10-03 14:29 ` Kevin Hilman
2012-10-03 15:51 ` Jean Pihet
-- strict thread matches above, loose matches on Subject: below --
2012-10-03 15:47 [PATCH 0/2] " jean.pihet
2012-10-03 15:47 ` [PATCH 2/2] " jean.pihet
2012-10-04 16:47 [PATCH 0/2] " jean.pihet
2012-10-04 16:47 ` [PATCH 2/2] " jean.pihet
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=20120921190710.GG28835@atomide.com \
--to=tony@atomide.com \
--cc=cbou@mail.ru \
--cc=j-keerthy@ti.com \
--cc=j-pihet@ti.com \
--cc=jean.pihet@newoldbits.com \
--cc=khilman@ti.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-omap@vger.kernel.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).