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] [PATCH] CPU affinity reset during save/restore

To: xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-devel] [PATCH] CPU affinity reset during save/restore
From: Jiri Denemark <jdenemar@xxxxxxxxxx>
Date: Thu, 13 Nov 2008 09:40:27 +0100
Delivery-date: Thu, 13 Nov 2008 00:41:06 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
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
User-agent: Mutt/1.5.18 (2008-05-17)
Hi,

This is the same patch I sent earlier this week with Signed-off-by-line added.

Even though there is a quite old cs 14588
(http://xenbits.xensource.com/xen-unstable.hg?rev/853853686147) described as a
fix to this issue, the CPU affinity is still reset after dom-U being saved and
restored in current xen-unstable.

I found two reasons for this. First, although XendConfig._parse_sxp() tries to
parse the affinity from 'cpus', the list is not stored in domain's checkpoint
file. This is because cs 15152
(http://xenbits.xensource.com/xen-unstable.hg?rev/681ed46676a6) prevents
'cpus' list to be generated in XendConfig.to_sxp().

Second, even though 'cpus' is correctly parsed in XendConfig._parse_sxp(), it
is not used for setting CPU affinity in XendDomainInfo.resume().

That said, after reverting cs 14588 and applying the attached patch, the CPU
affinity is correctly restored after restoring the domain.

The attached patch just copies the code related to CPU affinity from
XendDomainInfo._initDomain() into XendDomainInfo._setCPUAffinity() and calls
this method from _initDomain() and resume().

What do you think about this way to fix the CPU affinity reset? If it is not
the right way, what way do you prefer this issue to be fixed?

Any comments how the patch could be improved are most welcome.

Signed-off-by: Jiri Denemark <jdenemar@xxxxxxxxxx>

Attachment: cpu-affinity.patch
Description: Text document

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
<Prev in Thread] Current Thread [Next in Thread>