irq_to_desc(irq)->irq = irq;
if ( !irq_max_guests )
- irq_max_guests = 16;
+ irq_max_guests = 32;
#ifdef CONFIG_PV
/* Never allocate the hypercall vector or Linux/BSD fast-trap vector. */
{
struct irq_desc *desc;
irq_guest_action_t *action, *newaction = NULL;
+ unsigned int max_nr_guests = will_share ? irq_max_guests : 1;
int rc = 0;
WARN_ON(!spin_is_locked(&v->domain->event_lock));
{
spin_unlock_irq(&desc->lock);
if ( (newaction = xmalloc_flex_struct(irq_guest_action_t, guest,
- irq_max_guests)) != NULL &&
+ max_nr_guests)) != NULL &&
zalloc_cpumask_var(&newaction->cpu_eoi_map) )
goto retry;
xfree(newaction);
goto retry;
}
- if ( action->nr_guests == irq_max_guests )
+ if ( action->nr_guests >= max_nr_guests )
{
printk(XENLOG_G_INFO
"Cannot bind IRQ%d to %pd: already at max share %u"