Srinidhi Kasagar | ffae4e0 | 2009-11-28 08:10:40 +0100 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2008 STMicroelectronics |
| 3 | * Copyright (C) 2009 ST-Ericsson. |
| 4 | * |
| 5 | * This program is free software; you can redistribute it and/or modify |
| 6 | * it under the terms of the GNU General Public License as published by |
| 7 | * the Free Software Foundation; either version 2 of the License, or |
| 8 | * (at your option) any later version. |
| 9 | */ |
| 10 | #ifndef ASM_ARCH_IRQS_H |
| 11 | #define ASM_ARCH_IRQS_H |
| 12 | |
Rabin Vincent | 6055930 | 2010-07-26 11:09:27 +0100 | [diff] [blame] | 13 | #include <mach/irqs-db5500.h> |
| 14 | #include <mach/irqs-db8500.h> |
Srinidhi Kasagar | ffae4e0 | 2009-11-28 08:10:40 +0100 | [diff] [blame] | 15 | |
| 16 | #define IRQ_LOCALTIMER 29 |
| 17 | #define IRQ_LOCALWDOG 30 |
| 18 | |
| 19 | /* Shared Peripheral Interrupt (SHPI) */ |
| 20 | #define IRQ_SHPI_START 32 |
| 21 | |
| 22 | /* Interrupt numbers generic for shared peripheral */ |
| 23 | #define IRQ_MTU0 (IRQ_SHPI_START + 4) |
Srinidhi Kasagar | ffae4e0 | 2009-11-28 08:10:40 +0100 | [diff] [blame] | 24 | |
| 25 | /* There are 128 shared peripheral interrupts assigned to |
| 26 | * INTID[160:32]. The first 32 interrupts are reserved. |
| 27 | */ |
Rabin Vincent | 6055930 | 2010-07-26 11:09:27 +0100 | [diff] [blame] | 28 | #define DBX500_NR_INTERNAL_IRQS 161 |
Rabin Vincent | 94bdc0e | 2010-03-03 04:54:37 +0100 | [diff] [blame] | 29 | |
| 30 | /* After chip-specific IRQ numbers we have the GPIO ones */ |
| 31 | #define NOMADIK_NR_GPIO 288 |
Rabin Vincent | 6055930 | 2010-07-26 11:09:27 +0100 | [diff] [blame] | 32 | #define NOMADIK_GPIO_TO_IRQ(gpio) ((gpio) + DBX500_NR_INTERNAL_IRQS) |
| 33 | #define NOMADIK_IRQ_TO_GPIO(irq) ((irq) - DBX500_NR_INTERNAL_IRQS) |
| 34 | #define IRQ_BOARD_START NOMADIK_GPIO_TO_IRQ(NOMADIK_NR_GPIO) |
Srinidhi Kasagar | ffae4e0 | 2009-11-28 08:10:40 +0100 | [diff] [blame] | 35 | |
Rabin Vincent | 6055930 | 2010-07-26 11:09:27 +0100 | [diff] [blame] | 36 | /* This will be overridden by board-specific irq headers */ |
| 37 | #define IRQ_BOARD_END IRQ_BOARD_START |
| 38 | |
Rabin Vincent | 5dc55e0 | 2010-12-08 11:07:58 +0530 | [diff] [blame] | 39 | #ifdef CONFIG_MACH_U8500 |
Rabin Vincent | 39ae702 | 2010-07-26 11:12:15 +0100 | [diff] [blame] | 40 | #include <mach/irqs-board-mop500.h> |
| 41 | #endif |
| 42 | |
Linus Walleij | 4d4a4b0 | 2010-09-27 22:09:52 +0100 | [diff] [blame] | 43 | /* |
| 44 | * After the board specific IRQ:s we reserve a range of IRQ:s in which virtual |
| 45 | * IRQ:s representing modem IRQ:s can be allocated |
| 46 | */ |
| 47 | #define IRQ_MODEM_EVENTS_BASE (IRQ_BOARD_END + 1) |
| 48 | #define IRQ_MODEM_EVENTS_NBR 72 |
| 49 | #define IRQ_MODEM_EVENTS_END (IRQ_MODEM_EVENTS_BASE + IRQ_MODEM_EVENTS_NBR) |
| 50 | |
| 51 | /* List of virtual IRQ:s that are allocated from the range above */ |
| 52 | #define MBOX_PAIR0_VIRT_IRQ (IRQ_MODEM_EVENTS_BASE + 43) |
| 53 | #define MBOX_PAIR1_VIRT_IRQ (IRQ_MODEM_EVENTS_BASE + 45) |
| 54 | #define MBOX_PAIR2_VIRT_IRQ (IRQ_MODEM_EVENTS_BASE + 41) |
| 55 | |
| 56 | #define NR_IRQS IRQ_MODEM_EVENTS_END |
Rabin Vincent | 6055930 | 2010-07-26 11:09:27 +0100 | [diff] [blame] | 57 | |
| 58 | #endif /* ASM_ARCH_IRQS_H */ |