* [PATCH] ARM: OMAP2: fix mailbox init code
@ 2012-02-23 8:53 Ohad Ben-Cohen
2012-02-23 9:18 ` Bedia, Vaibhav
0 siblings, 1 reply; 5+ messages in thread
From: Ohad Ben-Cohen @ 2012-02-23 8:53 UTC (permalink / raw)
To: linux-arm-kernel
Fix this:
arch/arm/mach-omap2/mailbox.c: In function 'omap2_mbox_probe':
arch/arm/mach-omap2/mailbox.c:354: error: 'omap2_mboxes' undeclared (first use in this function)
arch/arm/mach-omap2/mailbox.c:354: error: (Each undeclared identifier is reported only once
arch/arm/mach-omap2/mailbox.c:354: error: for each function it appears in.)
Which happens on CONFIG_ARCH_OMAP2 && !CONFIG_SOC_OMAP2420, due to
missing omap2_mboxes declaration.
In addition, make sure we declare the right mailbox instances for 2430.
Reported-by: Russell King <linux@arm.linux.org.uk>
Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
Cc: Tony Lindgren <tony@atomide.com>
Cc: Hiroshi Doyu <hdoyu@nvidia.com>
Cc: Omar Ramirez Luna <omar.ramirez@ti.com>
---
arch/arm/mach-omap2/mailbox.c | 10 +++++++++-
1 files changed, 9 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-omap2/mailbox.c b/arch/arm/mach-omap2/mailbox.c
index 609ea2d..415a6f1 100644
--- a/arch/arm/mach-omap2/mailbox.c
+++ b/arch/arm/mach-omap2/mailbox.c
@@ -281,8 +281,16 @@ 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 };
+#ifdef CONFIG_ARCH_OMAP2
+struct omap_mbox *omap2_mboxes[] = {
+ &mbox_dsp_info,
+#ifdef CONFIG_SOC_OMAP2420
+ &mbox_iva_info,
+#endif
+ NULL
+};
#endif
#if defined(CONFIG_ARCH_OMAP4)
--
1.7.5.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* [PATCH] ARM: OMAP2: fix mailbox init code
2012-02-23 8:53 [PATCH] ARM: OMAP2: fix mailbox init code Ohad Ben-Cohen
@ 2012-02-23 9:18 ` Bedia, Vaibhav
2012-02-23 16:44 ` Ramirez Luna, Omar
2012-02-23 17:04 ` Ohad Ben-Cohen
0 siblings, 2 replies; 5+ messages in thread
From: Bedia, Vaibhav @ 2012-02-23 9:18 UTC (permalink / raw)
To: linux-arm-kernel
On Thu, Feb 23, 2012 at 14:23:35, Ohad Ben-Cohen wrote:
[...]
>
> Which happens on CONFIG_ARCH_OMAP2 && !CONFIG_SOC_OMAP2420, due to
> missing omap2_mboxes declaration.
>
[...]
>
> -struct omap_mbox *omap2_mboxes[] = { &mbox_dsp_info, &mbox_iva_info, NULL };
> +#ifdef CONFIG_ARCH_OMAP2
> +struct omap_mbox *omap2_mboxes[] = {
> + &mbox_dsp_info,
> +#ifdef CONFIG_SOC_OMAP2420
> + &mbox_iva_info,
> +#endif
> + NULL
> +};
> #endif
>
> #if defined(CONFIG_ARCH_OMAP4)
Instead of adding more #ifs can they be completely removed please?
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH] ARM: OMAP2: fix mailbox init code
2012-02-23 9:18 ` Bedia, Vaibhav
@ 2012-02-23 16:44 ` Ramirez Luna, Omar
2012-02-23 17:04 ` Ohad Ben-Cohen
1 sibling, 0 replies; 5+ messages in thread
From: Ramirez Luna, Omar @ 2012-02-23 16:44 UTC (permalink / raw)
To: linux-arm-kernel
Hi,
On Thu, Feb 23, 2012 at 3:18 AM, Bedia, Vaibhav <vaibhav.bedia@ti.com> wrote:
> On Thu, Feb 23, 2012 at 14:23:35, Ohad Ben-Cohen wrote:
> [...]
>>
>> Which happens on CONFIG_ARCH_OMAP2 && !CONFIG_SOC_OMAP2420, due to
>> missing omap2_mboxes declaration.
>>
> [...]
>>
>> -struct omap_mbox *omap2_mboxes[] = { &mbox_dsp_info, &mbox_iva_info, NULL };
>> +#ifdef CONFIG_ARCH_OMAP2
>> +struct omap_mbox *omap2_mboxes[] = {
>> + ? ? &mbox_dsp_info,
>> +#ifdef CONFIG_SOC_OMAP2420
>> + ? ? &mbox_iva_info,
>> +#endif
>> + ? ? NULL
>> +};
>> ?#endif
>>
>> ?#if defined(CONFIG_ARCH_OMAP4)
>
> Instead of adding more #ifs can they be completely removed please?
I'll rebase/repost this series:
[PATCH 0/7] OMAP: mailbox: removing static declarations
http://comments.gmane.org/gmane.linux.ports.arm.omap/59620
In the meantime I would appreciate comments.
Regards,
Omar
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH] ARM: OMAP2: fix mailbox init code
2012-02-23 9:18 ` Bedia, Vaibhav
2012-02-23 16:44 ` Ramirez Luna, Omar
@ 2012-02-23 17:04 ` Ohad Ben-Cohen
2012-02-23 19:27 ` Tony Lindgren
1 sibling, 1 reply; 5+ messages in thread
From: Ohad Ben-Cohen @ 2012-02-23 17:04 UTC (permalink / raw)
To: linux-arm-kernel
On Thu, Feb 23, 2012 at 11:18 AM, Bedia, Vaibhav <vaibhav.bedia@ti.com> wrote:
> Instead of adding more #ifs can they be completely removed please?
Care to propose something specific (which is viable for the -rc cycle) ?
Thanks,
Ohad.
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH] ARM: OMAP2: fix mailbox init code
2012-02-23 17:04 ` Ohad Ben-Cohen
@ 2012-02-23 19:27 ` Tony Lindgren
0 siblings, 0 replies; 5+ messages in thread
From: Tony Lindgren @ 2012-02-23 19:27 UTC (permalink / raw)
To: linux-arm-kernel
* Ohad Ben-Cohen <ohad@wizery.com> [120223 08:32]:
> On Thu, Feb 23, 2012 at 11:18 AM, Bedia, Vaibhav <vaibhav.bedia@ti.com> wrote:
> > Instead of adding more #ifs can they be completely removed please?
>
> Care to propose something specific (which is viable for the -rc cycle) ?
This is pretty much the minimal change for -rc cycle so I'll apply
this into fixes.
Regards,
Tony
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-02-23 19:27 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-23 8:53 [PATCH] ARM: OMAP2: fix mailbox init code Ohad Ben-Cohen
2012-02-23 9:18 ` Bedia, Vaibhav
2012-02-23 16:44 ` Ramirez Luna, Omar
2012-02-23 17:04 ` Ohad Ben-Cohen
2012-02-23 19:27 ` Tony Lindgren
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).