[PATCH] x86: 64bit support more than 256 irq because 64bit allow same vector for different cpu to serve different irq also change next in irq_pin_list from short to next. because for 4096 NR_IRQS is 2^(5+12)+224. need to create that array dynamically later Signed-off-by: Yinghai Lu --- arch/x86/kernel/io_apic_64.c | 3 ++- include/asm-x86/irq_vectors.h | 6 +++++- 2 files changed, 7 insertions(+), 2 deletions(-) Index: linux-2.6/include/asm-x86/irq_vectors.h =================================================================== --- linux-2.6.orig/include/asm-x86/irq_vectors.h +++ linux-2.6/include/asm-x86/irq_vectors.h @@ -113,9 +113,13 @@ # if defined(CONFIG_X86_IO_APIC) || defined(CONFIG_PARAVIRT) || defined(CONFIG_X86_VISWS) +#ifdef CONFIG_X86_64 +# define NR_IRQS (32 * NR_CPUS + 224) +#else # define NR_IRQS 224 +#endif -# if (224 >= 32 * NR_CPUS) +# if (NR_IRQS >= 32 * NR_CPUS) # define NR_IRQ_VECTORS NR_IRQS # else # define NR_IRQ_VECTORS (32 * NR_CPUS) Index: linux-2.6/arch/x86/kernel/io_apic_64.c =================================================================== --- linux-2.6.orig/arch/x86/kernel/io_apic_64.c +++ linux-2.6/arch/x86/kernel/io_apic_64.c @@ -140,7 +140,8 @@ DECLARE_BITMAP(mp_bus_not_pci, MAX_MP_BU */ static struct irq_pin_list { - short apic, pin, next; + short apic, pin; + int next; } irq_2_pin[PIN_MAP_SIZE]; struct io_apic {