Port-xen archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: LOCKDEBUG kernel option crashes if vcpu > 1
On Wed, Nov 19, 2014 at 04:58:19PM +0530, Cherry G. Mathew wrote:
> >>>>> "Manuel" == Manuel Bouyer <bouyer%antioche.eu.org@localhost> writes:
>
> Manuel> On Tue, Nov 18, 2014 at 10:30:28PM +0530, Cherry G. Mathew wrote:
> >> Hi,
> >>
> >> Does the following patch work for you ?
> >>
> >> It's a bit tricky since we use uvm_km_alloc() at early bootup
> >> (even for ci, I think this should come from a static array or a
> >> poolcache) which is what triggers the pmap_growkernel() as you
> >> probably know.
>
>
> Manuel> a static array is probably not appropriate as we can have as
> Manuel> much as 256 virtual CPUs. I don't think a poolcache would
> Manuel> help as it has to get the memory from somewhere. And as ci
> Manuel> is never freeed, a pool or poolcache would be overkill.
>
> How about if we could map in a few more pages into kva in early boot,
> like below ?
>
>
> --
> Cherry
>
>
> diff -r 32f09689dc19 sys/arch/xen/x86/x86_xpmap.c
> --- a/sys/arch/xen/x86/x86_xpmap.c Tue Nov 18 12:26:14 2014 +0530
> +++ b/sys/arch/xen/x86/x86_xpmap.c Wed Nov 19 22:23:39 2014 +0530
> @@ -644,6 +644,9 @@
> mapsize += NBPG;
> mapsize += NBPG;
>
> + /* Pre-alloc kva for ci during cpu attach */
> + mapsize += round_page(maxcpus * sizeof(struct cpu_info)) * NBPG;
> +
On amd64 this makes 2193 extra slots.
What's the problem with making pmap_growkernel() work as expected ?
--
Manuel Bouyer <bouyer%antioche.eu.org@localhost>
NetBSD: 26 ans d'experience feront toujours la difference
--
Home |
Main Index |
Thread Index |
Old Index