[prev in list] [next in list] [prev in thread] [next in thread]
List: linux-arm-kernel
Subject: Re: [patch 10/25] mxc: add debug-macro.S
From: Juergen Beisert <jbe () pengutronix ! de>
Date: 2008-06-30 10:48:57
Message-ID: 200806301248.57696.jbe () pengutronix ! de
[Download RAW message or body]
Fixed revision. Any idea how to manage Daniel's patch and this patch series
in the case of debug-macro.S?
Subject: [@num@/@total@] MXC: add debug-macro.S for mxc
From: Sascha Hauer <s.hauer@pengutronix.de>
This patch adds debug-macro.S for arch-mxc
Disadvantage: Due to the board specific UART definition, these macros (and
compile time) will fail for multi board kernels.
Changes since last review:
- spelling fixed
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
include/asm-arm/arch-mxc/board-mx31ads.h | 5 ++++
include/asm-arm/arch-mxc/debug-macro.S | 38 +++++++++++++++++++++++++++++++
2 files changed, 43 insertions(+)
Index: include/asm-arm/arch-mxc/debug-macro.S
===================================================================
--- /dev/null
+++ include/asm-arm/arch-mxc/debug-macro.S
@@ -0,0 +1,38 @@
+/* linux/include/asm-arm/arch-imx/debug-macro.S
+ *
+ * Debugging macro include header
+ *
+ * Copyright (C) 1994-1999 Russell King
+ * Moved from linux/arch/arm/kernel/debug.S by Ben Dooks
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ */
+
+#include <asm/arch/hardware.h>
+
+#ifdef CONFIG_MACH_MX31ADS
+#include <asm/arch/board-mx31ads.h>
+#endif
+
+ .macro addruart,rx
+ mrc p15, 0, \rx, c1, c0
+ tst \rx, #1 @ MMU enabled?
+ ldreq \rx, =MXC_LL_UART_PADDR @ physical
+ ldrne \rx, =MXC_LL_UART_VADDR @ virtual
+ .endm
+
+ .macro senduart,rd,rx
+ str \rd, [\rx, #0x40] @ TXDATA
+ .endm
+
+ .macro waituart,rd,rx
+ .endm
+
+ .macro busyuart,rd,rx
+1002: ldr \rd, [\rx, #0x98] @ SR2
+ tst \rd, #1 << 3 @ TXDC
+ beq 1002b @ wait until transmit done
+ .endm
Index: include/asm-arm/arch-mxc/board-mx31ads.h
===================================================================
--- include/asm-arm/arch-mxc/board-mx31ads.h.orig
+++ include/asm-arm/arch-mxc/board-mx31ads.h
@@ -109,4 +109,9 @@
#define MXC_MAX_EXP_IO_LINES 16
+/* mandatory for CONFIG_LL_DEBUG */
+
+#define MXC_LL_UART_PADDR UART1_BASE_ADDR
+#define MXC_LL_UART_VADDR AIPS1_IO_ADDRESS(UART1_BASE_ADDR)
+
#endif /* __ASM_ARCH_MXC_BOARD_MX31ADS_H__ */
--
Dipl.-Ing. Juergen Beisert | http://www.pengutronix.de
Pengutronix - Linux Solutions for Science and Industry
Handelsregister: Amtsgericht Hildesheim, HRA 2686
Vertretung Sued/Muenchen, Germany
Phone: +49-8766-939 228 | Fax: +49-5121-206917-9
-------------------------------------------------------------------
List admin: http://lists.arm.linux.org.uk/mailman/listinfo/linux-arm-kernel
FAQ: http://www.arm.linux.org.uk/mailinglists/faq.php
Etiquette: http://www.arm.linux.org.uk/mailinglists/etiquette.php
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic