<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div><div class="h5"><br>
> > > > ><br>
> > > > > +struct cpu_wp *(*get_cpu_wp)(int *wp);<br>
> > > > > +<br>
> > > ><br>
> > > > This is not needed.<br>
> > > ><br>
> > > This is needed, otherwise it does not pass compile.<br>
> ><br>
> > This hunk is the only change to arch/arm/mach-mx5/cpu.c and get_cpu_wp<br>
> > is introduced with this patch, so how can this break compilation?<br>
> > Also, you should move this to a header file. Otherwise you risk of<br>
> > having multiple (and possibly different) declarations of the same<br>
> > function which can lead to hard to find bugs.<br>
> ><br>
> IMHO, get_cpu_wp is definition rather than a declaration and without it<br>
> there will be errors in link phase. its declaration is in<br>
> arch/arm/plat-mxc/include/mach/mxc.h.<br>
<br>
</div></div>Of course, you are right, my bad. Isn't this function common to al<br>
i.MXs? In this case it should be somewhere in plat-mxc.<br>
Anyway, it seems very odd to me to provide a global function pointer<br>
which gets overwritten by the boards. For me it is more logical to<br>
provide a mxc_register_workpoints() function along with a<br>
mxc_for_each_workpoint() iterator.<br>
<div><div></div><div class="h5"><br>
</div></div></blockquote></div>About this, I am thinking move the global function pointer to plat-mxc/cpufreq.c and add protection before call the function pointer. Anyway, it is just about provide cpu operating points to cpufreq driver, right? Even, mxc_register_workpoints() has to go some where in cpufreq.c and export a declaration in a head file, also it needs to be called before cpufreq initialization. IMO, it's merely a preference of individuals. No offence about that, correct me:)