msp_slp_int.h 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. /*
  2. * Defines for the MSP interrupt controller.
  3. *
  4. * Copyright (C) 1999 MIPS Technologies, Inc. All rights reserved.
  5. * Author: Carsten Langgaard, carstenl@mips.com
  6. *
  7. * ########################################################################
  8. *
  9. * This program is free software; you can distribute it and/or modify it
  10. * under the terms of the GNU General Public License (Version 2) as
  11. * published by the Free Software Foundation.
  12. *
  13. * This program is distributed in the hope it will be useful, but WITHOUT
  14. * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  15. * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
  16. * for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License along
  19. * with this program; if not, write to the Free Software Foundation, Inc.,
  20. * 59 Temple Place - Suite 330, Boston MA 02111-1307, USA.
  21. *
  22. * ########################################################################
  23. */
  24. #ifndef _MSP_SLP_INT_H
  25. #define _MSP_SLP_INT_H
  26. /*
  27. * The PMC-Sierra SLP interrupts are arranged in a 3 level cascaded
  28. * hierarchical system. The first level are the direct MIPS interrupts
  29. * and are assigned the interrupt range 0-7. The second level is the SLM
  30. * interrupt controller and is assigned the range 8-39. The third level
  31. * comprises the Peripherial block, the PCI block, the PCI MSI block and
  32. * the SLP. The PCI interrupts and the SLP errors are handled by the
  33. * relevant subsystems so the core interrupt code needs only concern
  34. * itself with the Peripheral block. These are assigned interrupts in
  35. * the range 40-71.
  36. */
  37. /*
  38. * IRQs directly connected to CPU
  39. */
  40. #define MSP_MIPS_INTBASE 0
  41. #define MSP_INT_SW0 0 /* IRQ for swint0, C_SW0 */
  42. #define MSP_INT_SW1 1 /* IRQ for swint1, C_SW1 */
  43. #define MSP_INT_MAC0 2 /* IRQ for MAC 0, C_IRQ0 */
  44. #define MSP_INT_MAC1 3 /* IRQ for MAC 1, C_IRQ1 */
  45. #define MSP_INT_C_IRQ2 4 /* Wired off, C_IRQ2 */
  46. #define MSP_INT_VE 5 /* IRQ for Voice Engine, C_IRQ3 */
  47. #define MSP_INT_SLP 6 /* IRQ for SLM block, C_IRQ4 */
  48. #define MSP_INT_TIMER 7 /* IRQ for the MIPS timer, C_IRQ5 */
  49. /*
  50. * IRQs cascaded on CPU interrupt 4 (CAUSE bit 12, C_IRQ4)
  51. * These defines should be tied to the register definition for the SLM
  52. * interrupt routine. For now, just use hard-coded values.
  53. */
  54. #define MSP_SLP_INTBASE (MSP_MIPS_INTBASE + 8)
  55. #define MSP_INT_EXT0 (MSP_SLP_INTBASE + 0)
  56. /* External interrupt 0 */
  57. #define MSP_INT_EXT1 (MSP_SLP_INTBASE + 1)
  58. /* External interrupt 1 */
  59. #define MSP_INT_EXT2 (MSP_SLP_INTBASE + 2)
  60. /* External interrupt 2 */
  61. #define MSP_INT_EXT3 (MSP_SLP_INTBASE + 3)
  62. /* External interrupt 3 */
  63. /* Reserved 4-7 */
  64. /*
  65. *************************************************************************
  66. * DANGER/DANGER/DANGER/DANGER/DANGER/DANGER/DANGER/DANGER/DANGER/DANGER *
  67. * Some MSP produces have this interrupt labelled as Voice and some are *
  68. * SEC mbox ... *
  69. *************************************************************************
  70. */
  71. #define MSP_INT_SLP_VE (MSP_SLP_INTBASE + 8)
  72. /* Cascaded IRQ for Voice Engine*/
  73. #define MSP_INT_SLP_TDM (MSP_SLP_INTBASE + 9)
  74. /* TDM interrupt */
  75. #define MSP_INT_SLP_MAC0 (MSP_SLP_INTBASE + 10)
  76. /* Cascaded IRQ for MAC 0 */
  77. #define MSP_INT_SLP_MAC1 (MSP_SLP_INTBASE + 11)
  78. /* Cascaded IRQ for MAC 1 */
  79. #define MSP_INT_SEC (MSP_SLP_INTBASE + 12)
  80. /* IRQ for security engine */
  81. #define MSP_INT_PER (MSP_SLP_INTBASE + 13)
  82. /* Peripheral interrupt */
  83. #define MSP_INT_TIMER0 (MSP_SLP_INTBASE + 14)
  84. /* SLP timer 0 */
  85. #define MSP_INT_TIMER1 (MSP_SLP_INTBASE + 15)
  86. /* SLP timer 1 */
  87. #define MSP_INT_TIMER2 (MSP_SLP_INTBASE + 16)
  88. /* SLP timer 2 */
  89. #define MSP_INT_SLP_TIMER (MSP_SLP_INTBASE + 17)
  90. /* Cascaded MIPS timer */
  91. #define MSP_INT_BLKCP (MSP_SLP_INTBASE + 18)
  92. /* Block Copy */
  93. #define MSP_INT_UART0 (MSP_SLP_INTBASE + 19)
  94. /* UART 0 */
  95. #define MSP_INT_PCI (MSP_SLP_INTBASE + 20)
  96. /* PCI subsystem */
  97. #define MSP_INT_PCI_DBELL (MSP_SLP_INTBASE + 21)
  98. /* PCI doorbell */
  99. #define MSP_INT_PCI_MSI (MSP_SLP_INTBASE + 22)
  100. /* PCI Message Signal */
  101. #define MSP_INT_PCI_BC0 (MSP_SLP_INTBASE + 23)
  102. /* PCI Block Copy 0 */
  103. #define MSP_INT_PCI_BC1 (MSP_SLP_INTBASE + 24)
  104. /* PCI Block Copy 1 */
  105. #define MSP_INT_SLP_ERR (MSP_SLP_INTBASE + 25)
  106. /* SLP error condition */
  107. #define MSP_INT_MAC2 (MSP_SLP_INTBASE + 26)
  108. /* IRQ for MAC2 */
  109. /* Reserved 26-31 */
  110. /*
  111. * IRQs cascaded on SLP PER interrupt (MSP_INT_PER)
  112. */
  113. #define MSP_PER_INTBASE (MSP_SLP_INTBASE + 32)
  114. /* Reserved 0-1 */
  115. #define MSP_INT_UART1 (MSP_PER_INTBASE + 2)
  116. /* UART 1 */
  117. /* Reserved 3-5 */
  118. #define MSP_INT_2WIRE (MSP_PER_INTBASE + 6)
  119. /* 2-wire */
  120. #define MSP_INT_TM0 (MSP_PER_INTBASE + 7)
  121. /* Peripheral timer block out 0 */
  122. #define MSP_INT_TM1 (MSP_PER_INTBASE + 8)
  123. /* Peripheral timer block out 1 */
  124. /* Reserved 9 */
  125. #define MSP_INT_SPRX (MSP_PER_INTBASE + 10)
  126. /* SPI RX complete */
  127. #define MSP_INT_SPTX (MSP_PER_INTBASE + 11)
  128. /* SPI TX complete */
  129. #define MSP_INT_GPIO (MSP_PER_INTBASE + 12)
  130. /* GPIO */
  131. #define MSP_INT_PER_ERR (MSP_PER_INTBASE + 13)
  132. /* Peripheral error */
  133. /* Reserved 14-31 */
  134. #endif /* !_MSP_SLP_INT_H */