opvxa24xx: Lock the voice card IRQ to CPU0

The voice card generates an interrupt every 1ms, effectively operating
in real time.  Since migrating the IRQ between CPUs can, in some cases,
cause the card to lose sync due to the added delay from migration,
lock the interrupt to CPU0 for now.
parent 32bbbf2e
......@@ -2250,6 +2250,7 @@ static int __devinit a24xx_init_one(struct pci_dev *pdev, const struct pci_devic
int z,index;
static int initd_ifaces=0;
int has_msi=0;
struct cpumask cpu_affinity_mask;
if(!initd_ifaces){
memset((void *)ifaces,0,(sizeof(struct a24xx *))*WC_MAX_IFACES);
......@@ -2471,6 +2472,16 @@ static int __devinit a24xx_init_one(struct pci_dev *pdev, const struct pci_devic
return -EIO;
}
}
/* Set affinity hint to CPU0
* Migrating this interrupt between CPUs can result in the card losing
* sync, so just lock it to CPU0 for now
*/
cpumask_clear(&cpu_affinity_mask);
cpumask_set_cpu(0, &cpu_affinity_mask);
irq_set_status_flags(pdev->irq, IRQ_NO_BALANCING);
irq_set_affinity_hint(pdev->irq, &cpu_affinity_mask);
if(0) { // for debug;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment