Russell King | a09e64f | 2008-08-05 16:14:15 +0100 | [diff] [blame] | 1 | /* arch/arm/mach-imx/include/mach/debug-macro.S |
| 2 | * |
| 3 | * Debugging macro include header |
| 4 | * |
| 5 | * Copyright (C) 1994-1999 Russell King |
| 6 | * Moved from linux/arch/arm/kernel/debug.S by Ben Dooks |
| 7 | * |
| 8 | * This program is free software; you can redistribute it and/or modify |
| 9 | * it under the terms of the GNU General Public License version 2 as |
| 10 | * published by the Free Software Foundation. |
| 11 | * |
| 12 | */ |
| 13 | |
| 14 | #include <mach/hardware.h> |
| 15 | |
| 16 | #ifdef CONFIG_MACH_MX31ADS |
| 17 | #include <mach/board-mx31ads.h> |
| 18 | #endif |
| 19 | #ifdef CONFIG_MACH_PCM037 |
| 20 | #include <mach/board-pcm037.h> |
| 21 | #endif |
| 22 | #ifdef CONFIG_MACH_MX31LITE |
| 23 | #include <mach/board-mx31lite.h> |
| 24 | #endif |
| 25 | #ifdef CONFIG_MACH_MX27ADS |
| 26 | #include <mach/board-mx27ads.h> |
| 27 | #endif |
Ivo Clarysse | 6b91edd | 2009-04-15 15:39:27 +0200 | [diff] [blame] | 28 | #ifdef CONFIG_MACH_MX21ADS |
| 29 | #include <mach/board-mx21ads.h> |
| 30 | #endif |
Russell King | a09e64f | 2008-08-05 16:14:15 +0100 | [diff] [blame] | 31 | #ifdef CONFIG_MACH_PCM038 |
| 32 | #include <mach/board-pcm038.h> |
| 33 | #endif |
Fabio Estevam | 1553a1e | 2008-11-12 15:38:39 +0100 | [diff] [blame] | 34 | #ifdef CONFIG_MACH_MX31_3DS |
| 35 | #include <mach/board-mx31pdk.h> |
| 36 | #endif |
Ilya Yanok | 148854c | 2009-03-11 03:22:00 +0300 | [diff] [blame] | 37 | #ifdef CONFIG_MACH_QONG |
| 38 | #include <mach/board-qong.h> |
| 39 | #endif |
Sascha Hauer | 54df526 | 2009-02-06 15:42:26 +0100 | [diff] [blame] | 40 | #ifdef CONFIG_MACH_PCM043 |
| 41 | #include <mach/board-pcm043.h> |
| 42 | #endif |
Fabio Estevam | ec9be0d | 2009-04-16 12:45:01 -0700 | [diff] [blame] | 43 | #ifdef CONFIG_MACH_MX27_3DS |
| 44 | #include <mach/board-mx27pdk.h> |
| 45 | #endif |
Alberto Panizzo | 5e9145e | 2009-05-19 10:01:03 +0200 | [diff] [blame] | 46 | #ifdef CONFIG_MACH_ARMADILLO5X0 |
| 47 | #include <mach/board-armadillo5x0.h> |
| 48 | #endif |
Fabio Estevam | aefa1c6 | 2009-06-02 17:24:16 -0700 | [diff] [blame] | 49 | #ifdef CONFIG_MACH_MX35_3DS |
| 50 | #include <mach/board-mx35pdk.h> |
| 51 | #endif |
Daniel Schaeffer | 8c032ec | 2009-06-03 17:23:54 -0400 | [diff] [blame] | 52 | #ifdef CONFIG_MACH_MX27LITE |
| 53 | #include <mach/board-mx27lite.h> |
| 54 | #endif |
Russell King | a09e64f | 2008-08-05 16:14:15 +0100 | [diff] [blame] | 55 | .macro addruart,rx |
| 56 | mrc p15, 0, \rx, c1, c0 |
| 57 | tst \rx, #1 @ MMU enabled? |
| 58 | ldreq \rx, =MXC_LL_UART_PADDR @ physical |
| 59 | ldrne \rx, =MXC_LL_UART_VADDR @ virtual |
| 60 | .endm |
| 61 | |
| 62 | .macro senduart,rd,rx |
| 63 | str \rd, [\rx, #0x40] @ TXDATA |
| 64 | .endm |
| 65 | |
| 66 | .macro waituart,rd,rx |
| 67 | .endm |
| 68 | |
| 69 | .macro busyuart,rd,rx |
| 70 | 1002: ldr \rd, [\rx, #0x98] @ SR2 |
| 71 | tst \rd, #1 << 3 @ TXDC |
| 72 | beq 1002b @ wait until transmit done |
| 73 | .endm |