[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] xen: cpupools: update domU's node-affinity on the cpupool_unassign_cpu() path

  • To: Dario Faggioli <dario.faggioli@xxxxxxxxxx>
  • From: Juergen Gross <juergen.gross@xxxxxxxxxxxxxx>
  • Date: Mon, 30 Sep 2013 07:38:56 +0200
  • Cc: George Dunlap <George.Dunlap@xxxxxxxxxxxxx>, xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Keir Fraser <keir@xxxxxxx>
  • Delivery-date: Mon, 30 Sep 2013 05:39:43 +0000
  • Domainkey-signature: s=s1536a; d=ts.fujitsu.com; c=nofws; q=dns; h=X-SBRSScore:X-IronPort-AV:Received:X-IronPort-AV: Received:Message-ID:Date:From:Organization:User-Agent: MIME-Version:To:CC:Subject:References:In-Reply-To: Content-Type:Content-Transfer-Encoding; b=j+O+lJP6RcwKywJoujVg77AAvGkdbMoJkw6jFg+PjQc+Hr33wa9DAbAb 0B6keIpEWSYtgF5tuT2A1ztwpzaN6H1n9lAINMq+vVAQ5LI0dNzyWfE0E jG/Q7ysbz9Z8RX1A1fQ3MVBkzbvoeFd0srCvXUD4THVAOrEaLocScr37K A7IiYuG6JnzWCXNMx1Bu4LRwn4rFe3gicPxl1KP8CmrDgcXeHY+ci3XUq sM64Qer37gzgxH5J+4aQrSzbDEk7x;
  • List-id: Xen developer discussion <xen-devel.lists.xen.org>

On 27.09.2013 17:46, Dario Faggioli wrote:
that is, when a cpu is remove from a pool, as it is happening already
on the cpupool_assign_cpu_*() path (i.e., when a cpu is added to a

Signed-off-by: Dario Faggioli <dario.faggioli@xxxxxxxxxx>
Cc: Juergen Gross <juergen.gross@xxxxxxxxxxxxxx>
Cc: George Dunlap <George.Dunlap@xxxxxxxxxxxxx>
Cc: Keir Fraser <keir@xxxxxxx>

Acked-by: Juergen Gross <juergen.gross@xxxxxxxxxxxxxx>

This patch was originally an hunk of the first version of a patch I sent last
week as a bugfix for an ASSERT() triggering in the NUMA-aware scheduling code.

Truned out that the bug was better fixe in a completely different way, and
hence this part was killed from there... That's why I'm resending it now as a
separate patch.

  xen/common/cpupool.c |    8 ++++++++
  1 file changed, 8 insertions(+)

diff --git a/xen/common/cpupool.c b/xen/common/cpupool.c
index 2164a9f..23e461d 100644
--- a/xen/common/cpupool.c
+++ b/xen/common/cpupool.c
@@ -355,6 +355,14 @@ int cpupool_unassign_cpu(struct cpupool *c, unsigned int 
      cpupool_cpu_moving = c;
      cpumask_clear_cpu(cpu, c->cpu_valid);
+    rcu_read_lock(&domlist_read_lock);
+    for_each_domain_in_cpupool(d, c)
+    {
+        domain_update_node_affinity(d);
+    }
+    rcu_read_unlock(&domlist_read_lock);

      work_cpu = smp_processor_id();

Xen-devel mailing list

Juergen Gross                 Principal Developer Operating Systems
PBG PDG ES&S SWE OS6                   Telephone: +49 (0) 89 3222 2967
Fujitsu Technology Solutions              e-mail: juergen.gross@xxxxxxxxxxxxxx
Mies van der Rohe Str. 8                Internet: ts.fujitsu.com
D-80807 Muenchen                 Company details: ts.fujitsu.com/imprint.html

Xen-devel mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.