MOXA linux-2.6.x / linux-2.6.19-uc1 from UC-7110-LX-BOOTLOADER-1.9_VERSION-4.2.tgz
[linux-2.6.19-moxart.git] / include / asm-arm / arch-p2001 / debug-macro.S
blobab0757326619900af5d33925c3ee99d54b41b888
1 /* linux/include/asm-arm/arch-p2001/debug-macro.S
2  *
3  * Debugging macro include header
4  *
5  * by Hyok S. Choi <hyok.choi@samsung.com>
6  *
7  * This program is free software; you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License version 2 as
9  * published by the Free Software Foundation.
10  *
13                 /* UART base address */
14                 .macro  addruart,rx
15                 mov     \rx, #0x00140000
16                 .endm
18                 /* send char */
19                 .macro  senduart,rd,rx
20                 strb    \rd, [\rx]
21                 .endm
23                 /* wait for end of transmission */
24                 .macro  busyuart,rd,rx
25 1001:           ldrb    \rd, [\rx, #0x24]
26                 cmp     \rd, #0
27                 bne     1001b
28                 .endm
30                 /* wait for fifo space */
31                 /* quickest way here: test for >0x20 chars in fifo */
32                 .macro  waituart,rd,rx
33 1001:           ldrb    \rd, [\rx, #0x24]
34                 tst     \rd, #0x20
35                 bne     1001b
36                 .endm