Skip to content

Commit e242114

Browse files
zch-repoozbenh
authored andcommitted
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. Signed-off-by: Zhao Chenhui <chenhui.zhao@freescale.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
1 parent 2b3f8e8 commit e242114

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎arch/powerpc/sysdev/mpic.c‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ static DEFINE_RAW_SPINLOCK(mpic_lock);
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)
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);

0 commit comments

Comments
 (0)