History

powerpc/mpic: Fix irq distribution problem when MPIC_SINGLE_DEST_CPU

For the mpic with a flag MPIC_SINGLE_DEST_CPU, only one bit should be set in interrupt destination registers. The code is applicable to 64-bit platforms as well as 32-bit.

chenhui zhao committed 13 years ago

Commit e2421141 parent 2b3f8e81 file · +2 −2Browse files

Unified · Split

arch/powerpc/sysdev/mpic.c+2−2
@@ -54,7 +54,7 @@ static DEFINE_RAW_SPINLOCK(mpic_lock); · 53 unmodified lines
5454
5555 #ifdef CONFIG_PPC32 /* XXX for now */
5656 #ifdef CONFIG_IRQ_ALL_CPUS
57−#define distribute_irqs (!(mpic->flags & MPIC_SINGLE_DEST_CPU))
57+#define distribute_irqs (1)
5858 #else
5959 #define distribute_irqs (0)
6060 #endif
@@ -1703,7 +1703,7 @@ void mpic_setup_this_cpu(void) · 1642 unmodified lines
17031703 * it differently, then we should make sure we also change the default
17041704 * values of irq_desc[].affinity in irq.c.
17051705 */
1706− if (distribute_irqs) {
1706+ if (distribute_irqs && !(mpic->flags & MPIC_SINGLE_DEST_CPU)) {
17071707 for (i = 0; i < mpic->num_sources ; i++)
17081708 mpic_irq_write(i, MPIC_INFO(IRQ_DESTINATION),
17091709 mpic_irq_read(i, MPIC_INFO(IRQ_DESTINATION)) | msk);