RE: [PATCH 5/7][RFC] OMAP4: Update common omap machine specific sources.

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

 




Regards,
Santosh
 

> -----Original Message-----
> From: Tony Lindgren [mailto:tony@xxxxxxxxxxx] 
> Sent: Wednesday, April 22, 2009 12:07 AM
> To: Shilimkar, Santosh
> Cc: linux-omap@xxxxxxxxxxxxxxx
> Subject: Re: [PATCH 5/7][RFC] OMAP4: Update common omap 
> machine specific sources.
> 
> * Santosh Shilimkar <santosh.shilimkar@xxxxxx> [090421 06:08]:
> > This patch updates the common machine spcific source files 
> for OMAP4430.
> > Few OMAP4 peripherals are common with OMAP3 architecture. 
> Lot of code
> > gets re-used because of this.
> > 
> > Signed-off-by: Santosh Shilimkar <santosh.shilimkar@xxxxxx>
> > ---
> >  arch/arm/mach-omap2/gpmc.c     |    3 ++
> >  arch/arm/mach-omap2/id.c       |    5 +++-
> >  arch/arm/mach-omap2/io.c       |   48 
> ++++++++++++++++++++++++++++++++++++++++
> >  arch/arm/mach-omap2/timer-gp.c |    6 ++++-
> >  4 files changed, 60 insertions(+), 2 deletions(-)
> > 

  
> >  void __init omap2_map_common_io(void)
> >  {
> > @@ -183,6 +225,10 @@ void __init omap2_map_common_io(void)
> >  	iotable_init(omap34xx_io_desc, ARRAY_SIZE(omap34xx_io_desc));
> >  #endif
> >  
> > +#if defined(CONFIG_ARCH_OMAP44XX)
> > +	iotable_init(omap44xx_io_desc, ARRAY_SIZE(omap44xx_io_desc));
> > +#endif
> > +
> 
> This will break multi-omap. The cpu_is_omap44xx() works very early
> during the boot nowadays as the omap2_set_globals_44xx() initializes
> that, so please use that instead.

Looks possible to correct this. But I need to do this for OMAP2 and OMAp3 as well because for both the compile time switch is used. It was done for OMAP2/3 and hence I just maintained same way for OMAP4


/* Normally devicemaps_init() would flush caches and tlb after
> >  	 * mdesc->map_io(), but we must also do it here because 
> of the CPU
> >  	 * revision check below.
> > @@ -198,9 +244,11 @@ void __init omap2_map_common_io(void)
> >  void __init omap2_init_common_hw(struct omap_sdrc_params *sp)
> >  {
> >  	omap2_mux_init();
> > +#ifndef CONFIG_ARCH_OMAP4 /* REVISIT: to avoid build errors */
> >  	pwrdm_init(powerdomains_omap);
> >  	clkdm_init(clockdomains_omap, clkdm_pwrdm_autodeps);
> >  	omap2_clk_init();
> >  	omap2_sdrc_init(sp);
> > +#endif
> >  	gpmc_init();
> >  }
> 
> Please use cpu_is_omap44xx() here too instead of the ifndef.

If I use cpu_is_omap44xx(), then I need to write stub functions under OMAP4 macro. Kevin also suggested to write stubs. So this can be done.

Regards
Santosh--
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