1 /* SPDX-License-Identifier: GPL-2.0-or-later */
3 * arch/arm/mach-prima2/include/mach/debug-macro.S
5 * Copyright (c) 2011 Cambridge Silicon Radio Limited, a CSR plc group company.
8 #define SIRF_LLUART_TXFIFO_STATUS 0x0114
9 #define SIRF_LLUART_TXFIFO_DATA 0x0118
11 #define SIRF_LLUART_TXFIFO_FULL (1 << 5)
13 #ifdef CONFIG_DEBUG_SIRFATLAS7_UART0
14 #define SIRF_LLUART_TXFIFO_EMPTY (1 << 8)
16 #define SIRF_LLUART_TXFIFO_EMPTY (1 << 6)
20 .macro addruart, rp, rv, tmp
21 ldr \rp, =CONFIG_DEBUG_UART_PHYS @ physical
22 ldr \rv, =CONFIG_DEBUG_UART_VIRT @ virtual
26 str \rd, [\rx, #SIRF_LLUART_TXFIFO_DATA]
33 1001: ldr \rd, [\rx, #SIRF_LLUART_TXFIFO_STATUS]
34 tst \rd, #SIRF_LLUART_TXFIFO_EMPTY