Hi Sascha,<div><br></div><div>I had sent out v3 patch before the your last comments.</div><div>I noticed how davinci is doing, but some SOCs like omap, they also do it in another way like my code.</div><div>However, if you prefer the way davinci is doing, I will redo it. Please confirm.</div>
<div><br></div><div>thanks</div><div>Yong<br><br><div class="gmail_quote">On Thu, Feb 17, 2011 at 11:54 AM, Sascha Hauer <span dir="ltr"><<a href="mailto:s.hauer@pengutronix.de">s.hauer@pengutronix.de</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div><div></div><div class="h5">On Thu, Feb 17, 2011 at 09:18:11AM +0100, Yong Shen wrote:<br>
> ><br>
> ><br>
> > > + return 0;<br>
> > > +}<br>
> > > +<br>
> > > +late_initcall(imx_cpuidle_init);<br>
> ><br>
> > We have a late_initcall here which needs to be protected from other<br>
> > cpus. On the other hand we depend on board code calling<br>
> > imx_cpuidle_board_params() before this initcall. I think the board code<br>
> > should call a imx_cpuidle_init(struct imx_cpuidle_params<br>
> > *cpuidle_params) instead which makes the flow of execution more clear.<br>
> ><br>
> > imx_cpuidle_init can not be called directly in board code, since it is too<br>
> early to register cpuidle driver and device which depend on some other<br>
> system resource.<br>
<br>
</div></div>I see. Maybe we should make this a platform driver then like for example<br>
davinci does.<br>
<font color="#888888"><br>
Sascha<br>
</font><div><div></div><div class="h5"><br>
--<br>
Pengutronix e.K. | |<br>
Industrial Linux Solutions | <a href="http://www.pengutronix.de/" target="_blank">http://www.pengutronix.de/</a> |<br>
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |<br>
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |<br>
</div></div></blockquote></div><br></div>