smpc.h 910 B

12345678910111213141516171819202122232425262728293031323334
  1. /*
  2. * include/asm-sh/saturn/smpc.h
  3. *
  4. * System Manager / Peripheral Control definitions.
  5. *
  6. * Copyright (C) 2002 Paul Mundt
  7. *
  8. * Released under the terms of the GNU GPL v2.0.
  9. */
  10. #ifndef __ASM_SH_SATURN_SMPC_H
  11. #define __ASM_SH_SATURN_SMPC_H
  12. #include <asm/io.h>
  13. #define SMPC_COMMAND 0x2010001f /* SMPC command register */
  14. #define SMPC_RESULT 0x2010005f /* SMPC result register */
  15. #define SMPC_STATUS 0x20100063 /* SMPC status register */
  16. #define SMPC_CMD_MSHON 0x0001 /* Master SH On */
  17. #define SMPC_CMD_SSHON 0x0002 /* Slave SH On */
  18. #define SMPC_CMD_SSHOFF 0x0003 /* Slave SH Off */
  19. #define SMPC_CMD_SNDON 0x0004 /* Sound On */
  20. #define SMPC_CMD_SNDOFF 0x0005 /* Sound Off */
  21. #define SMPC_CMD_CDON 0x0006 /* CD On */
  22. #define SMPC_CMD_CDOFF 0x0007 /* CD Off */
  23. static inline void smpc_barrier(void)
  24. {
  25. while ((ctrl_inb(SMPC_STATUS) & 0x0001) == 0x0001)
  26. ;
  27. }
  28. #endif /* __ASM_SH_SATURN_SMPC_H */