* [PATCH 1/9] omap: Move multi-omap ifdeffery into it's own header file
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
@ 2010-01-30 2:01 ` Tony Lindgren
2010-01-30 2:01 ` [PATCH 2/9] omap2/3/4: Clean up defines for entry-macro.S Tony Lindgren
` (9 subsequent siblings)
10 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 2:01 UTC (permalink / raw)
To: linux-arm-kernel
This way we can include it easily as needed also for .S files.
Signed-off-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/plat-omap/include/plat/cpu.h | 70 -----------------------
arch/arm/plat-omap/include/plat/multi.h | 94 +++++++++++++++++++++++++++++++
2 files changed, 95 insertions(+), 69 deletions(-)
create mode 100644 arch/arm/plat-omap/include/plat/multi.h
diff --git a/arch/arm/plat-omap/include/plat/cpu.h b/arch/arm/plat-omap/include/plat/cpu.h
index 995466d..b80151c 100644
--- a/arch/arm/plat-omap/include/plat/cpu.h
+++ b/arch/arm/plat-omap/include/plat/cpu.h
@@ -31,6 +31,7 @@
#define __ASM_ARCH_OMAP_CPU_H
#include <linux/bitops.h>
+#include <plat/multi.h>
/*
* Omap device type i.e. EMU/HS/TST/GP/BAD
@@ -76,75 +77,6 @@ unsigned int omap_rev(void);
#define GET_OMAP_REVISION() ((omap_rev() >> 8) & 0xff)
/*
- * Test if multicore OMAP support is needed
- */
-#undef MULTI_OMAP1
-#undef MULTI_OMAP2
-#undef OMAP_NAME
-
-#ifdef CONFIG_ARCH_OMAP730
-# ifdef OMAP_NAME
-# undef MULTI_OMAP1
-# define MULTI_OMAP1
-# else
-# define OMAP_NAME omap730
-# endif
-#endif
-#ifdef CONFIG_ARCH_OMAP850
-# ifdef OMAP_NAME
-# undef MULTI_OMAP1
-# define MULTI_OMAP1
-# else
-# define OMAP_NAME omap850
-# endif
-#endif
-#ifdef CONFIG_ARCH_OMAP15XX
-# ifdef OMAP_NAME
-# undef MULTI_OMAP1
-# define MULTI_OMAP1
-# else
-# define OMAP_NAME omap1510
-# endif
-#endif
-#ifdef CONFIG_ARCH_OMAP16XX
-# ifdef OMAP_NAME
-# undef MULTI_OMAP1
-# define MULTI_OMAP1
-# else
-# define OMAP_NAME omap16xx
-# endif
-#endif
-#if (defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3))
-# if (defined(OMAP_NAME) || defined(MULTI_OMAP1))
-# error "OMAP1 and OMAP2 can't be selected at the same time"
-# endif
-#endif
-#ifdef CONFIG_ARCH_OMAP2420
-# ifdef OMAP_NAME
-# undef MULTI_OMAP2
-# define MULTI_OMAP2
-# else
-# define OMAP_NAME omap2420
-# endif
-#endif
-#ifdef CONFIG_ARCH_OMAP2430
-# ifdef OMAP_NAME
-# undef MULTI_OMAP2
-# define MULTI_OMAP2
-# else
-# define OMAP_NAME omap2430
-# endif
-#endif
-#ifdef CONFIG_ARCH_OMAP3430
-# ifdef OMAP_NAME
-# undef MULTI_OMAP2
-# define MULTI_OMAP2
-# else
-# define OMAP_NAME omap3430
-# endif
-#endif
-
-/*
* Macros to group OMAP into cpu classes.
* These can be used in most places.
* cpu_is_omap7xx(): True for OMAP730, OMAP850
diff --git a/arch/arm/plat-omap/include/plat/multi.h b/arch/arm/plat-omap/include/plat/multi.h
new file mode 100644
index 0000000..f235d32
--- /dev/null
+++ b/arch/arm/plat-omap/include/plat/multi.h
@@ -0,0 +1,94 @@
+/*
+ * Support for compiling in multiple OMAP processors
+ *
+ * Copyright (C) 2010 Nokia Corporation
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ */
+
+#ifndef __PLAT_OMAP_MULTI_H
+#define __PLAT_OMAP_MULTI_H
+
+/*
+ * Test if multicore OMAP support is needed
+ */
+#undef MULTI_OMAP1
+#undef MULTI_OMAP2
+#undef OMAP_NAME
+
+#ifdef CONFIG_ARCH_OMAP730
+# ifdef OMAP_NAME
+# undef MULTI_OMAP1
+# define MULTI_OMAP1
+# else
+# define OMAP_NAME omap730
+# endif
+#endif
+#ifdef CONFIG_ARCH_OMAP850
+# ifdef OMAP_NAME
+# undef MULTI_OMAP1
+# define MULTI_OMAP1
+# else
+# define OMAP_NAME omap850
+# endif
+#endif
+#ifdef CONFIG_ARCH_OMAP15XX
+# ifdef OMAP_NAME
+# undef MULTI_OMAP1
+# define MULTI_OMAP1
+# else
+# define OMAP_NAME omap1510
+# endif
+#endif
+#ifdef CONFIG_ARCH_OMAP16XX
+# ifdef OMAP_NAME
+# undef MULTI_OMAP1
+# define MULTI_OMAP1
+# else
+# define OMAP_NAME omap16xx
+# endif
+#endif
+#if (defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3))
+# if (defined(OMAP_NAME) || defined(MULTI_OMAP1))
+# error "OMAP1 and OMAP2 can't be selected at the same time"
+# endif
+#endif
+#ifdef CONFIG_ARCH_OMAP2420
+# ifdef OMAP_NAME
+# undef MULTI_OMAP2
+# define MULTI_OMAP2
+# else
+# define OMAP_NAME omap2420
+# endif
+#endif
+#ifdef CONFIG_ARCH_OMAP2430
+# ifdef OMAP_NAME
+# undef MULTI_OMAP2
+# define MULTI_OMAP2
+# else
+# define OMAP_NAME omap2430
+# endif
+#endif
+#ifdef CONFIG_ARCH_OMAP3430
+# ifdef OMAP_NAME
+# undef MULTI_OMAP2
+# define MULTI_OMAP2
+# else
+# define OMAP_NAME omap3430
+# endif
+#endif
+
+#endif /* __PLAT_OMAP_MULTI_H */
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 2/9] omap2/3/4: Clean up defines for entry-macro.S
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
2010-01-30 2:01 ` [PATCH 1/9] omap: Move multi-omap ifdeffery into it's own header file Tony Lindgren
@ 2010-01-30 2:01 ` Tony Lindgren
2010-01-30 2:01 ` [PATCH 3/9] omap4: Use get_irqnr_preamble Tony Lindgren
` (8 subsequent siblings)
10 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 2:01 UTC (permalink / raw)
To: linux-arm-kernel
Define the irq base the same way as for omap2 and omap3,
and start using get_irqnr_preamble.
Signed-off-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/mach-omap2/include/mach/entry-macro.S | 15 +++++++--------
1 files changed, 7 insertions(+), 8 deletions(-)
diff --git a/arch/arm/mach-omap2/include/mach/entry-macro.S b/arch/arm/mach-omap2/include/mach/entry-macro.S
index 4fd6b1b..3e63aaa 100644
--- a/arch/arm/mach-omap2/include/mach/entry-macro.S
+++ b/arch/arm/mach-omap2/include/mach/entry-macro.S
@@ -19,6 +19,12 @@
#include <plat/omap34xx.h>
#include <plat/omap44xx.h>
+#define OMAP2_IRQ_BASE OMAP2_L4_IO_ADDRESS(OMAP24XX_IC_BASE)
+#define OMAP3_IRQ_BASE OMAP2_L4_IO_ADDRESS(OMAP34XX_IC_BASE)
+#define OMAP4_IRQ_BASE OMAP2_L4_IO_ADDRESS(OMAP44XX_GIC_CPU_BASE)
+#define INTCPS_SIR_IRQ_OFFSET 0x0040 /* omap2/3 active interrupt offset */
+#define ACTIVEIRQ_MASK 0x7f /* omap2/3 active interrupt bits */
+
.macro disable_fiq
.endm
@@ -27,11 +33,6 @@
#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
-#define OMAP2_IRQ_BASE OMAP2_L4_IO_ADDRESS(OMAP24XX_IC_BASE)
-#define OMAP3_IRQ_BASE OMAP2_L4_IO_ADDRESS(OMAP34XX_IC_BASE)
-#define INTCPS_SIR_IRQ_OFFSET 0x0040 /* Active interrupt offset */
-#define ACTIVEIRQ_MASK 0x7f /* Active interrupt bits */
-
.pushsection .data
omap_irq_base: .word 0
.popsection
@@ -90,8 +91,6 @@ omap_irq_base: .word 0
#ifdef CONFIG_ARCH_OMAP4
-#define OMAP44XX_VA_GIC_CPU_BASE OMAP2_L4_IO_ADDRESS(OMAP44XX_GIC_CPU_BASE)
-
.macro get_irqnr_preamble, base, tmp
.endm
@@ -115,7 +114,7 @@ omap_irq_base: .word 0
* valid range for an IRQ (30-1020 inclusive).
*/
.macro get_irqnr_and_base, irqnr, irqstat, base, tmp
- ldr \base, =OMAP44XX_VA_GIC_CPU_BASE
+ ldr \base, =OMAP4_IRQ_BASE
ldr \irqstat, [\base, #GIC_CPU_INTACK]
ldr \tmp, =1021
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 3/9] omap4: Use get_irqnr_preamble
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
2010-01-30 2:01 ` [PATCH 1/9] omap: Move multi-omap ifdeffery into it's own header file Tony Lindgren
2010-01-30 2:01 ` [PATCH 2/9] omap2/3/4: Clean up defines for entry-macro.S Tony Lindgren
@ 2010-01-30 2:01 ` Tony Lindgren
2010-01-30 2:01 ` [PATCH 4/9] omap2/3/4: Clean up entry-macro.s for adding support for omap4 multiboot Tony Lindgren
` (7 subsequent siblings)
10 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 2:01 UTC (permalink / raw)
To: linux-arm-kernel
Use get_irqnr_preamble
Signed-off-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/mach-omap2/include/mach/entry-macro.S | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-omap2/include/mach/entry-macro.S b/arch/arm/mach-omap2/include/mach/entry-macro.S
index 3e63aaa..101ed79 100644
--- a/arch/arm/mach-omap2/include/mach/entry-macro.S
+++ b/arch/arm/mach-omap2/include/mach/entry-macro.S
@@ -92,6 +92,7 @@ omap_irq_base: .word 0
#ifdef CONFIG_ARCH_OMAP4
.macro get_irqnr_preamble, base, tmp
+ ldr \base, =OMAP4_IRQ_BASE
.endm
/*
@@ -114,7 +115,6 @@ omap_irq_base: .word 0
* valid range for an IRQ (30-1020 inclusive).
*/
.macro get_irqnr_and_base, irqnr, irqstat, base, tmp
- ldr \base, =OMAP4_IRQ_BASE
ldr \irqstat, [\base, #GIC_CPU_INTACK]
ldr \tmp, =1021
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 4/9] omap2/3/4: Clean up entry-macro.s for adding support for omap4 multiboot
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
` (2 preceding siblings ...)
2010-01-30 2:01 ` [PATCH 3/9] omap4: Use get_irqnr_preamble Tony Lindgren
@ 2010-01-30 2:01 ` Tony Lindgren
2010-01-30 2:01 ` [PATCH 5/9] omap2/3/4: Allow booting omap4 with multi-omap configuration Tony Lindgren
` (6 subsequent siblings)
10 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 2:01 UTC (permalink / raw)
To: linux-arm-kernel
Move defines around and set up handlers based on MULTI_OMAP2.
Note that this will only allow compiling in omap4 with omap2 and
omap3. It will not yet make omap4 boot with multi-omap.
Signed-off-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/mach-omap2/include/mach/entry-macro.S | 38 +++++++++++++++++++++---
1 files changed, 34 insertions(+), 4 deletions(-)
diff --git a/arch/arm/mach-omap2/include/mach/entry-macro.S b/arch/arm/mach-omap2/include/mach/entry-macro.S
index 101ed79..fe3c9ad 100644
--- a/arch/arm/mach-omap2/include/mach/entry-macro.S
+++ b/arch/arm/mach-omap2/include/mach/entry-macro.S
@@ -19,6 +19,8 @@
#include <plat/omap34xx.h>
#include <plat/omap44xx.h>
+#include <plat/multi.h>
+
#define OMAP2_IRQ_BASE OMAP2_L4_IO_ADDRESS(OMAP24XX_IC_BASE)
#define OMAP3_IRQ_BASE OMAP2_L4_IO_ADDRESS(OMAP34XX_IC_BASE)
#define OMAP4_IRQ_BASE OMAP2_L4_IO_ADDRESS(OMAP44XX_GIC_CPU_BASE)
@@ -31,13 +33,15 @@
.macro arch_ret_to_user, tmp1, tmp2
.endm
-#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
+/*
+ * Unoptimized irq functions for multi-omap2, 3 and 4
+ */
+#ifdef MULTI_OMAP2
.pushsection .data
omap_irq_base: .word 0
.popsection
-#if defined(CONFIG_ARCH_OMAP2) && defined(CONFIG_ARCH_OMAP3)
/* Configure the interrupt base on the first interrupt */
.macro get_irqnr_preamble, base, tmp
9:
@@ -62,7 +66,32 @@ omap_irq_base: .word 0
b 9b
9998:
.endm
-#else
+
+ /* Check the pending interrupts. Note that base already set */
+ .macro get_irqnr_and_base, irqnr, irqstat, base, tmp
+ ldr \irqnr, [\base, #0x98] /* IRQ pending reg 1 */
+ cmp \irqnr, #0x0
+ bne 9999f
+ ldr \irqnr, [\base, #0xb8] /* IRQ pending reg 2 */
+ cmp \irqnr, #0x0
+ bne 9999f
+ ldr \irqnr, [\base, #0xd8] /* IRQ pending reg 3 */
+ cmp \irqnr, #0x0
+9999:
+ ldrne \irqnr, [\base, #INTCPS_SIR_IRQ_OFFSET]
+ and \irqnr, \irqnr, #ACTIVEIRQ_MASK /* Clear spurious bits */
+
+ .endm
+
+
+#else /* MULTI_OMAP2 */
+
+
+/*
+ * Optimized irq functions for omap2, 3 and 4
+ */
+
+#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
.macro get_irqnr_preamble, base, tmp
#ifdef CONFIG_ARCH_OMAP2
ldr \base, =OMAP2_IRQ_BASE
@@ -70,7 +99,7 @@ omap_irq_base: .word 0
ldr \base, =OMAP3_IRQ_BASE
#endif
.endm
-#endif
+
/* Check the pending interrupts. Note that base already set */
.macro get_irqnr_and_base, irqnr, irqstat, base, tmp
ldr \irqnr, [\base, #0x98] /* IRQ pending reg 1 */
@@ -155,6 +184,7 @@ omap_irq_base: .word 0
cmp \tmp, #0
.endm
#endif
+#endif /* MULTI_OMAP2 */
.macro irq_prio_table
.endm
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 5/9] omap2/3/4: Allow booting omap4 with multi-omap configuration
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
` (3 preceding siblings ...)
2010-01-30 2:01 ` [PATCH 4/9] omap2/3/4: Clean up entry-macro.s for adding support for omap4 multiboot Tony Lindgren
@ 2010-01-30 2:01 ` Tony Lindgren
2010-01-30 2:01 ` [PATCH 6/9] omap3/4: Fix compile for multi-omap for clkops_noncore_dpll_ops Tony Lindgren
` (5 subsequent siblings)
10 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 2:01 UTC (permalink / raw)
To: linux-arm-kernel
Allow booting omap4 with multi-omap configuration.
Tested only on omap2 and omap3, please somebody test
on omap4 and ack.
Signed-off-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/mach-omap2/include/mach/entry-macro.S | 36 +++++++++++++++++++-----
1 files changed, 29 insertions(+), 7 deletions(-)
diff --git a/arch/arm/mach-omap2/include/mach/entry-macro.S b/arch/arm/mach-omap2/include/mach/entry-macro.S
index fe3c9ad..ff25c7e 100644
--- a/arch/arm/mach-omap2/include/mach/entry-macro.S
+++ b/arch/arm/mach-omap2/include/mach/entry-macro.S
@@ -48,14 +48,18 @@ omap_irq_base: .word 0
ldr \base, =omap_irq_base @ irq base address
ldr \base, [\base, #0] @ irq base value
cmp \base, #0 @ already configured?
- bne 9998f @ nothing to do
+ bne 9997f @ nothing to do
mrc p15, 0, \tmp, c0, c0, 0 @ get processor revision
and \tmp, \tmp, #0x000f0000 @ only check architecture
cmp \tmp, #0x00060000 @ is v6?
beq 2400f @ found v6 so it's omap24xx
- cmp \tmp, #0x000f0000 @ is cortex?
- beq 3400f @ found v7 so it's omap34xx
+ mrc p15, 0, \tmp, c0, c0, 0 @ get processor revision
+ and \tmp, \tmp, #0x000000f0 @ check cortex 8 or 9
+ cmp \tmp, #0x00000080 @ cortex A-8?
+ beq 3400f @ found A-8 so it's omap34xx
+ cmp \tmp, #0x00000090 @ cortex A-9?
+ beq 4400f @ found A-9 so it's omap44xx
2400: ldr \base, =OMAP2_IRQ_BASE
ldr \tmp, =omap_irq_base
str \base, [\tmp, #0]
@@ -64,23 +68,41 @@ omap_irq_base: .word 0
ldr \tmp, =omap_irq_base
str \base, [\tmp, #0]
b 9b
-9998:
+4400: ldr \base, =OMAP4_IRQ_BASE
+ ldr \tmp, =omap_irq_base
+ str \base, [\tmp, #0]
+ b 9b
+9997:
.endm
/* Check the pending interrupts. Note that base already set */
.macro get_irqnr_and_base, irqnr, irqstat, base, tmp
+ tst \base, #0x100 @ gic address?
+ bne 4401f @ found gic
+
+ /* Handle omap2 and omap3 */
ldr \irqnr, [\base, #0x98] /* IRQ pending reg 1 */
cmp \irqnr, #0x0
- bne 9999f
+ bne 9998f
ldr \irqnr, [\base, #0xb8] /* IRQ pending reg 2 */
cmp \irqnr, #0x0
- bne 9999f
+ bne 9998f
ldr \irqnr, [\base, #0xd8] /* IRQ pending reg 3 */
cmp \irqnr, #0x0
-9999:
+9998:
ldrne \irqnr, [\base, #INTCPS_SIR_IRQ_OFFSET]
and \irqnr, \irqnr, #ACTIVEIRQ_MASK /* Clear spurious bits */
+ b 9999f
+ /* Handle omap4 */
+4401: ldr \irqstat, [\base, #GIC_CPU_INTACK]
+ ldr \tmp, =1021
+ bic \irqnr, \irqstat, #0x1c00
+ cmp \irqnr, #29
+ cmpcc \irqnr, \irqnr
+ cmpne \irqnr, \tmp
+ cmpcs \irqnr, \irqnr
+9999:
.endm
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 6/9] omap3/4: Fix compile for multi-omap for clkops_noncore_dpll_ops
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
` (4 preceding siblings ...)
2010-01-30 2:01 ` [PATCH 5/9] omap2/3/4: Allow booting omap4 with multi-omap configuration Tony Lindgren
@ 2010-01-30 2:01 ` Tony Lindgren
2010-02-01 20:20 ` Paul Walmsley
2010-01-30 2:01 ` [PATCH 7/9] omap: Fix gpio.c for multi-omap for omap4 Tony Lindgren
` (4 subsequent siblings)
10 siblings, 1 reply; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 2:01 UTC (permalink / raw)
To: linux-arm-kernel
Rename clkops_noncore_dpll_ops for omap3 and omap4.
Signed-off-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/mach-omap2/clock34xx.c | 2 +-
arch/arm/mach-omap2/clock34xx.h | 2 +-
arch/arm/mach-omap2/clock34xx_data.c | 6 +++---
arch/arm/mach-omap2/clock44xx.c | 2 +-
arch/arm/mach-omap2/clock44xx.h | 2 +-
arch/arm/mach-omap2/clock44xx_data.c | 12 ++++++------
6 files changed, 13 insertions(+), 13 deletions(-)
diff --git a/arch/arm/mach-omap2/clock34xx.c b/arch/arm/mach-omap2/clock34xx.c
index 1f1b5a6..ae9e2c8 100644
--- a/arch/arm/mach-omap2/clock34xx.c
+++ b/arch/arm/mach-omap2/clock34xx.c
@@ -130,7 +130,7 @@ const struct clkops clkops_omap3430es2_hsotgusb_wait = {
.find_companion = omap2_clk_dflt_find_companion,
};
-const struct clkops clkops_noncore_dpll_ops = {
+const struct clkops omap3_clkops_noncore_dpll_ops = {
.enable = omap3_noncore_dpll_enable,
.disable = omap3_noncore_dpll_disable,
};
diff --git a/arch/arm/mach-omap2/clock34xx.h b/arch/arm/mach-omap2/clock34xx.h
index 73f2109..313efc0 100644
--- a/arch/arm/mach-omap2/clock34xx.h
+++ b/arch/arm/mach-omap2/clock34xx.h
@@ -20,6 +20,6 @@ extern struct clk *arm_fck_p;
extern const struct clkops clkops_omap3430es2_ssi_wait;
extern const struct clkops clkops_omap3430es2_hsotgusb_wait;
extern const struct clkops clkops_omap3430es2_dss_usbhost_wait;
-extern const struct clkops clkops_noncore_dpll_ops;
+extern const struct clkops omap3_clkops_noncore_dpll_ops;
#endif
diff --git a/arch/arm/mach-omap2/clock34xx_data.c b/arch/arm/mach-omap2/clock34xx_data.c
index 0d04f92..8728f1f 100644
--- a/arch/arm/mach-omap2/clock34xx_data.c
+++ b/arch/arm/mach-omap2/clock34xx_data.c
@@ -337,7 +337,7 @@ static struct dpll_data dpll2_dd = {
static struct clk dpll2_ck = {
.name = "dpll2_ck",
- .ops = &clkops_noncore_dpll_ops,
+ .ops = &omap3_clkops_noncore_dpll_ops,
.parent = &sys_ck,
.dpll_data = &dpll2_dd,
.round_rate = &omap2_dpll_round_rate,
@@ -554,7 +554,7 @@ static struct dpll_data dpll4_dd = {
static struct clk dpll4_ck = {
.name = "dpll4_ck",
- .ops = &clkops_noncore_dpll_ops,
+ .ops = &omap3_clkops_noncore_dpll_ops,
.parent = &sys_ck,
.dpll_data = &dpll4_dd,
.round_rate = &omap2_dpll_round_rate,
@@ -854,7 +854,7 @@ static struct dpll_data dpll5_dd = {
static struct clk dpll5_ck = {
.name = "dpll5_ck",
- .ops = &clkops_noncore_dpll_ops,
+ .ops = &omap3_clkops_noncore_dpll_ops,
.parent = &sys_ck,
.dpll_data = &dpll5_dd,
.round_rate = &omap2_dpll_round_rate,
diff --git a/arch/arm/mach-omap2/clock44xx.c b/arch/arm/mach-omap2/clock44xx.c
index c238717..84ee6b0 100644
--- a/arch/arm/mach-omap2/clock44xx.c
+++ b/arch/arm/mach-omap2/clock44xx.c
@@ -13,7 +13,7 @@
#include <linux/errno.h>
#include "clock.h"
-const struct clkops clkops_noncore_dpll_ops = {
+const struct clkops omap4_clkops_noncore_dpll_ops = {
.enable = &omap3_noncore_dpll_enable,
.disable = &omap3_noncore_dpll_disable,
};
diff --git a/arch/arm/mach-omap2/clock44xx.h b/arch/arm/mach-omap2/clock44xx.h
index 1f55b6b..efe8494 100644
--- a/arch/arm/mach-omap2/clock44xx.h
+++ b/arch/arm/mach-omap2/clock44xx.h
@@ -12,6 +12,6 @@
int omap4xxx_clk_init(void);
-extern const struct clkops clkops_noncore_dpll_ops;
+extern const struct clkops omap4_clkops_noncore_dpll_ops;
#endif
diff --git a/arch/arm/mach-omap2/clock44xx_data.c b/arch/arm/mach-omap2/clock44xx_data.c
index 35ffe63..86af31d 100644
--- a/arch/arm/mach-omap2/clock44xx_data.c
+++ b/arch/arm/mach-omap2/clock44xx_data.c
@@ -279,7 +279,7 @@ static struct clk dpll_abe_ck = {
.parent = &abe_dpll_refclk_mux_ck,
.dpll_data = &dpll_abe_dd,
.init = &omap2_init_dpll_parent,
- .ops = &clkops_noncore_dpll_ops,
+ .ops = &omap4_clkops_noncore_dpll_ops,
.recalc = &omap3_dpll_recalc,
.round_rate = &omap2_dpll_round_rate,
.set_rate = &omap3_noncore_dpll_set_rate,
@@ -668,7 +668,7 @@ static struct clk dpll_iva_ck = {
.parent = &dpll_sys_ref_clk,
.dpll_data = &dpll_iva_dd,
.init = &omap2_init_dpll_parent,
- .ops = &clkops_noncore_dpll_ops,
+ .ops = &omap4_clkops_noncore_dpll_ops,
.recalc = &omap3_dpll_recalc,
.round_rate = &omap2_dpll_round_rate,
.set_rate = &omap3_noncore_dpll_set_rate,
@@ -731,7 +731,7 @@ static struct clk dpll_mpu_ck = {
.parent = &dpll_sys_ref_clk,
.dpll_data = &dpll_mpu_dd,
.init = &omap2_init_dpll_parent,
- .ops = &clkops_noncore_dpll_ops,
+ .ops = &omap4_clkops_noncore_dpll_ops,
.recalc = &omap3_dpll_recalc,
.round_rate = &omap2_dpll_round_rate,
.set_rate = &omap3_noncore_dpll_set_rate,
@@ -807,7 +807,7 @@ static struct clk dpll_per_ck = {
.parent = &dpll_sys_ref_clk,
.dpll_data = &dpll_per_dd,
.init = &omap2_init_dpll_parent,
- .ops = &clkops_noncore_dpll_ops,
+ .ops = &omap4_clkops_noncore_dpll_ops,
.recalc = &omap3_dpll_recalc,
.round_rate = &omap2_dpll_round_rate,
.set_rate = &omap3_noncore_dpll_set_rate,
@@ -930,7 +930,7 @@ static struct clk dpll_unipro_ck = {
.parent = &dpll_sys_ref_clk,
.dpll_data = &dpll_unipro_dd,
.init = &omap2_init_dpll_parent,
- .ops = &clkops_noncore_dpll_ops,
+ .ops = &omap4_clkops_noncore_dpll_ops,
.recalc = &omap3_dpll_recalc,
.round_rate = &omap2_dpll_round_rate,
.set_rate = &omap3_noncore_dpll_set_rate,
@@ -988,7 +988,7 @@ static struct clk dpll_usb_ck = {
.parent = &dpll_sys_ref_clk,
.dpll_data = &dpll_usb_dd,
.init = &omap2_init_dpll_parent,
- .ops = &clkops_noncore_dpll_ops,
+ .ops = &omap4_clkops_noncore_dpll_ops,
.recalc = &omap3_dpll_recalc,
.round_rate = &omap2_dpll_round_rate,
.set_rate = &omap3_noncore_dpll_set_rate,
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 7/9] omap: Fix gpio.c for multi-omap for omap4
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
` (5 preceding siblings ...)
2010-01-30 2:01 ` [PATCH 6/9] omap3/4: Fix compile for multi-omap for clkops_noncore_dpll_ops Tony Lindgren
@ 2010-01-30 2:01 ` Tony Lindgren
2010-01-30 2:01 ` [PATCH 8/9] omap2/3/4: Fix mach-omap2/serial.c for multiboot Tony Lindgren
` (3 subsequent siblings)
10 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 2:01 UTC (permalink / raw)
To: linux-arm-kernel
Set up METHOD_GPIO_44XX instead of trying to use the METHOD_GPIO_24XX.
Signed-off-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/plat-omap/gpio.c | 217 ++++++++++++++++++++++++++-------------------
1 files changed, 126 insertions(+), 91 deletions(-)
diff --git a/arch/arm/plat-omap/gpio.c b/arch/arm/plat-omap/gpio.c
index a888304..4395d15 100644
--- a/arch/arm/plat-omap/gpio.c
+++ b/arch/arm/plat-omap/gpio.c
@@ -202,6 +202,7 @@ struct gpio_bank {
#define METHOD_GPIO_1610 2
#define METHOD_GPIO_7XX 3
#define METHOD_GPIO_24XX 5
+#define METHOD_GPIO_44XX 6
#ifdef CONFIG_ARCH_OMAP16XX
static struct gpio_bank gpio_bank_1610[5] = {
@@ -312,17 +313,17 @@ static struct omap3_gpio_regs gpio_context[OMAP34XX_NR_GPIOS];
#ifdef CONFIG_ARCH_OMAP4
static struct gpio_bank gpio_bank_44xx[6] = {
{ OMAP44XX_GPIO1_BASE, NULL, INT_44XX_GPIO_BANK1, IH_GPIO_BASE,
- METHOD_GPIO_24XX },
+ METHOD_GPIO_44XX },
{ OMAP44XX_GPIO2_BASE, NULL, INT_44XX_GPIO_BANK2, IH_GPIO_BASE + 32,
- METHOD_GPIO_24XX },
+ METHOD_GPIO_44XX },
{ OMAP44XX_GPIO3_BASE, NULL, INT_44XX_GPIO_BANK3, IH_GPIO_BASE + 64,
- METHOD_GPIO_24XX },
+ METHOD_GPIO_44XX },
{ OMAP44XX_GPIO4_BASE, NULL, INT_44XX_GPIO_BANK4, IH_GPIO_BASE + 96,
- METHOD_GPIO_24XX },
+ METHOD_GPIO_44XX },
{ OMAP44XX_GPIO5_BASE, NULL, INT_44XX_GPIO_BANK5, IH_GPIO_BASE + 128,
- METHOD_GPIO_24XX },
+ METHOD_GPIO_44XX },
{ OMAP44XX_GPIO6_BASE, NULL, INT_44XX_GPIO_BANK6, IH_GPIO_BASE + 160,
- METHOD_GPIO_24XX },
+ METHOD_GPIO_44XX },
};
#endif
@@ -430,7 +431,7 @@ static void _set_gpio_direction(struct gpio_bank *bank, int gpio, int is_input)
break;
#endif
#if defined(CONFIG_ARCH_OMAP4)
- case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
reg += OMAP4_GPIO_OE;
break;
#endif
@@ -501,7 +502,7 @@ static void _set_gpio_dataout(struct gpio_bank *bank, int gpio, int enable)
break;
#endif
#ifdef CONFIG_ARCH_OMAP4
- case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
if (enable)
reg += OMAP4_GPIO_SETDATAOUT;
else
@@ -550,7 +551,7 @@ static int _get_gpio_datain(struct gpio_bank *bank, int gpio)
break;
#endif
#ifdef CONFIG_ARCH_OMAP4
- case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
reg += OMAP4_GPIO_DATAIN;
break;
#endif
@@ -592,6 +593,7 @@ static int _get_gpio_dataout(struct gpio_bank *bank, int gpio)
#endif
#ifdef CONFIG_ARCH_OMAP2PLUS
case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
reg += OMAP24XX_GPIO_DATAOUT;
break;
#endif
@@ -622,11 +624,12 @@ void omap_set_gpio_debounce(int gpio, int enable)
bank = get_gpio_bank(gpio);
reg = bank->base;
-#ifdef CONFIG_ARCH_OMAP4
- reg += OMAP4_GPIO_DEBOUNCENABLE;
-#else
- reg += OMAP24XX_GPIO_DEBOUNCE_EN;
-#endif
+
+ if (cpu_is_omap44xx())
+ reg += OMAP4_GPIO_DEBOUNCENABLE;
+ else
+ reg += OMAP24XX_GPIO_DEBOUNCE_EN;
+
if (!(bank->mod_usage & l)) {
printk(KERN_ERR "GPIO %d not requested\n", gpio);
return;
@@ -672,11 +675,12 @@ void omap_set_gpio_debounce_time(int gpio, int enc_time)
}
enc_time &= 0xff;
-#ifdef CONFIG_ARCH_OMAP4
- reg += OMAP4_GPIO_DEBOUNCINGTIME;
-#else
- reg += OMAP24XX_GPIO_DEBOUNCE_VAL;
-#endif
+
+ if (cpu_is_omap44xx())
+ reg += OMAP4_GPIO_DEBOUNCINGTIME;
+ else
+ reg += OMAP24XX_GPIO_DEBOUNCE_VAL;
+
__raw_writel(enc_time, reg);
}
EXPORT_SYMBOL(omap_set_gpio_debounce_time);
@@ -854,6 +858,7 @@ static int _set_gpio_triggering(struct gpio_bank *bank, int gpio, int trigger)
#endif
#ifdef CONFIG_ARCH_OMAP2PLUS
case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
set_24xx_gpio_triggering(bank, gpio, trigger);
break;
#endif
@@ -938,7 +943,7 @@ static void _clear_gpio_irqbank(struct gpio_bank *bank, int gpio_mask)
break;
#endif
#if defined(CONFIG_ARCH_OMAP4)
- case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
reg += OMAP4_GPIO_IRQSTATUS0;
break;
#endif
@@ -949,12 +954,11 @@ static void _clear_gpio_irqbank(struct gpio_bank *bank, int gpio_mask)
__raw_writel(gpio_mask, reg);
/* Workaround for clearing DSP GPIO interrupts to allow retention */
-#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
- reg = bank->base + OMAP24XX_GPIO_IRQSTATUS2;
-#endif
-#if defined(CONFIG_ARCH_OMAP4)
- reg = bank->base + OMAP4_GPIO_IRQSTATUS1;
-#endif
+ if (cpu_is_omap24xx() || cpu_is_omap34xx())
+ reg = bank->base + OMAP24XX_GPIO_IRQSTATUS2;
+ else if (cpu_is_omap44xx())
+ reg = bank->base + OMAP4_GPIO_IRQSTATUS1;
+
if (cpu_is_omap24xx() || cpu_is_omap34xx() || cpu_is_omap44xx()) {
__raw_writel(gpio_mask, reg);
@@ -1010,7 +1014,7 @@ static u32 _get_gpio_irqbank_mask(struct gpio_bank *bank)
break;
#endif
#if defined(CONFIG_ARCH_OMAP4)
- case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
reg += OMAP4_GPIO_IRQSTATUSSET0;
mask = 0xffffffff;
break;
@@ -1082,7 +1086,7 @@ static void _enable_gpio_irqbank(struct gpio_bank *bank, int gpio_mask, int enab
break;
#endif
#ifdef CONFIG_ARCH_OMAP4
- case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
if (enable)
reg += OMAP4_GPIO_IRQSTATUSSET0;
else
@@ -1128,6 +1132,7 @@ static int _set_gpio_wakeup(struct gpio_bank *bank, int gpio, int enable)
#endif
#ifdef CONFIG_ARCH_OMAP2PLUS
case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
if (bank->non_wakeup_gpios & (1 << gpio)) {
printk(KERN_ERR "Unable to modify wakeup on "
"non-wakeup GPIO%d\n",
@@ -1222,7 +1227,8 @@ static void omap_gpio_free(struct gpio_chip *chip, unsigned offset)
}
#endif
#ifdef CONFIG_ARCH_OMAP2PLUS
- if (bank->method == METHOD_GPIO_24XX) {
+ if ((bank->method == METHOD_GPIO_24XX) ||
+ (bank->method == METHOD_GPIO_44XX)) {
/* Disable wake-up during idle for dynamic tick */
void __iomem *reg = bank->base + OMAP24XX_GPIO_CLEARWKUENA;
__raw_writel(1 << offset, reg);
@@ -1284,7 +1290,7 @@ static void gpio_irq_handler(unsigned int irq, struct irq_desc *desc)
isr_reg = bank->base + OMAP24XX_GPIO_IRQSTATUS1;
#endif
#if defined(CONFIG_ARCH_OMAP4)
- if (bank->method == METHOD_GPIO_24XX)
+ if (bank->method == METHOD_GPIO_44XX)
isr_reg = bank->base + OMAP4_GPIO_IRQSTATUS0;
#endif
while(1) {
@@ -1564,6 +1570,7 @@ static int gpio_is_input(struct gpio_bank *bank, int mask)
reg += OMAP7XX_GPIO_DIR_CONTROL;
break;
case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
reg += OMAP24XX_GPIO_OE;
break;
}
@@ -1803,28 +1810,34 @@ static int __init _omap_gpio_init(void)
}
#ifdef CONFIG_ARCH_OMAP2PLUS
- if (bank->method == METHOD_GPIO_24XX) {
+ if ((bank->method == METHOD_GPIO_24XX) ||
+ (bank->method == METHOD_GPIO_44XX)) {
static const u32 non_wakeup_gpios[] = {
0xe203ffc0, 0x08700040
};
- if (cpu_is_omap44xx()) {
- __raw_writel(0xffffffff, bank->base +
+
+ if (cpu_is_omap44xx()) {
+ __raw_writel(0xffffffff, bank->base +
OMAP4_GPIO_IRQSTATUSCLR0);
- __raw_writew(0x0015, bank->base +
+ __raw_writew(0x0015, bank->base +
OMAP4_GPIO_SYSCONFIG);
- __raw_writel(0x00000000, bank->base +
+ __raw_writel(0x00000000, bank->base +
OMAP4_GPIO_DEBOUNCENABLE);
- /* Initialize interface clock ungated, module enabled */
- __raw_writel(0, bank->base + OMAP4_GPIO_CTRL);
- } else {
- __raw_writel(0x00000000, bank->base + OMAP24XX_GPIO_IRQENABLE1);
- __raw_writel(0xffffffff, bank->base + OMAP24XX_GPIO_IRQSTATUS1);
- __raw_writew(0x0015, bank->base + OMAP24XX_GPIO_SYSCONFIG);
- __raw_writel(0x00000000, bank->base + OMAP24XX_GPIO_DEBOUNCE_EN);
-
- /* Initialize interface clock ungated, module enabled */
- __raw_writel(0, bank->base + OMAP24XX_GPIO_CTRL);
- }
+ /* Initialize interface clock ungated, module enabled */
+ __raw_writel(0, bank->base + OMAP4_GPIO_CTRL);
+ } else {
+ __raw_writel(0x00000000, bank->base +
+ OMAP24XX_GPIO_IRQENABLE1);
+ __raw_writel(0xffffffff, bank->base +
+ OMAP24XX_GPIO_IRQSTATUS1);
+ __raw_writew(0x0015, bank->base +
+ OMAP24XX_GPIO_SYSCONFIG);
+ __raw_writel(0x00000000, bank->base +
+ OMAP24XX_GPIO_DEBOUNCE_EN);
+
+ /* Initialize interface clock ungated, module enabled */
+ __raw_writel(0, bank->base + OMAP24XX_GPIO_CTRL);
+ }
if (i < ARRAY_SIZE(non_wakeup_gpios))
bank->non_wakeup_gpios = non_wakeup_gpios[i];
gpio_count = 32;
@@ -1926,7 +1939,7 @@ static int omap_gpio_suspend(struct sys_device *dev, pm_message_t mesg)
break;
#endif
#ifdef CONFIG_ARCH_OMAP4
- case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
wake_status = bank->base + OMAP4_GPIO_IRQWAKEN0;
wake_clear = bank->base + OMAP4_GPIO_IRQWAKEN0;
wake_set = bank->base + OMAP4_GPIO_IRQWAKEN0;
@@ -1973,7 +1986,7 @@ static int omap_gpio_resume(struct sys_device *dev)
break;
#endif
#ifdef CONFIG_ARCH_OMAP4
- case METHOD_GPIO_24XX:
+ case METHOD_GPIO_44XX:
wake_clear = bank->base + OMAP4_GPIO_IRQWAKEN0;
wake_set = bank->base + OMAP4_GPIO_IRQWAKEN0;
break;
@@ -2020,29 +2033,42 @@ void omap2_gpio_prepare_for_retention(void)
if (!(bank->enabled_non_wakeup_gpios))
continue;
-#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
- bank->saved_datain = __raw_readl(bank->base + OMAP24XX_GPIO_DATAIN);
- l1 = __raw_readl(bank->base + OMAP24XX_GPIO_FALLINGDETECT);
- l2 = __raw_readl(bank->base + OMAP24XX_GPIO_RISINGDETECT);
-#endif
-#ifdef CONFIG_ARCH_OMAP4
- bank->saved_datain = __raw_readl(bank->base +
- OMAP4_GPIO_DATAIN);
- l1 = __raw_readl(bank->base + OMAP4_GPIO_FALLINGDETECT);
- l2 = __raw_readl(bank->base + OMAP4_GPIO_RISINGDETECT);
-#endif
+
+ if (cpu_is_omap24xx() || cpu_is_omap34xx()) {
+ bank->saved_datain = __raw_readl(bank->base +
+ OMAP24XX_GPIO_DATAIN);
+ l1 = __raw_readl(bank->base +
+ OMAP24XX_GPIO_FALLINGDETECT);
+ l2 = __raw_readl(bank->base +
+ OMAP24XX_GPIO_RISINGDETECT);
+ }
+
+ if (cpu_is_omap44xx()) {
+ bank->saved_datain = __raw_readl(bank->base +
+ OMAP4_GPIO_DATAIN);
+ l1 = __raw_readl(bank->base +
+ OMAP4_GPIO_FALLINGDETECT);
+ l2 = __raw_readl(bank->base +
+ OMAP4_GPIO_RISINGDETECT);
+ }
+
bank->saved_fallingdetect = l1;
bank->saved_risingdetect = l2;
l1 &= ~bank->enabled_non_wakeup_gpios;
l2 &= ~bank->enabled_non_wakeup_gpios;
-#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
- __raw_writel(l1, bank->base + OMAP24XX_GPIO_FALLINGDETECT);
- __raw_writel(l2, bank->base + OMAP24XX_GPIO_RISINGDETECT);
-#endif
-#ifdef CONFIG_ARCH_OMAP4
- __raw_writel(l1, bank->base + OMAP4_GPIO_FALLINGDETECT);
- __raw_writel(l2, bank->base + OMAP4_GPIO_RISINGDETECT);
-#endif
+
+ if (cpu_is_omap24xx() || cpu_is_omap34xx()) {
+ __raw_writel(l1, bank->base +
+ OMAP24XX_GPIO_FALLINGDETECT);
+ __raw_writel(l2, bank->base +
+ OMAP24XX_GPIO_RISINGDETECT);
+ }
+
+ if (cpu_is_omap44xx()) {
+ __raw_writel(l1, bank->base + OMAP4_GPIO_FALLINGDETECT);
+ __raw_writel(l2, bank->base + OMAP4_GPIO_RISINGDETECT);
+ }
+
c++;
}
if (!c) {
@@ -2064,20 +2090,23 @@ void omap2_gpio_resume_after_retention(void)
if (!(bank->enabled_non_wakeup_gpios))
continue;
-#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
- __raw_writel(bank->saved_fallingdetect,
+
+ if (cpu_is_omap24xx() || cpu_is_omap34xx()) {
+ __raw_writel(bank->saved_fallingdetect,
bank->base + OMAP24XX_GPIO_FALLINGDETECT);
- __raw_writel(bank->saved_risingdetect,
+ __raw_writel(bank->saved_risingdetect,
bank->base + OMAP24XX_GPIO_RISINGDETECT);
- l = __raw_readl(bank->base + OMAP24XX_GPIO_DATAIN);
-#endif
-#ifdef CONFIG_ARCH_OMAP4
- __raw_writel(bank->saved_fallingdetect,
+ l = __raw_readl(bank->base + OMAP24XX_GPIO_DATAIN);
+ }
+
+ if (cpu_is_omap44xx()) {
+ __raw_writel(bank->saved_fallingdetect,
bank->base + OMAP4_GPIO_FALLINGDETECT);
- __raw_writel(bank->saved_risingdetect,
+ __raw_writel(bank->saved_risingdetect,
bank->base + OMAP4_GPIO_RISINGDETECT);
- l = __raw_readl(bank->base + OMAP4_GPIO_DATAIN);
-#endif
+ l = __raw_readl(bank->base + OMAP4_GPIO_DATAIN);
+ }
+
/* Check if any of the non-wakeup interrupt GPIOs have changed
* state. If so, generate an IRQ by software. This is
* horribly racy, but it's the best we can do to work around
@@ -2103,30 +2132,36 @@ void omap2_gpio_resume_after_retention(void)
if (gen) {
u32 old0, old1;
-#if defined(CONFIG_ARCH_OMAP2) || defined(CONFIG_ARCH_OMAP3)
- old0 = __raw_readl(bank->base + OMAP24XX_GPIO_LEVELDETECT0);
- old1 = __raw_readl(bank->base + OMAP24XX_GPIO_LEVELDETECT1);
+
+ if (cpu_is_omap24xx() || cpu_is_omap44xx()) {
+ old0 = __raw_readl(bank->base +
+ OMAP24XX_GPIO_LEVELDETECT0);
+ old1 = __raw_readl(bank->base +
+ OMAP24XX_GPIO_LEVELDETECT1);
__raw_writel(old0 | gen, bank->base +
OMAP24XX_GPIO_LEVELDETECT0);
__raw_writel(old1 | gen, bank->base +
OMAP24XX_GPIO_LEVELDETECT1);
- __raw_writel(old0, bank->base + OMAP24XX_GPIO_LEVELDETECT0);
- __raw_writel(old1, bank->base + OMAP24XX_GPIO_LEVELDETECT1);
-#endif
-#ifdef CONFIG_ARCH_OMAP4
- old0 = __raw_readl(bank->base +
+ __raw_writel(old0, bank->base +
+ OMAP24XX_GPIO_LEVELDETECT0);
+ __raw_writel(old1, bank->base +
+ OMAP24XX_GPIO_LEVELDETECT1);
+ }
+
+ if (cpu_is_omap44xx()) {
+ old0 = __raw_readl(bank->base +
OMAP4_GPIO_LEVELDETECT0);
- old1 = __raw_readl(bank->base +
+ old1 = __raw_readl(bank->base +
OMAP4_GPIO_LEVELDETECT1);
- __raw_writel(old0 | l, bank->base +
+ __raw_writel(old0 | l, bank->base +
OMAP4_GPIO_LEVELDETECT0);
- __raw_writel(old1 | l, bank->base +
+ __raw_writel(old1 | l, bank->base +
OMAP4_GPIO_LEVELDETECT1);
- __raw_writel(old0, bank->base +
+ __raw_writel(old0, bank->base +
OMAP4_GPIO_LEVELDETECT0);
- __raw_writel(old1, bank->base +
+ __raw_writel(old1, bank->base +
OMAP4_GPIO_LEVELDETECT1);
-#endif
+ }
}
}
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 8/9] omap2/3/4: Fix mach-omap2/serial.c for multiboot
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
` (6 preceding siblings ...)
2010-01-30 2:01 ` [PATCH 7/9] omap: Fix gpio.c for multi-omap for omap4 Tony Lindgren
@ 2010-01-30 2:01 ` Tony Lindgren
2010-01-30 2:01 ` [PATCH 9/9] omap2/3/4: Add omap4 into omap3_defconfnig Tony Lindgren
` (2 subsequent siblings)
10 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 2:01 UTC (permalink / raw)
To: linux-arm-kernel
Initialize UART4 only for 3630 and 44xx.
Signed-off-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/mach-omap2/serial.c | 27 ++++++++++++++++++++-------
1 files changed, 20 insertions(+), 7 deletions(-)
diff --git a/arch/arm/mach-omap2/serial.c b/arch/arm/mach-omap2/serial.c
index 21e51c5..9bbc2c5 100644
--- a/arch/arm/mach-omap2/serial.c
+++ b/arch/arm/mach-omap2/serial.c
@@ -108,7 +108,7 @@ static struct plat_serial8250_port serial_platform_data2[] = {
}
};
-#ifdef CONFIG_ARCH_OMAP4
+#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
static struct plat_serial8250_port serial_platform_data3[] = {
{
.irq = 70,
@@ -120,6 +120,15 @@ static struct plat_serial8250_port serial_platform_data3[] = {
.flags = 0
}
};
+
+static inline void omap2_set_globals_uart4(struct omap_globals *omap2_globals)
+{
+ serial_platform_data3[0].mapbase = omap2_globals->uart4_phys;
+}
+#else
+static inline void omap2_set_globals_uart4(struct omap_globals *omap2_globals)
+{
+}
#endif
void __init omap2_set_globals_uart(struct omap_globals *omap2_globals)
@@ -127,9 +136,8 @@ void __init omap2_set_globals_uart(struct omap_globals *omap2_globals)
serial_platform_data0[0].mapbase = omap2_globals->uart1_phys;
serial_platform_data1[0].mapbase = omap2_globals->uart2_phys;
serial_platform_data2[0].mapbase = omap2_globals->uart3_phys;
-#ifdef CONFIG_ARCH_OMAP4
- serial_platform_data3[0].mapbase = omap2_globals->uart4_phys;
-#endif
+ if (cpu_is_omap3630() || cpu_is_omap44xx())
+ omap2_set_globals_uart4(omap2_globals);
}
static inline unsigned int __serial_read_reg(struct uart_port *up,
@@ -574,7 +582,7 @@ static struct omap_uart_state omap_uart[] = {
},
},
},
-#ifdef CONFIG_ARCH_OMAP4
+#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4)
{
.pdev = {
.name = "serial8250",
@@ -722,8 +730,13 @@ void __init omap_serial_init_port(int port)
*/
void __init omap_serial_init(void)
{
- int i;
+ int i, nr_ports;
+
+ if (!(cpu_is_omap3630() || cpu_is_omap4430()))
+ nr_ports = 3;
+ else
+ nr_ports = ARRAY_SIZE(omap_uart);
- for (i = 0; i < ARRAY_SIZE(omap_uart); i++)
+ for (i = 0; i < nr_ports; i++)
omap_serial_init_port(i);
}
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 9/9] omap2/3/4: Add omap4 into omap3_defconfnig
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
` (7 preceding siblings ...)
2010-01-30 2:01 ` [PATCH 8/9] omap2/3/4: Fix mach-omap2/serial.c for multiboot Tony Lindgren
@ 2010-01-30 2:01 ` Tony Lindgren
2010-01-30 11:09 ` [PATCH 0/9] Initial multi-omap support for omap4 Shilimkar, Santosh
2010-01-30 12:51 ` Shilimkar, Santosh
10 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 2:01 UTC (permalink / raw)
To: linux-arm-kernel
Add omap4 into omap3_defconfig. Note that this does not
yet boot on omap4, but boots on omap2 and omap3.
Also note that CONFIG_SMP does not currently work on
uniprocessor ARMs.
Signed-off-by: Tony Lindgren <tony@atomide.com>
---
arch/arm/configs/omap3_defconfig | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/arch/arm/configs/omap3_defconfig b/arch/arm/configs/omap3_defconfig
index 2bc80d7..714835e 100644
--- a/arch/arm/configs/omap3_defconfig
+++ b/arch/arm/configs/omap3_defconfig
@@ -239,7 +239,7 @@ CONFIG_ARCH_OMAP_OTG=y
CONFIG_ARCH_OMAP2PLUS=y
CONFIG_ARCH_OMAP2=y
CONFIG_ARCH_OMAP3=y
-# CONFIG_ARCH_OMAP4 is not set
+CONFIG_ARCH_OMAP4=y
#
# OMAP Feature Selections
@@ -295,6 +295,7 @@ CONFIG_MACH_OMAP_ZOOM3=y
CONFIG_MACH_CM_T35=y
CONFIG_MACH_IGEP0020=y
CONFIG_MACH_OMAP_3630SDP=y
+CONFIG_MACH_OMAP_4430SDP=y
# CONFIG_OMAP3_EMU is not set
# CONFIG_OMAP3_SDRC_AC_TIMING is not set
@@ -334,6 +335,7 @@ CONFIG_ARM_L1_CACHE_SHIFT=6
# CONFIG_ARM_ERRATA_430973 is not set
# CONFIG_ARM_ERRATA_458693 is not set
# CONFIG_ARM_ERRATA_460075 is not set
+CONFIG_ARM_GIC=y
CONFIG_COMMON_CLKDEV=y
#
@@ -350,6 +352,7 @@ CONFIG_TICK_ONESHOT=y
CONFIG_NO_HZ=y
CONFIG_HIGH_RES_TIMERS=y
CONFIG_GENERIC_CLOCKEVENTS_BUILD=y
+# CONFIG_SMP is not set
CONFIG_VMSPLIT_3G=y
# CONFIG_VMSPLIT_2G is not set
# CONFIG_VMSPLIT_1G is not set
@@ -361,6 +364,7 @@ CONFIG_HZ=128
# CONFIG_THUMB2_KERNEL is not set
CONFIG_AEABI=y
CONFIG_OABI_COMPAT=y
+CONFIG_ARCH_HAS_HOLES_MEMORYMODEL=y
# CONFIG_ARCH_SPARSEMEM_DEFAULT is not set
# CONFIG_ARCH_SELECT_MEMORY_MODEL is not set
# CONFIG_HIGHMEM is not set
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 0/9] Initial multi-omap support for omap4
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
` (8 preceding siblings ...)
2010-01-30 2:01 ` [PATCH 9/9] omap2/3/4: Add omap4 into omap3_defconfnig Tony Lindgren
@ 2010-01-30 11:09 ` Shilimkar, Santosh
2010-01-30 16:18 ` Tony Lindgren
2010-01-30 12:51 ` Shilimkar, Santosh
10 siblings, 1 reply; 17+ messages in thread
From: Shilimkar, Santosh @ 2010-01-30 11:09 UTC (permalink / raw)
To: linux-arm-kernel
Tony,
> -----Original Message-----
> From: linux-omap-owner at vger.kernel.org [mailto:linux-omap-owner at vger.kernel.org] On Behalf Of Tony
> Lindgren
> Sent: Saturday, January 30, 2010 7:31 AM
> To: linux-arm-kernel at lists.infradead.org
> Cc: linux-omap at vger.kernel.org
> Subject: [PATCH 0/9] Initial multi-omap support for omap4
>
> Hi all,
>
> These patches allow compiling in also omap4 into the multi-omap
> configuration. As I don't yet have omap4, I've only boot tested
> these on omap2 and omap3.
>
> Somebody with an omap4 board please boot test these with the
> omap3_defconfig and see what happens.. You might want to enable
> DEBUG_LL and EARLY_PRINTK with earlyprintk on the cmdline too.
Looks like this series have some dependent series because it doesn't
apply on mainline.
So I tested this directly on linux-omap "multi-omap4" branch. It boots sufficiently
but doesn't proceed after "brd_init". Didn't get much time to debug so attached log
Regards,
Santosh
-------------- next part --------------
A non-text attachment was scrubbed...
Name: omap3_defconfig.log
Type: application/octet-stream
Size: 10866 bytes
Desc: omap3_defconfig.log
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20100130/4a7373c7/attachment-0001.obj>
^ permalink raw reply [flat|nested] 17+ messages in thread* [PATCH 0/9] Initial multi-omap support for omap4
2010-01-30 11:09 ` [PATCH 0/9] Initial multi-omap support for omap4 Shilimkar, Santosh
@ 2010-01-30 16:18 ` Tony Lindgren
0 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 16:18 UTC (permalink / raw)
To: linux-arm-kernel
* Shilimkar, Santosh <santosh.shilimkar@ti.com> [100130 03:07]:
> Tony,
> > -----Original Message-----
> > From: linux-omap-owner at vger.kernel.org [mailto:linux-omap-owner at vger.kernel.org] On Behalf Of Tony
> > Lindgren
> > Sent: Saturday, January 30, 2010 7:31 AM
> > To: linux-arm-kernel at lists.infradead.org
> > Cc: linux-omap at vger.kernel.org
> > Subject: [PATCH 0/9] Initial multi-omap support for omap4
> >
> > Hi all,
> >
> > These patches allow compiling in also omap4 into the multi-omap
> > configuration. As I don't yet have omap4, I've only boot tested
> > these on omap2 and omap3.
> >
> > Somebody with an omap4 board please boot test these with the
> > omap3_defconfig and see what happens.. You might want to enable
> > DEBUG_LL and EARLY_PRINTK with earlyprintk on the cmdline too.
> Looks like this series have some dependent series because it doesn't
> apply on mainline.
Sorry, forgot to mention that these are against the earlier
multi-omap patches. Basically stuff that's now queued for the
merge window in the omap-for-linus branch.
> So I tested this directly on linux-omap "multi-omap4" branch. It boots sufficiently
> but doesn't proceed after "brd_init". Didn't get much time to debug so attached log
Thanks for testing. Yeah these same are in the multi-omap4
branch also.
Regards,
Tony
^ permalink raw reply [flat|nested] 17+ messages in thread
* [PATCH 0/9] Initial multi-omap support for omap4
2010-01-30 2:01 [PATCH 0/9] Initial multi-omap support for omap4 Tony Lindgren
` (9 preceding siblings ...)
2010-01-30 11:09 ` [PATCH 0/9] Initial multi-omap support for omap4 Shilimkar, Santosh
@ 2010-01-30 12:51 ` Shilimkar, Santosh
2010-01-30 16:24 ` Tony Lindgren
10 siblings, 1 reply; 17+ messages in thread
From: Shilimkar, Santosh @ 2010-01-30 12:51 UTC (permalink / raw)
To: linux-arm-kernel
> > Hi all,
> >
> > These patches allow compiling in also omap4 into the multi-omap
> > configuration. As I don't yet have omap4, I've only boot tested
> > these on omap2 and omap3.
> >
> > Somebody with an omap4 board please boot test these with the
> > omap3_defconfig and see what happens.. You might want to enable
> > DEBUG_LL and EARLY_PRINTK with earlyprintk on the cmdline too.
> Looks like this series have some dependent series because it doesn't
> apply on mainline.
>
> So I tested this directly on linux-omap "multi-omap4" branch. It boots sufficiently
> but doesn't proceed after "brd_init". Didn't get much time to debug so attached log
Stand alone omap_4430sdp_defconfig also didn't fully boot on the linux-omap "multi-omap4".
The log below shows that the serial platform data isn't configured correctly.
<6>io scheduler deadline registered
<6>io scheduler cfq registered (default)
<6>Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
<6>serial8250.0: ttyS0 at MMIO 0x4806a000 (irq = 104) is a ST16654
<6>serial8250.1: ttyS0 at MMIO 0x4806a000 (irq = 105) is a ST16654
Below patch to fix the boot for omap_4430sdp_defconfig. Small typo really.
diff --git a/arch/arm/plat-omap/include/plat/serial.h b/arch/arm/plat-omap/inclu
index 67ffa08..83dce4c 100644
--- a/arch/arm/plat-omap/include/plat/serial.h
+++ b/arch/arm/plat-omap/include/plat/serial.h
@@ -33,7 +33,7 @@
/* OMAP4 serial ports */
#define OMAP4_UART1_BASE OMAP2_UART1_BASE
-#define OMAP4_UART2_BASE OMAP2_UART1_BASE
+#define OMAP4_UART2_BASE OMAP2_UART2_BASE
#define OMAP4_UART3_BASE 0x48020000
#define OMAP4_UART4_BASE 0x4806e000
For multi-omap build, for now I need to disable
[*] Reset unused clocks during boot
With this OMAP4430 boots with omap3_defconfig :)
Regards,
Santosh
^ permalink raw reply related [flat|nested] 17+ messages in thread* [PATCH 0/9] Initial multi-omap support for omap4
2010-01-30 12:51 ` Shilimkar, Santosh
@ 2010-01-30 16:24 ` Tony Lindgren
2010-01-30 17:54 ` Shilimkar, Santosh
0 siblings, 1 reply; 17+ messages in thread
From: Tony Lindgren @ 2010-01-30 16:24 UTC (permalink / raw)
To: linux-arm-kernel
* Shilimkar, Santosh <santosh.shilimkar@ti.com> [100130 04:49]:
> > > Hi all,
> > >
> > > These patches allow compiling in also omap4 into the multi-omap
> > > configuration. As I don't yet have omap4, I've only boot tested
> > > these on omap2 and omap3.
> > >
> > > Somebody with an omap4 board please boot test these with the
> > > omap3_defconfig and see what happens.. You might want to enable
> > > DEBUG_LL and EARLY_PRINTK with earlyprintk on the cmdline too.
> > Looks like this series have some dependent series because it doesn't
> > apply on mainline.
> >
> > So I tested this directly on linux-omap "multi-omap4" branch. It boots sufficiently
> > but doesn't proceed after "brd_init". Didn't get much time to debug so attached log
>
> Stand alone omap_4430sdp_defconfig also didn't fully boot on the linux-omap "multi-omap4".
> The log below shows that the serial platform data isn't configured correctly.
>
> <6>io scheduler deadline registered
> <6>io scheduler cfq registered (default)
> <6>Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
> <6>serial8250.0: ttyS0 at MMIO 0x4806a000 (irq = 104) is a ST16654
> <6>serial8250.1: ttyS0 at MMIO 0x4806a000 (irq = 105) is a ST16654
>
> Below patch to fix the boot for omap_4430sdp_defconfig. Small typo really.
>
> diff --git a/arch/arm/plat-omap/include/plat/serial.h b/arch/arm/plat-omap/inclu
> index 67ffa08..83dce4c 100644
> --- a/arch/arm/plat-omap/include/plat/serial.h
> +++ b/arch/arm/plat-omap/include/plat/serial.h
> @@ -33,7 +33,7 @@
>
> /* OMAP4 serial ports */
> #define OMAP4_UART1_BASE OMAP2_UART1_BASE
> -#define OMAP4_UART2_BASE OMAP2_UART1_BASE
> +#define OMAP4_UART2_BASE OMAP2_UART2_BASE
> #define OMAP4_UART3_BASE 0x48020000
> #define OMAP4_UART4_BASE 0x4806e000
Heh OK :) Sounds like at this point it makes sense to merge
that into the original patch redo omap-for-linus partially.
Can I also add your Acked-by for these patches then?
> For multi-omap build, for now I need to disable
> [*] Reset unused clocks during boot
Sounds like omap4 has some clocks left on from the bootloader
that it should clk_get and clk_enable during init. That should
be easy to track if you boot with "debug" in your cmdline and
take a look at the list of unused clocks that are shut down
with late_initcall.
> With this OMAP4430 boots with omap3_defconfig :)
Cool, thanks, good to hear!
Now the only omap2/3/4 that's not booting with omap3_defconfig
is 2430 because of the different clock offsets compare dot 2420.
That should get fixed eventually though.
Regards,
Tony
^ permalink raw reply [flat|nested] 17+ messages in thread
* [PATCH 0/9] Initial multi-omap support for omap4
2010-01-30 16:24 ` Tony Lindgren
@ 2010-01-30 17:54 ` Shilimkar, Santosh
2010-02-01 19:11 ` Tony Lindgren
0 siblings, 1 reply; 17+ messages in thread
From: Shilimkar, Santosh @ 2010-01-30 17:54 UTC (permalink / raw)
To: linux-arm-kernel
> -----Original Message-----
> From: Tony Lindgren [mailto:tony at atomide.com]
> Sent: Saturday, January 30, 2010 9:55 PM
> To: Shilimkar, Santosh
> Cc: linux-arm-kernel at lists.infradead.org; linux-omap at vger.kernel.org
> Subject: Re: [PATCH 0/9] Initial multi-omap support for omap4
>
> * Shilimkar, Santosh <santosh.shilimkar@ti.com> [100130 04:49]:
> > > > Hi all,
> > > >
> > > > These patches allow compiling in also omap4 into the multi-omap
> > > > configuration. As I don't yet have omap4, I've only boot tested
> > > > these on omap2 and omap3.
> > > >
> > > > Somebody with an omap4 board please boot test these with the
> > > > omap3_defconfig and see what happens.. You might want to enable
> > > > DEBUG_LL and EARLY_PRINTK with earlyprintk on the cmdline too.
> > > Looks like this series have some dependent series because it doesn't
> > > apply on mainline.
> > >
> > > So I tested this directly on linux-omap "multi-omap4" branch. It boots sufficiently
> > > but doesn't proceed after "brd_init". Didn't get much time to debug so attached log
> >
> > Stand alone omap_4430sdp_defconfig also didn't fully boot on the linux-omap "multi-omap4".
> > The log below shows that the serial platform data isn't configured correctly.
> >
> > <6>io scheduler deadline registered
> > <6>io scheduler cfq registered (default)
> > <6>Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
> > <6>serial8250.0: ttyS0 at MMIO 0x4806a000 (irq = 104) is a ST16654
> > <6>serial8250.1: ttyS0 at MMIO 0x4806a000 (irq = 105) is a ST16654
> >
> > Below patch to fix the boot for omap_4430sdp_defconfig. Small typo really.
> >
> > diff --git a/arch/arm/plat-omap/include/plat/serial.h b/arch/arm/plat-omap/inclu
> > index 67ffa08..83dce4c 100644
> > --- a/arch/arm/plat-omap/include/plat/serial.h
> > +++ b/arch/arm/plat-omap/include/plat/serial.h
> > @@ -33,7 +33,7 @@
> >
> > /* OMAP4 serial ports */
> > #define OMAP4_UART1_BASE OMAP2_UART1_BASE
> > -#define OMAP4_UART2_BASE OMAP2_UART1_BASE
> > +#define OMAP4_UART2_BASE OMAP2_UART2_BASE
> > #define OMAP4_UART3_BASE 0x48020000
> > #define OMAP4_UART4_BASE 0x4806e000
>
> Heh OK :) Sounds like at this point it makes sense to merge
> that into the original patch redo omap-for-linus partially.
>
> Can I also add your Acked-by for these patches then?
Yes please.
> > For multi-omap build, for now I need to disable
> > [*] Reset unused clocks during boot
>
> Sounds like omap4 has some clocks left on from the bootloader
> that it should clk_get and clk_enable during init. That should
> be easy to track if you boot with "debug" in your cmdline and
> take a look at the list of unused clocks that are shut down
> with late_initcall.
I know it hangs when it tries to cut down UART3 ( console) clock.
The clock support got just recently merged and drivers are not
yet migrated so, need to still depend on bootloader. The work
is ongoing and soon the patches will be pushed. Few drivers
are planned to be handled in hwmod way so we were holding these
patches.
> > With this OMAP4430 boots with omap3_defconfig :)
>
> Cool, thanks, good to hear!
>
> Now the only omap2/3/4 that's not booting with omap3_defconfig
> is 2430 because of the different clock offsets compare dot 2420.
> That should get fixed eventually though.
>
> Regards,
>
> Tony
^ permalink raw reply [flat|nested] 17+ messages in thread
* [PATCH 0/9] Initial multi-omap support for omap4
2010-01-30 17:54 ` Shilimkar, Santosh
@ 2010-02-01 19:11 ` Tony Lindgren
0 siblings, 0 replies; 17+ messages in thread
From: Tony Lindgren @ 2010-02-01 19:11 UTC (permalink / raw)
To: linux-arm-kernel
* Shilimkar, Santosh <santosh.shilimkar@ti.com> [100130 09:52]:
> > -----Original Message-----
> > From: Tony Lindgren [mailto:tony at atomide.com]
> > Sent: Saturday, January 30, 2010 9:55 PM
> > To: Shilimkar, Santosh
> > Cc: linux-arm-kernel at lists.infradead.org; linux-omap at vger.kernel.org
> > Subject: Re: [PATCH 0/9] Initial multi-omap support for omap4
> >
> > * Shilimkar, Santosh <santosh.shilimkar@ti.com> [100130 04:49]:
> > > > > Hi all,
> > > > >
> > > > > These patches allow compiling in also omap4 into the multi-omap
> > > > > configuration. As I don't yet have omap4, I've only boot tested
> > > > > these on omap2 and omap3.
> > > > >
> > > > > Somebody with an omap4 board please boot test these with the
> > > > > omap3_defconfig and see what happens.. You might want to enable
> > > > > DEBUG_LL and EARLY_PRINTK with earlyprintk on the cmdline too.
> > > > Looks like this series have some dependent series because it doesn't
> > > > apply on mainline.
> > > >
> > > > So I tested this directly on linux-omap "multi-omap4" branch. It boots sufficiently
> > > > but doesn't proceed after "brd_init". Didn't get much time to debug so attached log
> > >
> > > Stand alone omap_4430sdp_defconfig also didn't fully boot on the linux-omap "multi-omap4".
> > > The log below shows that the serial platform data isn't configured correctly.
> > >
> > > <6>io scheduler deadline registered
> > > <6>io scheduler cfq registered (default)
> > > <6>Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
> > > <6>serial8250.0: ttyS0 at MMIO 0x4806a000 (irq = 104) is a ST16654
> > > <6>serial8250.1: ttyS0 at MMIO 0x4806a000 (irq = 105) is a ST16654
> > >
> > > Below patch to fix the boot for omap_4430sdp_defconfig. Small typo really.
> > >
> > > diff --git a/arch/arm/plat-omap/include/plat/serial.h b/arch/arm/plat-omap/inclu
> > > index 67ffa08..83dce4c 100644
> > > --- a/arch/arm/plat-omap/include/plat/serial.h
> > > +++ b/arch/arm/plat-omap/include/plat/serial.h
> > > @@ -33,7 +33,7 @@
> > >
> > > /* OMAP4 serial ports */
> > > #define OMAP4_UART1_BASE OMAP2_UART1_BASE
> > > -#define OMAP4_UART2_BASE OMAP2_UART1_BASE
> > > +#define OMAP4_UART2_BASE OMAP2_UART2_BASE
> > > #define OMAP4_UART3_BASE 0x48020000
> > > #define OMAP4_UART4_BASE 0x4806e000
I've refreshed the second patch in the earlier multi-omap series
with your fix above.
> > Heh OK :) Sounds like at this point it makes sense to merge
> > that into the original patch redo omap-for-linus partially.
> >
> > Can I also add your Acked-by for these patches then?
> Yes please.
OK, added your Acked-by to all the omap4 patches. Also fixed
three checkpatch.pl warnings about long lines for the gpio patch.
> > > For multi-omap build, for now I need to disable
> > > [*] Reset unused clocks during boot
> >
> > Sounds like omap4 has some clocks left on from the bootloader
> > that it should clk_get and clk_enable during init. That should
> > be easy to track if you boot with "debug" in your cmdline and
> > take a look at the list of unused clocks that are shut down
> > with late_initcall.
> I know it hangs when it tries to cut down UART3 ( console) clock.
> The clock support got just recently merged and drivers are not
> yet migrated so, need to still depend on bootloader. The work
> is ongoing and soon the patches will be pushed. Few drivers
> are planned to be handled in hwmod way so we were holding these
> patches.
OK
Tony
^ permalink raw reply [flat|nested] 17+ messages in thread