Re: [PATCH] X86: Change the default value of nr_irqs from 32 to NR_IRQs

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Alex Nixon <alex.nixon@...>
Cc: Ingo Molnar <mingo@...>, Jeremy Fitzhardinge <Jeremy.Fitzhardinge@...>, Linux Kernel Mailing List <linux-kernel@...>
Date: Wednesday, August 20, 2008 - 7:47 pm

On Wed, Aug 20, 2008 at 4:23 PM, Alex Nixon <alex.nixon@citrix.com> wrote:

small real system doesn't have MSI ioapic will have nr_irqs == 32.
your patch will increase that to 224 again.

sth like ?

#ifdef CONFIG_XEN
int __init probe_nr_irqs(void)
{
        int idx;
        int nr = 0;

        for (idx = 0; idx < nr_ioapics; idx++)
                nr += io_apic_get_redir_entries(idx);

        /* double it for hotplug and msi and nmi */
        nr <<= 1;

        /* something wrong ? */
        if (nr < 32)
                nr = 32;

        return nr;
}
#else
int __init probe_nr_irqs(void)
{
       return NR_IRQS;
}
#endif
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [PATCH] X86: Change the default value of nr_irqs from 32..., Yinghai Lu, (Wed Aug 20, 7:47 pm)
Re: [PATCH] X86: Change the default value of nr_irqs from 32..., Jeremy Fitzhardinge, (Thu Aug 21, 7:21 pm)