X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=Kernel%2Farch%2Farmv7%2Fdebug.c;h=7b9e55dd79e242708f7550e54d7cfa6321df2649;hb=72e1657f992d917aee5c0b5ca17bf730537629d1;hp=d75048edaf20489e7bbadf68e6d11accfb7b65aa;hpb=1501fe53f7cc9d2d7bcb30abac636a8afbee2f8b;p=tpg%2Facess2.git diff --git a/Kernel/arch/armv7/debug.c b/Kernel/arch/armv7/debug.c index d75048ed..7b9e55dd 100644 --- a/Kernel/arch/armv7/debug.c +++ b/Kernel/arch/armv7/debug.c @@ -23,8 +23,14 @@ void StartupPrint(const char *str); // === CODE === void Debug_PutCharDebug(char ch) { -// while( *(volatile Uint32*)(SERIAL_BASE + SERIAL_REG_FLAG) & SERIAL_FLAG_FULL ) + if(ch == '\n') + Debug_PutCharDebug('\r'); + + #if PLATFORM_is_tegra2 + // Tegra2 + while( !(*(volatile Uint32*)(UART0_BASE + 0x14) & (1 << 5)) ) ; + #endif // *(volatile Uint32*)(SERIAL_BASE + SERIAL_REG_DATA) = ch; *(volatile Uint32*)(UART0_BASE) = ch;