From 852663d94f0cc44199c31c0e42d4801302f41705 Mon Sep 17 00:00:00 2001 From: Pawel Moll Date: Tue, 4 Sep 2012 17:06:20 +0100 Subject: ARM: vexpress: Make the debug UART detection more specific Base the UART detection heuristic on architecturally defined MIDR register instead of implementation dependent CBAR. The only tile using the original memory map is V2P-CA9 with Cortex A9 r0p1, which MIDR contains value 0x410fc091. Signed-off-by: Pawel Moll --- arch/arm/include/debug/vexpress.S | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'arch/arm/include') diff --git a/arch/arm/include/debug/vexpress.S b/arch/arm/include/debug/vexpress.S index 9f509f55d07..0c6abbf4c82 100644 --- a/arch/arm/include/debug/vexpress.S +++ b/arch/arm/include/debug/vexpress.S @@ -23,12 +23,14 @@ .macro addruart,rp,rv,tmp @ Make an educated guess regarding the memory map: - @ - the original A9 core tile, which has MPCore peripherals - @ located at 0x1e000000, should use UART at 0x10009000 + @ - the original A9 core tile (based on ARM Cortex-A9 r0p1) + @ should use UART at 0x10009000 @ - all other (RS1 complaint) tiles use UART mapped @ at 0x1c090000 - mrc p15, 4, \tmp, c15, c0, 0 - cmp \tmp, #0x1e000000 + mrc p15, 0, \rp, c0, c0, 0 + movw \rv, #0xc091 + movt \rv, #0x410f + cmp \rp, \rv @ Original memory map moveq \rp, #DEBUG_LL_UART_OFFSET -- cgit v1.2.3 From d892a91730013b306cef3b55be6cc0b2755d6d24 Mon Sep 17 00:00:00 2001 From: Arnd Bergmann Date: Thu, 8 Nov 2012 14:05:23 +0000 Subject: ARM: vexpress: fix ll debug code when building multiplatform After "ARM: vexpress: Make the debug UART detection more specific", building allyesconfig in linux-next now gives me: arch/arm/kernel/debug.S: Assembler messages: arch/arm/kernel/debug.S:81: Error: selected processor does not support ARM mode `movw r2,#0xc 091' arch/arm/kernel/debug.S:81: Error: selected processor does not support ARM mode `movt r2,#0x4 10f' arch/arm/kernel/debug.S:97: Error: selected processor does not support ARM mode `movw r2,#0xc 091' arch/arm/kernel/debug.S:97: Error: selected processor does not support ARM mode `movt r2,#0x4 10f' arch/arm/kernel/debug.S:104: Error: selected processor does not support ARM mode `movw r3,#0x c091' arch/arm/kernel/debug.S:104: Error: selected processor does not support ARM mode `movt r3,#0x 410f' Since the code can never get executed on ARMv6 but might be built in a configuration that has ARMv6 enabled, it's safe to just mark it in the assembly source for being ARMv7-only. Signed-off-by: Arnd Bergmann Acked-by: Pawel Moll --- arch/arm/include/debug/vexpress.S | 1 + 1 file changed, 1 insertion(+) (limited to 'arch/arm/include') diff --git a/arch/arm/include/debug/vexpress.S b/arch/arm/include/debug/vexpress.S index 0c6abbf4c82..dc8e882a625 100644 --- a/arch/arm/include/debug/vexpress.S +++ b/arch/arm/include/debug/vexpress.S @@ -21,6 +21,7 @@ #if defined(CONFIG_DEBUG_VEXPRESS_UART0_DETECT) .macro addruart,rp,rv,tmp + .arch armv7-a @ Make an educated guess regarding the memory map: @ - the original A9 core tile (based on ARM Cortex-A9 r0p1) -- cgit v1.2.3