| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | /*
 | 
					
						
							|  |  |  |  * Defines for the MSP interrupt controller. | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * Copyright (C) 1999 MIPS Technologies, Inc.  All rights reserved. | 
					
						
							|  |  |  |  * Author: Carsten Langgaard, carstenl@mips.com | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * ######################################################################## | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  *  This program is free software; you can distribute it and/or modify it | 
					
						
							|  |  |  |  *  under the terms of the GNU General Public License (Version 2) as | 
					
						
							|  |  |  |  *  published by the Free Software Foundation. | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  *  This program is distributed in the hope it will be useful, but WITHOUT | 
					
						
							|  |  |  |  *  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | 
					
						
							|  |  |  |  *  FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License | 
					
						
							|  |  |  |  *  for more details. | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  *  You should have received a copy of the GNU General Public License along | 
					
						
							|  |  |  |  *  with this program; if not, write to the Free Software Foundation, Inc., | 
					
						
							|  |  |  |  *  59 Temple Place - Suite 330, Boston MA 02111-1307, USA. | 
					
						
							|  |  |  |  * | 
					
						
							|  |  |  |  * ######################################################################## | 
					
						
							|  |  |  |  */ | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #ifndef _MSP_CIC_INT_H
 | 
					
						
							|  |  |  | #define _MSP_CIC_INT_H
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | /*
 | 
					
						
							|  |  |  |  * The PMC-Sierra CIC interrupts are all centrally managed by the | 
					
						
							|  |  |  |  * CIC sub-system. | 
					
						
							|  |  |  |  * We attempt to keep the interrupt numbers as consistent as possible | 
					
						
							|  |  |  |  * across all of the MSP devices, but some differences will creep in ... | 
					
						
							|  |  |  |  * The interrupts which are directly forwarded to the MIPS core interrupts | 
					
						
							|  |  |  |  * are assigned interrupts in the range 0-7, interrupts cascaded through | 
					
						
							|  |  |  |  * the CIC are assigned interrupts 8-39.  The cascade occurs on C_IRQ4 | 
					
						
							|  |  |  |  * (MSP_INT_CIC).  Currently we don't really distinguish between VPE1 | 
					
						
							|  |  |  |  * and VPE0 (or thread contexts for that matter).  Will have to fix. | 
					
						
							|  |  |  |  * The PER interrupts are assigned interrupts in the range 40-71. | 
					
						
							|  |  |  | */ | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | /*
 | 
					
						
							|  |  |  |  * IRQs directly forwarded to the CPU | 
					
						
							|  |  |  |  */ | 
					
						
							|  |  |  | #define MSP_MIPS_INTBASE	0
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | #define MSP_INT_SW0		0	/* IRQ for swint0,	 C_SW0	*/
 | 
					
						
							|  |  |  | #define MSP_INT_SW1		1	/* IRQ for swint1,	 C_SW1	*/
 | 
					
						
							|  |  |  | #define MSP_INT_MAC0		2	/* IRQ for MAC 0,	 C_IRQ0 */
 | 
					
						
							|  |  |  | #define MSP_INT_MAC1		3	/* IRQ for MAC 1,	 C_IRQ1 */
 | 
					
						
							|  |  |  | #define MSP_INT_USB		4	/* IRQ for USB,		 C_IRQ2 */
 | 
					
						
							|  |  |  | #define MSP_INT_SAR		5	/* IRQ for ADSL2+ SAR,	 C_IRQ3 */
 | 
					
						
							|  |  |  | #define MSP_INT_CIC		6	/* IRQ for CIC block,	 C_IRQ4 */
 | 
					
						
							|  |  |  | #define MSP_INT_SEC		7	/* IRQ for Sec engine,	 C_IRQ5 */
 | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | 
 | 
					
						
							|  |  |  | /*
 | 
					
						
							|  |  |  |  * IRQs cascaded on CPU interrupt 4 (CAUSE bit 12, C_IRQ4) | 
					
						
							|  |  |  |  * These defines should be tied to the register definitions for the CIC | 
					
						
							|  |  |  |  * interrupt routine.  For now, just use hard-coded values. | 
					
						
							|  |  |  |  */ | 
					
						
							|  |  |  | #define MSP_CIC_INTBASE		(MSP_MIPS_INTBASE + 8)
 | 
					
						
							|  |  |  | #define MSP_INT_EXT0		(MSP_CIC_INTBASE + 0)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* External interrupt 0		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_EXT1		(MSP_CIC_INTBASE + 1)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* External interrupt 1		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_EXT2		(MSP_CIC_INTBASE + 2)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* External interrupt 2		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_EXT3		(MSP_CIC_INTBASE + 3)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* External interrupt 3		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_CPUIF		(MSP_CIC_INTBASE + 4)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* CPU interface interrupt	*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_EXT4		(MSP_CIC_INTBASE + 5)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* External interrupt 4		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_CIC_USB		(MSP_CIC_INTBASE + 6)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* Cascaded IRQ for USB		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_MBOX		(MSP_CIC_INTBASE + 7)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* Sec engine mailbox IRQ	*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_EXT5		(MSP_CIC_INTBASE + 8)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* External interrupt 5		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_TDM		(MSP_CIC_INTBASE + 9)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* TDM interrupt		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_CIC_MAC0	(MSP_CIC_INTBASE + 10)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* Cascaded IRQ for MAC 0	*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_CIC_MAC1	(MSP_CIC_INTBASE + 11)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* Cascaded IRQ for MAC 1	*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_CIC_SEC		(MSP_CIC_INTBASE + 12)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* Cascaded IRQ for sec engine	*/ | 
					
						
							|  |  |  | #define MSP_INT_PER		(MSP_CIC_INTBASE + 13)
 | 
					
						
							|  |  |  | 					/* Peripheral interrupt		*/ | 
					
						
							|  |  |  | #define MSP_INT_TIMER0		(MSP_CIC_INTBASE + 14)
 | 
					
						
							|  |  |  | 					/* SLP timer 0			*/ | 
					
						
							|  |  |  | #define MSP_INT_TIMER1		(MSP_CIC_INTBASE + 15)
 | 
					
						
							|  |  |  | 					/* SLP timer 1			*/ | 
					
						
							|  |  |  | #define MSP_INT_TIMER2		(MSP_CIC_INTBASE + 16)
 | 
					
						
							|  |  |  | 					/* SLP timer 2			*/ | 
					
						
							|  |  |  | #define MSP_INT_VPE0_TIMER	(MSP_CIC_INTBASE + 17)
 | 
					
						
							|  |  |  | 					/* VPE0 MIPS timer		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_BLKCP		(MSP_CIC_INTBASE + 18)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* Block Copy			*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_UART0		(MSP_CIC_INTBASE + 19)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* UART 0			*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_PCI		(MSP_CIC_INTBASE + 20)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* PCI subsystem		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_EXT6		(MSP_CIC_INTBASE + 21)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* External interrupt 5		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_PCI_MSI		(MSP_CIC_INTBASE + 22)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* PCI Message Signal		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_CIC_SAR		(MSP_CIC_INTBASE + 23)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* Cascaded ADSL2+ SAR IRQ	*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_DSL		(MSP_CIC_INTBASE + 24)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* ADSL2+ IRQ			*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_CIC_ERR		(MSP_CIC_INTBASE + 25)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* SLP error condition		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_VPE1_TIMER	(MSP_CIC_INTBASE + 26)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* VPE1 MIPS timer		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_VPE0_PC		(MSP_CIC_INTBASE + 27)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* VPE0 Performance counter	*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_VPE1_PC		(MSP_CIC_INTBASE + 28)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* VPE1 Performance counter	*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_EXT7		(MSP_CIC_INTBASE + 29)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* External interrupt 5		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_VPE0_SW		(MSP_CIC_INTBASE + 30)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* VPE0 Software interrupt	*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_VPE1_SW		(MSP_CIC_INTBASE + 31)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* VPE0 Software interrupt	*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | 
 | 
					
						
							|  |  |  | /*
 | 
					
						
							|  |  |  |  * IRQs cascaded on CIC PER interrupt (MSP_INT_PER) | 
					
						
							|  |  |  |  */ | 
					
						
							|  |  |  | #define MSP_PER_INTBASE		(MSP_CIC_INTBASE + 32)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | /* Reserved					   0-1			*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_UART1		(MSP_PER_INTBASE + 2)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* UART 1			*/ | 
					
						
							|  |  |  | /* Reserved					   3-5			*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_2WIRE		(MSP_PER_INTBASE + 6)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* 2-wire			*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_TM0		(MSP_PER_INTBASE + 7)
 | 
					
						
							|  |  |  | 					/* Peripheral timer block out 0 */ | 
					
						
							|  |  |  | #define MSP_INT_TM1		(MSP_PER_INTBASE + 8)
 | 
					
						
							|  |  |  | 					/* Peripheral timer block out 1 */ | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | /* Reserved					   9			*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_SPRX		(MSP_PER_INTBASE + 10)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* SPI RX complete		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_SPTX		(MSP_PER_INTBASE + 11)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* SPI TX complete		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_GPIO		(MSP_PER_INTBASE + 12)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* GPIO				*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | #define MSP_INT_PER_ERR		(MSP_PER_INTBASE + 13)
 | 
					
						
							| 
									
										
										
										
											2013-01-22 12:59:30 +01:00
										 |  |  | 					/* Peripheral error		*/ | 
					
						
							|  |  |  | /* Reserved					   14-31		*/ | 
					
						
							| 
									
										
										
										
											2007-06-14 15:54:47 -06:00
										 |  |  | 
 | 
					
						
							|  |  |  | #endif /* !_MSP_CIC_INT_H */
 |