From: Chris Metcalf Date: Fri, 9 Aug 2013 19:41:09 +0000 (-0400) Subject: tile: fix panic with large IRQ number X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=8d8cf0674023da578e0539dc7cf4d824b2cf1f9e;p=deliverable%2Flinux.git tile: fix panic with large IRQ number The "available_irqs" value needs to actually reflect the IRQs available, not just start as an all-ones mask, since we only have 32 IRQs available even on a 64-bit platform. Signed-off-by: Chris Metcalf --- diff --git a/arch/tile/kernel/irq.c b/arch/tile/kernel/irq.c index c90de6c3cb7f..0e6c521b8a89 100644 --- a/arch/tile/kernel/irq.c +++ b/arch/tile/kernel/irq.c @@ -55,7 +55,8 @@ static DEFINE_PER_CPU(int, irq_depth); /* State for allocating IRQs on Gx. */ #if CHIP_HAS_IPI() -static unsigned long available_irqs = ~(1UL << IRQ_RESCHEDULE); +static unsigned long available_irqs = ((1UL << NR_IRQS) - 1) & + (~(1UL << IRQ_RESCHEDULE)); static DEFINE_SPINLOCK(available_irqs_lock); #endif