Setting /proc/irq/[n]/smp_affinity failure on 8 cpu systems
Quoted 26 lines · John Blackwood
Quoted 21 lines
Quoted 21 lines
I would like to mention an irq set affinity issue occurs on an older Dell PowerEdge 6650 system:
- 8 cpus (4 are hyper-threaded),
- uses the struct apic 'apic_default' support
- 32 bit (x86) kernelThis issue is that once you change the irq
smp_affinityof an irq to be less than all cpus in the system, you can never change really the
irqsmp_affinityback to be all cpus in the system (0xff) again, even though no error status is returned on the "/bin/echoff > /proc/irq/[n]/smp_affinity" operation.This is due to that fact that
BAD_APICIDhas the same value as all cpus (0xff) on 32bit kernels, and thus the value returned fromset_desc_affinity()via thecpu_mask_to_apicid_and()function is treated
as a failure inset_ioapic_affinity_irq_desc(), and no affinity changes
are made.Quoted 3 lines
Quoted 3 lines
It seems like changing the
BAD_APICIDvalue from0xFFto0xFFFFforCONFIG_X86_32might be one possible solution, and it seems to function properly for this Dell PowerEdge 6650 system.
Quoted 6 lines
John, Thanks for the root cause and analysis. As you noticed,
0xffis a valid logical apicid. Similarly0xffffis a valid logical x2apic cluster id. So while your patch fixes your issue, it doesn't completely fix the issue. Can you please check if the appended patch works and ack if it passes your test?
Hi Suresh,
Yes, your patch works on the Dell PowerEdge 6650 system.
Thanks for your help and quick reply.