WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

RE: [Xen-devel] RE: [PATCH] Allocate vmcs pages when system booting

To: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>, Jan Beulich <JBeulich@xxxxxxxxxx>
Subject: RE: [Xen-devel] RE: [PATCH] Allocate vmcs pages when system booting
From: "Jiang, Yunhong" <yunhong.jiang@xxxxxxxxx>
Date: Sun, 17 Jan 2010 10:02:03 +0800
Accept-language: en-US
Acceptlanguage: en-US
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Sat, 16 Jan 2010 18:02:30 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <C775F48B.66D1%keir.fraser@xxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <4B5043B8020000780002A2E9@xxxxxxxxxxxxxxxxxx> <C775F48B.66D1%keir.fraser@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcqVxVme7EN1OoA5TyaMx+UMKHT6NwACJIqgAFJQcYA=
Thread-topic: [Xen-devel] RE: [PATCH] Allocate vmcs pages when system booting
In Linux side, it required some changes on ACPI. See information from 
Documentation/x86/x86_64/cpu-hotplug-spec:

Linux/x86-64 supports CPU hotplug now. For various reasons Linux wants to
know in advance of boot time the maximum number of CPUs that could be plugged
into the system. ACPI 3.0 currently has no official way to supply
this information from the firmware to the operating system.

But this requirement is not added to ACPI 4.0, so when working on CPU hotplug, 
I didn't try to use the same method.

After reading the code again, I think maybe I missed one possible place to 
achieve the same purpose. We can simply allocate the VMCS pag from cpu_hotadd 
in XENPF_cpu_hotadd, where the CPU changed from possible to present. Later, 
when we bring-up the CPU, we don't need allocate VMCS page anymore. That is, we 
will allocate VMCS pages still, but only for present cpus, not possible CPUs. 
When CPU is changed from logical online to offline, this VMCS page will not be 
freed.

Do you agree this method?

Thanks
Yunhong Jiang

>-----Original Message-----
>From: Keir Fraser [mailto:keir.fraser@xxxxxxxxxxxxx]
>Sent: Friday, January 15, 2010 6:32 PM
>To: Jan Beulich; Jiang, Yunhong
>Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
>Subject: Re: [Xen-devel] RE: [PATCH] Allocate vmcs pages when system booting
>
>On 15/01/2010 09:30, "Jan Beulich" <JBeulich@xxxxxxxxxx> wrote:
>
>>>>> "Jiang, Yunhong" <yunhong.jiang@xxxxxxxxx> 15.01.10 10:06 >>>
>>> b) Can we still turn to the original patch, i.e. pre-allocate all VMCS pages
>>> for all possible CPU?
>>
>> I'm generally opposed to pre-allocations, at least as long as all CPUs are
>> considered 'possible'. Building with a relatively high nr_cpus= setting
>> and then running on a relatively small system results in (close to)
>> unacceptable overhead.
>>
>> In fact it's really not clear to me why cpu_possible_map must be set to
>> CPU_MASK_ALL - if Linux has ways to avoid this, Xen should have too.
>
>Does Linux manage a good reliable job of cutting down cpu_possible_map? That
>would save cpu_possible_map in my eyes, if we could do that. Otherwise it is
>indeed pretty useless now. Either way, I'd like cpu hotplug notifier chains
>in the 4.1 development window.
>
> -- Keir
>


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel