Re: [RESUBMIT][PATCH 3/7 v2] OMAP4: Update common omap platform headers.

2009-05-19 Thread Tony Lindgren
* Santosh Shilimkar  [090519 06:32]:
> (patch is rebased on 2.6.30-rc6. The older version was based on 2.6.30-rc2)
> 
> This patch updates the common platform headers files for OMAP4430.
> On OMAP4, GIC is used instead of INTC, hence all the private peripheral
> interrupts are shifted by an offset of 32. So if the hardcoding is not
> done for IRQ lines in drivers, then this change won't impact any driver.
> 
> Signed-off-by: Santosh Shilimkar 
> ---
>  arch/arm/plat-omap/include/mach/clock.h   |8 ++-
>  arch/arm/plat-omap/include/mach/common.h  |1 +
>  arch/arm/plat-omap/include/mach/control.h |7 +-
>  arch/arm/plat-omap/include/mach/debug-macro.S |2 +-
>  arch/arm/plat-omap/include/mach/dma.h |1 +
>  arch/arm/plat-omap/include/mach/entry-macro.S |   46 -
>  arch/arm/plat-omap/include/mach/io.h  |   37 ++
>  arch/arm/plat-omap/include/mach/irqs.h|   89 
> +
>  arch/arm/plat-omap/include/mach/memory.h  |3 +-
>  arch/arm/plat-omap/include/mach/serial.h  |   16 -
>  10 files changed, 198 insertions(+), 12 deletions(-)
> 
> diff --git a/arch/arm/plat-omap/include/mach/clock.h 
> b/arch/arm/plat-omap/include/mach/clock.h
> index 073a2c5..058a808 100644
> --- a/arch/arm/plat-omap/include/mach/clock.h
> +++ b/arch/arm/plat-omap/include/mach/clock.h
> @@ -22,7 +22,8 @@ struct clkops {
>   void(*disable)(struct clk *);
>  };
>  
> -#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
> +#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3) || \
> + defined(CONFIG_ARCH_OMAP4)
>  
>  struct clksel_rate {
>   u32 val;
> @@ -51,7 +52,7 @@ struct dpll_data {
>   u8  max_divider;
>   u32 max_tolerance;
>   u16 max_multiplier;
> -#  if defined(CONFIG_ARCH_OMAP3)
> +#  if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
>   u8  modes;
>   void __iomem*autoidle_reg;
>   void __iomem*idlest_reg;

Please get rid of the extra spaces in the #if defined above while at it.

Regards,

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


Re: [RESUBMIT][PATCH 3/7 v2] OMAP4: Update common omap platform headers.

2009-05-19 Thread Santosh Shilimkar
(patch is rebased on 2.6.30-rc6. The older version was based on 2.6.30-rc2)

This patch updates the common platform headers files for OMAP4430.
On OMAP4, GIC is used instead of INTC, hence all the private peripheral
interrupts are shifted by an offset of 32. So if the hardcoding is not
done for IRQ lines in drivers, then this change won't impact any driver.

Signed-off-by: Santosh Shilimkar 
---
 arch/arm/plat-omap/include/mach/clock.h   |8 ++-
 arch/arm/plat-omap/include/mach/common.h  |1 +
 arch/arm/plat-omap/include/mach/control.h |7 +-
 arch/arm/plat-omap/include/mach/debug-macro.S |2 +-
 arch/arm/plat-omap/include/mach/dma.h |1 +
 arch/arm/plat-omap/include/mach/entry-macro.S |   46 -
 arch/arm/plat-omap/include/mach/io.h  |   37 ++
 arch/arm/plat-omap/include/mach/irqs.h|   89 +
 arch/arm/plat-omap/include/mach/memory.h  |3 +-
 arch/arm/plat-omap/include/mach/serial.h  |   16 -
 10 files changed, 198 insertions(+), 12 deletions(-)

diff --git a/arch/arm/plat-omap/include/mach/clock.h 
b/arch/arm/plat-omap/include/mach/clock.h
index 073a2c5..058a808 100644
--- a/arch/arm/plat-omap/include/mach/clock.h
+++ b/arch/arm/plat-omap/include/mach/clock.h
@@ -22,7 +22,8 @@ struct clkops {
void(*disable)(struct clk *);
 };
 
-#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
+#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3) || \
+   defined(CONFIG_ARCH_OMAP4)
 
 struct clksel_rate {
u32 val;
@@ -51,7 +52,7 @@ struct dpll_data {
u8  max_divider;
u32 max_tolerance;
u16 max_multiplier;
-#  if defined(CONFIG_ARCH_OMAP3)
+#  if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
u8  modes;
void __iomem*autoidle_reg;
void __iomem*idlest_reg;
@@ -83,7 +84,8 @@ struct clk {
void(*init)(struct clk *);
__u8enable_bit;
__s8usecount;
-#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
+#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3) || \
+   defined(CONFIG_ARCH_OMAP4)
u8  fixed_div;
void __iomem*clksel_reg;
u32 clksel_mask;
diff --git a/arch/arm/plat-omap/include/mach/common.h 
b/arch/arm/plat-omap/include/mach/common.h
index 0ecf36d..4b18833 100644
--- a/arch/arm/plat-omap/include/mach/common.h
+++ b/arch/arm/plat-omap/include/mach/common.h
@@ -62,6 +62,7 @@ struct omap_globals {
 void omap2_set_globals_242x(void);
 void omap2_set_globals_243x(void);
 void omap2_set_globals_343x(void);
+void omap2_set_globals_443x(void);
 
 /* These get called from omap2_set_globals_(), do not call these */
 void omap2_set_globals_tap(struct omap_globals *);
diff --git a/arch/arm/plat-omap/include/mach/control.h 
b/arch/arm/plat-omap/include/mach/control.h
index 269147f..f45ec62 100644
--- a/arch/arm/plat-omap/include/mach/control.h
+++ b/arch/arm/plat-omap/include/mach/control.h
@@ -1,9 +1,9 @@
 /*
  * arch/arm/plat-omap/include/mach/control.h
  *
- * OMAP2/3 System Control Module definitions
+ * OMAP2/3/4 System Control Module definitions
  *
- * Copyright (C) 2007-2008 Texas Instruments, Inc.
+ * Copyright (C) 2007-2009 Texas Instruments, Inc.
  * Copyright (C) 2007-2008 Nokia Corporation
  *
  * Written by Paul Walmsley
@@ -190,7 +190,8 @@
 #define OMAP2_PBIASLITEVMODE0  (1 << 0)
 
 #ifndef __ASSEMBLY__
-#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
+#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3) || \
+   defined(CONFIG_ARCH_OMAP4)
 extern void __iomem *omap_ctrl_base_get(void);
 extern u8 omap_ctrl_readb(u16 offset);
 extern u16 omap_ctrl_readw(u16 offset);
diff --git a/arch/arm/plat-omap/include/mach/debug-macro.S 
b/arch/arm/plat-omap/include/mach/debug-macro.S
index 1b11f5c..ac24050 100644
--- a/arch/arm/plat-omap/include/mach/debug-macro.S
+++ b/arch/arm/plat-omap/include/mach/debug-macro.S
@@ -36,7 +36,7 @@
add \rx, \rx, #0x4000   @ UART 3
 #endif
 
-#elif  CONFIG_ARCH_OMAP3
+#elif defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
moveq   \rx, #0x4800@ physical base address
movne   \rx, #0xd800@ virtual base
orr \rx, \rx, #0x0006a000
diff --git a/arch/arm/plat-omap/include/mach/dma.h 
b/arch/arm/plat-omap/include/mach/dma.h
index 54fe966..8e05b6a 100644
--- a/arch/arm/plat-omap/include/mach/dma.h
+++ b/arch/arm/plat-omap/include/mach/dma.h
@@ -48,6 +48,7 @@
 /* Hardware registers for omap2 and omap3 */
 #define OMAP24XX_DMA4_BASE (L4_24XX_BASE + 0x56000)
 #define OMAP34XX_DMA4_BASE (L4_34XX_BASE + 0x