Re: [PATCH 08/10] OMAP: split plat-omap/common.c

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



* Varadarajan, Charulatha <charu@xxxxxx> [101004 01:20]:
> Paul,
> 
> <<snip>>
> 
> > 
> > > > +static int __init omap_init_clocksource_32k(void)
> > > > +{
> > > > +	static char err[] __initdata = KERN_ERR
> > > > +			"%s: can't register clocksource!\n";
> > > > +
> > > > +	if (cpu_is_omap16xx() || cpu_class_is_omap2()) {
> > > > +		struct clk *sync_32k_ick;
> > > > +
> > > > +		if (cpu_is_omap16xx())
> > >
> > > Avoid cpu_is* checks in plat-omap.
> > 
> > OK, I'll bite.  Why?
> 
> I think this is being looked for all the new code introduced
> in plat-omap layer for the following reasons:
> Adding cpu-is-* checks makes code unmaintainable going fwd.
> plat-omap layer needs to handle common code for all omap platforms.
> 
> This was raised for GPIO driver because of which, there was a
> requirement to clean-up the gpio driver.
> 
> Is this stand changed? Are cpu_is* checks allowed in plat-omap?

We should only need to do cpu_is* checks in arch/arm/mach-omap2,
and only in few places during the init.

However, this patch series moves around the existing code to
avoid having oma2plus specific code be in plat-omap.

Again, further patches can be done easily on this.

Tony
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux