summaryrefslogtreecommitdiff
path: root/arch/arm/mach-msm/include/mach/debug-macro.S
diff options
context:
space:
mode:
authorPavel Machek <pavel@ucw.cz>2009-11-02 11:48:29 +0100
committerDaniel Walker <dwalker@fifo99.com>2009-11-20 06:40:05 -0800
commit6339f6695f84e48b42021c6df91d81b17308fe92 (patch)
tree38be250cc731428524eba5f1c598771f71780304 /arch/arm/mach-msm/include/mach/debug-macro.S
parent333a07437c31ea8c16a2b82071629a540ae1e50f (diff)
msm: make debugging UART (for DEBUG_LL) configurable
Provides options to select one of the three "lowspeed" UARTs on MSM7k SoCs for DEBUG_LL output from the zImage decompressor and kernel. Signed-off-by: Brian Swetland <swetland@google.com> Signed-off-by: Pavel Machek <pavel@ucw.cz> Signed-off-by: Daniel Walker <dwalker@codeaurora.org>
Diffstat (limited to 'arch/arm/mach-msm/include/mach/debug-macro.S')
-rw-r--r--arch/arm/mach-msm/include/mach/debug-macro.S24
1 files changed, 17 insertions, 7 deletions
diff --git a/arch/arm/mach-msm/include/mach/debug-macro.S b/arch/arm/mach-msm/include/mach/debug-macro.S
index 1db3c97dbc49..d48747ebcd3d 100644
--- a/arch/arm/mach-msm/include/mach/debug-macro.S
+++ b/arch/arm/mach-msm/include/mach/debug-macro.S
@@ -14,15 +14,18 @@
*
*/
+
+
#include <mach/hardware.h>
#include <mach/msm_iomap.h>
+#ifdef CONFIG_MSM_DEBUG_UART
.macro addruart,rx
@ see if the MMU is enabled and select appropriate base address
mrc p15, 0, \rx, c1, c0
tst \rx, #1
- ldreq \rx, =MSM_UART1_PHYS
- movne \rx, #0
+ ldreq \rx, =MSM_DEBUG_UART_PHYS
+ ldrne \rx, =MSM_DEBUG_UART_BASE
.endm
.macro senduart,rd,rx
@@ -32,13 +35,20 @@
.macro waituart,rd,rx
@ wait for TX_READY
- teq \rx, #0
- bne 2f
-1: ldr \rd, [\rx, #0x08]
+1001: ldr \rd, [\rx, #0x08]
tst \rd, #0x04
- beq 1b
-2:
+ beq 1001b
+ .endm
+#else
+ .macro addruart,rx
+ .endm
+
+ .macro senduart,rd,rx
+ .endm
+
+ .macro waituart,rd,rx
.endm
+#endif
.macro busyuart,rd,rx
.endm