#include <config.h>
#include <stdint.h>
#include <util.h>
#include <machine/io.h>
#include <plat/machine/devices.h>
#define UARTDR 0x000
#define UARTFR 0x018
#define PL011_UARTFR_TXFF (1 << 5)
#define UART_REG(x) ((volatile uint32_t *)(UART0_PPTR + (x)))
#if defined(CONFIG_DEBUG_BUILD) || defined(CONFIG_PRINTING)
void
putDebugChar(unsigned char c)
{
while ((*UART_REG(UARTFR) & PL011_UARTFR_TXFF) != 0);
*UART_REG(UARTDR) = c;
}
#endif
#ifdef CONFIG_DEBUG_BUILD
unsigned char
getDebugChar(void)
{
return 0;
}
#endif