diff mbox series

[U-Boot,04/16] arm: mach-bcm283x: Define mbox address for BCM2838

Message ID 20190716133803.1174-5-andrei@gherzan.ro
State Superseded
Delegated to: Matthias Brugger
Headers show
Series Raspberry Pi 32/64 support | expand

Commit Message

Andrei Gherzan July 16, 2019, 1:37 p.m. UTC
From: Andrei Gherzan <andrei@gherzan.ro>

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
---
 arch/arm/mach-bcm283x/include/mach/mbox.h | 5 +++++
 1 file changed, 5 insertions(+)

Comments

Matthias Brugger July 16, 2019, 2:22 p.m. UTC | #1
On 16/07/2019 15:37, andrei@gherzan.ro wrote:
> From: Andrei Gherzan <andrei@gherzan.ro>
> 
> Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
> ---
>  arch/arm/mach-bcm283x/include/mach/mbox.h | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/arch/arm/mach-bcm283x/include/mach/mbox.h b/arch/arm/mach-bcm283x/include/mach/mbox.h
> index e3a893e49c..2d711daaa8 100644
> --- a/arch/arm/mach-bcm283x/include/mach/mbox.h
> +++ b/arch/arm/mach-bcm283x/include/mach/mbox.h
> @@ -38,11 +38,16 @@
>  /* Raw mailbox HW */
>  
>  #ifndef CONFIG_BCM2835
> +#ifdef CONFIG_BCM2838
> +#define BCM2835_MBOX_PHYSADDR	0xfe00b880
> +#else

That gets really complicated. I prefer to add CONFIG_BCM283x_BASE or something
like that and then add the offset in the header files.

>  #define BCM2835_MBOX_PHYSADDR	0x3f00b880
> +#endif
>  #else
>  #define BCM2835_MBOX_PHYSADDR	0x2000b880
>  #endif
>  
> +
>  struct bcm2835_mbox_regs {
>  	u32 read;
>  	u32 rsvd0[5];
>
diff mbox series

Patch

diff --git a/arch/arm/mach-bcm283x/include/mach/mbox.h b/arch/arm/mach-bcm283x/include/mach/mbox.h
index e3a893e49c..2d711daaa8 100644
--- a/arch/arm/mach-bcm283x/include/mach/mbox.h
+++ b/arch/arm/mach-bcm283x/include/mach/mbox.h
@@ -38,11 +38,16 @@ 
 /* Raw mailbox HW */
 
 #ifndef CONFIG_BCM2835
+#ifdef CONFIG_BCM2838
+#define BCM2835_MBOX_PHYSADDR	0xfe00b880
+#else
 #define BCM2835_MBOX_PHYSADDR	0x3f00b880
+#endif
 #else
 #define BCM2835_MBOX_PHYSADDR	0x2000b880
 #endif
 
+
 struct bcm2835_mbox_regs {
 	u32 read;
 	u32 rsvd0[5];