On Tue, Aug 19, 2008 at 11:13 AM, Alex Nixon (Intern)
can you try !CONFIG_HAVE_SPARSE_IRQ and CONFIG_HAVE_SPARSE_IRQ ?
YH
--
Sorry I should have mentioned originally - the bug occurs both with
CONFIG_HAVE_SPARSE_IRQ enabled, and disabled.- Alex
--
maybe we need special probe_nr_irqs for PV or not call that in
setup_arch for xen -- it will leave nr_irqs == NR_IRQSYH
--
That would be one solution, but would be more involved than this trivial
patch (although if considered more 'correct' then it is of course worth
the effort).
But attempting to keep things simple, is there a reason it's
preferable to fall back to 32 rather NR_IRQS?- Alex
--
when !CONFIG_HAVE_SPARSE_IRQ, with dyn_array, could allocate irq_desc
and etc as less as possible.
when CONFIG_HAVE_SPARESE_IRQ, no actually meaning for nr_irqs.YH
--
So I believe the only case this affects is !CONFIG_HAVE_SPARSE_IRQ
The worry is that with CONFIG_HAVE_DYN_ARRAY we may waste memory by
pre-allocating more irq_descs than may be necessary (NR_IRQs vs 32)?With !CONFIG_HAVE_DYN_ARRAY however, a static array of size NR_IRQS is
allocated instead - so doesn't defaulting nr_irqs back to NR_IRQS just
revert to the old behaviour (with the exception of the irq_descs being
allocated in pre_alloc_dyn_array instead)?- Alex
--
Sorry to pester you Yinghai, but I'd like to get a patch for this out
one way or another as Xen is _completely_ unusable with 5 or more VCPUs.Can you explain more clearly what the problem with the patch is?
I have a different patch set which solves the problem by adding in a pv
hook for probe_nr_irqs, but it's by far less clean.Or alternatively, we could revert your patch b2e5f326bb
Cheers,
- Alex
--
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
--
No. A Xen-capable kernel can also run native, so it must do whatever a
normal kernel would do when booting native.At what point in the boot does nr_irqs need to be set? Could we just
J
--
| Greg Kroah-Hartman | [PATCH 008/196] Chinese: add translation of volatile-considered-harmful.txt |
| Tarkan Erimer | Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3 |
| Greg KH | Re: [Patch v2] Make PCI extended config space (MMCONFIG) a driver opt-in |
| Andrew Morton | -mm merge plans for 2.6.23 |
git: | |
| Gerrit Renker | [PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side) |
| Herbert Xu | Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| David Miller | [GIT]: Networking |
| Rémi Denis-Courmont | [PATCH 01/14] Phonet global definitions |
