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

[Xen-devel] Re: [PATCH] Don't assume the vcpu_id is continous in alloc_v

To: "Jiang, Yunhong" <yunhong.jiang@xxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Subject: [Xen-devel] Re: [PATCH] Don't assume the vcpu_id is continous in alloc_vcpu
From: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Date: Thu, 12 Nov 2009 13:18:19 +0000
Cc:
Delivery-date: Thu, 12 Nov 2009 05:18:50 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <C721A2AE.19F60%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>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
Thread-index: AcpjiGc6hZlnMOBYRPSWYjjerzo1vQAA1c0HAAO2138=
Thread-topic: [PATCH] Don't assume the vcpu_id is continous in alloc_vcpu
User-agent: Microsoft-Entourage/12.20.0.090605
On 12/11/2009 11:31, "Keir Fraser" <keir.fraser@xxxxxxxxxxxxx> wrote:

>> Currently in alloc_vcpu, it assumes the vcpu is allocated with vcpu_id is
>> continous.
>> When cpu hot-added, this assumption is broken because the hot-added CPU may
>> be
>> brougt online by dom0 in arbitrary order. This patch try to link the new vcpu
>> to the end of the link.
>> 
>> Signed-off-by: Jiang, Yunhong <yunhong.jiang@xxxxxxxxx>
> 
> Is this something to do with allocating vcpus for the idle domain?
> 
> If so, I suggest we just allocate vcpu_ids sequentially on-demand. I can
> work up a patch for you to test if you like.

I was wrong, that was a bad idea since idle_vcpu[] is also the idle domain's
vcpu pointer array. Actually I also have been able to revert c/s 20045 since
I was mistaken about that being needed. And I've applied your patch as c/s
20433, but I rewrote it to keep vcpus in ascending order of vcpuid (not sure
it's necessary really, but it's nice to do).

 -- Keir



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