uncompress.h 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. /*
  2. * arch/arm/mach-aaec2000/include/mach/uncompress.h
  3. *
  4. * Copyright (c) 2005 Nicolas Bellido Y Ortega
  5. *
  6. * This program is free software; you can redistribute it and/or modify
  7. * it under the terms of the GNU General Public License version 2 as
  8. * published by the Free Software Foundation.
  9. */
  10. #ifndef __ASM_ARCH_UNCOMPRESS_H
  11. #define __ASM_ARCH_UNCOMPRESS_H
  12. #include "hardware.h"
  13. #define UART(x) (*(volatile unsigned long *)(serial_port + (x)))
  14. static void putc(int c)
  15. {
  16. unsigned long serial_port;
  17. do {
  18. serial_port = _UART3_BASE;
  19. if (UART(UART_CR) & UART_CR_EN) break;
  20. serial_port = _UART1_BASE;
  21. if (UART(UART_CR) & UART_CR_EN) break;
  22. serial_port = _UART2_BASE;
  23. if (UART(UART_CR) & UART_CR_EN) break;
  24. return;
  25. } while (0);
  26. /* wait for space in the UART's transmitter */
  27. while ((UART(UART_SR) & UART_SR_TxFF))
  28. barrier();
  29. /* send the character out. */
  30. UART(UART_DR) = c;
  31. }
  32. static inline void flush(void)
  33. {
  34. }
  35. #define arch_decomp_setup()
  36. #define arch_decomp_wdog()
  37. #endif /* __ASM_ARCH_UNCOMPRESS_H */