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: Shall we clear the cpumap in XEN_DOMCTL_setvcpuaffinity

To: "Jiang, Yunhong" <yunhong.jiang@xxxxxxxxx>
Subject: [Xen-devel] Re: Shall we clear the cpumap in XEN_DOMCTL_setvcpuaffinity
From: Keir Fraser <keir.fraser@xxxxxxxxxxxxx>
Date: Wed, 12 May 2010 09:11:29 +0100
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Wed, 12 May 2010 01:13:09 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <789F9655DD1B8F43B48D77C5D30659731E5F2112@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>
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: Acrxo9fMxtcQKWhdSH+8fA5mN2iicwAAup85AABvtOAAAI4QZw==
Thread-topic: Shall we clear the cpumap in XEN_DOMCTL_setvcpuaffinity
User-agent: Microsoft-Entourage/12.24.0.100205
It's in the staging tree
http://xenbits.xensource.com/staging/xen-unstable.hg

 -- Keir

On 12/05/2010 08:57, "Jiang, Yunhong" <yunhong.jiang@xxxxxxxxx> wrote:

> Thanks, although "no changes found" after hg pull :-)
> 
> --jyh
> 
>> -----Original Message-----
>> From: Keir Fraser [mailto:keir.fraser@xxxxxxxxxxxxx]
>> Sent: Wednesday, May 12, 2010 3:43 PM
>> To: Jiang, Yunhong
>> Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
>> Subject: Re: Shall we clear the cpumap in XEN_DOMCTL_setvcpuaffinity
>> 
>> On 12/05/2010 08:22, "Jiang, Yunhong" <yunhong.jiang@xxxxxxxxx> wrote:
>> 
>>> When browse code, I noticed if the op->u.vcpuaffinity.cpumap is NULL, a
>>> random
>>> value of new_affinity will be passed to vcpu_set_affinity(), as in followed
>>> code.
>>> 
>>> I'm not sure if this is expected result. IMO, we should return -EINVAL if no
>>> cpu specified, as the return value at vcpu_set_affinity() for empty cpumap.
>> 
>> Xen-unstable:21350.
>> 
>> Thanks,
>> Keir
>> 
>>> Did I missed anything?
>>> 
>>>     case XEN_DOMCTL_getvcpuaffinity:
>>>     {
>>>         domid_t dom = op->domain;
>>>         struct domain *d = rcu_lock_domain_by_id(dom);
>>>         struct vcpu *v;
>>>         cpumask_t new_affinity;
>>> ......
>>>         if ( op->cmd == XEN_DOMCTL_setvcpuaffinity )
>>>         {
>>>             xenctl_cpumap_to_cpumask(  >>>>> the new_affinity is not
>>> initialized for if cpumap==NULL
>>>                 &new_affinity, &op->u.vcpuaffinity.cpumap);
>>>             ret = vcpu_set_affinity(v, &new_affinity);
>>>         }
>>> 
>>> Thanks
>>> --jyh
>> 
> 



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

<Prev in Thread] Current Thread [Next in Thread>