On Wed, Feb 22, 2012 at 09:55:56PM +0200, Ohad Ben-Cohen wrote: > On Wed, Feb 22, 2012 at 7:58 PM, Tony Lindgren <tony@xxxxxxxxxxx> wrote: > > 2430 is like omap3 for the mailbox. > > Gotcha, thanks. > > This one below isn't pretty, but it should satisfy all build > permutations and still be correct hw-wise. > > If it looks good to you I'll submit it properly. > > diff --git a/arch/arm/mach-omap2/mailbox.c b/arch/arm/mach-omap2/mailbox.c > index 609ea2d..6f0f228 100644 > --- a/arch/arm/mach-omap2/mailbox.c > +++ b/arch/arm/mach-omap2/mailbox.c > @@ -281,8 +281,14 @@ static struct omap_mbox mbox_iva_info = { > .ops = &omap2_mbox_ops, > .priv = &omap2_mbox_iva_priv, > }; > +#endif > > -struct omap_mbox *omap2_mboxes[] = { &mbox_dsp_info, &mbox_iva_info, NULL }; > +#if defined(CONFIG_ARCH_OMAP2) > +struct omap_mbox *omap2_mboxes[] = { &mbox_dsp_info, > +#if defined(CONFIG_SOC_OMAP2420) > + &mbox_iva_info, > +#endif > + NULL }; Better would be: +#ifdef CONFIG_ARCH_OMAP2 +struct omap_mbox *omap2_mboxes[] = { + &mbox_dsp_info, +#ifdef CONFIG_SOC_OMAP2420 + &mbox_iva_info, +#endif + NULL +}; #endif There's no point in typing any more than you have to with #if defined(). The only place where using #if defined() makes sense is if you want to subsequently do #elif defined xxx because there isn't a #elifdef. -- 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