uncompress.h 728 B

123456789101112131415161718192021222324252627282930313233343536
  1. /*
  2. * linux/include/asm-arm/arch-iop33x/uncompress.h
  3. */
  4. #include <asm/types.h>
  5. #include <asm/mach-types.h>
  6. #include <linux/serial_reg.h>
  7. #include <asm/hardware.h>
  8. static volatile u32 *uart_base;
  9. #define TX_DONE (UART_LSR_TEMT|UART_LSR_THRE)
  10. static inline void putc(char c)
  11. {
  12. while ((uart_base[UART_LSR] & TX_DONE) != TX_DONE)
  13. barrier();
  14. *uart_base = c;
  15. }
  16. static inline void flush(void)
  17. {
  18. }
  19. static __inline__ void __arch_decomp_setup(unsigned long arch_id)
  20. {
  21. if (machine_is_iq80331() || machine_is_iq80332())
  22. uart_base = (volatile u32 *)IOP331_UART0_PHYS;
  23. else
  24. uart_base = (volatile u32 *)0xfe800000;
  25. }
  26. /*
  27. * nothing to do
  28. */
  29. #define arch_decomp_setup() __arch_decomp_setup(arch_id)
  30. #define arch_decomp_wdog()