[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [XenPPC] [xenppc-unstable] [POWERPC][XEN] Allocate more memory than RMA for Dom0
On Sun, 2006-08-27 at 20:20 +0000, Xen patchbot-xenppc-unstable wrote: > @@ -155,13 +159,36 @@ int construct_dom0(struct domain *d, > /* By default DOM0 is allocated all available memory. */ > d->max_pages = ~0U; > > + /* default is the max(1/16th of memory, CONFIG_MIN_DOM0_PAGES) */ > if (dom0_nrpages == 0) { > - dom0_nrpages = 1UL << d->arch.rma_order; > - } > + dom0_nrpages = total_pages >> 4; > + > + if (dom0_nrpages < CONFIG_MIN_DOM0_PAGES) > + dom0_nrpages = CONFIG_MIN_DOM0_PAGES; > + } > + > + /* make sure we are at least as big as the RMA */ > + if (dom0_nrpages < rma_nrpages) > + dom0_nrpages = rma_nrpages; > + else > + dom0_nrpages = allocate_extents(d, dom0_nrpages, rma_nrpages); > > d->tot_pages = dom0_nrpages; > ASSERT(d->tot_pages > 0); Note that dom0_nrpages here doesn't do anything other than confuse the memory accounting (though we don't try to destroy dom0, so it doesn't matter too much ATM). In particular, we're assigning d->tot_pages without actually doing any heap allocation. -- Hollis Blanchard IBM Linux Technology Center _______________________________________________ Xen-ppc-devel mailing list Xen-ppc-devel@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-ppc-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |