]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - arch/powerpc/kernel/irq.c
powerpc: Fix logic error in fixup_irqs
[net-next-2.6.git] / arch / powerpc / kernel / irq.c
index 30817d9b20cb59ecb12741edee7d0dacf5366dc3..77be3d058a658fa447a2235a8441d320be245d20 100644 (file)
@@ -295,7 +295,10 @@ void fixup_irqs(const struct cpumask *map)
 
        for_each_irq(irq) {
                desc = irq_to_desc(irq);
-               if (desc && desc->status & IRQ_PER_CPU)
+               if (!desc)
+                       continue;
+
+               if (desc->status & IRQ_PER_CPU)
                        continue;
 
                cpumask_and(mask, desc->affinity, map);
@@ -317,7 +320,6 @@ void fixup_irqs(const struct cpumask *map)
 }
 #endif
 
-#ifdef CONFIG_IRQSTACKS
 static inline void handle_one_irq(unsigned int irq)
 {
        struct thread_info *curtp, *irqtp;
@@ -358,12 +360,6 @@ static inline void handle_one_irq(unsigned int irq)
        if (irqtp->flags)
                set_bits(irqtp->flags, &curtp->flags);
 }
-#else
-static inline void handle_one_irq(unsigned int irq)
-{
-       generic_handle_irq(irq);
-}
-#endif
 
 static inline void check_stack_overflow(void)
 {
@@ -455,7 +451,6 @@ void exc_lvl_ctx_init(void)
 }
 #endif
 
-#ifdef CONFIG_IRQSTACKS
 struct thread_info *softirq_ctx[NR_CPUS] __read_mostly;
 struct thread_info *hardirq_ctx[NR_CPUS] __read_mostly;
 
@@ -492,10 +487,6 @@ static inline void do_softirq_onstack(void)
        irqtp->task = NULL;
 }
 
-#else
-#define do_softirq_onstack()   __do_softirq()
-#endif /* CONFIG_IRQSTACKS */
-
 void do_softirq(void)
 {
        unsigned long flags;