All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] libxl: bail from placement on non-NUMA boxes
@ 2014-04-30 15:44 Dario Faggioli
  2014-05-02 13:03 ` Ian Campbell
  0 siblings, 1 reply; 2+ messages in thread
From: Dario Faggioli @ 2014-04-30 15:44 UTC (permalink / raw)
  To: xen-devel; +Cc: Juergen Gross, Ian Jackson, Ian Campbell

If there only is 1 NUMA node, no need to go through placement
candidate selection, etc., we can just bail.

Signed-off-by: Dario Faggioli <dario.faggioli@citrix.com>
---
 tools/libxl/libxl_numa.c |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/tools/libxl/libxl_numa.c b/tools/libxl/libxl_numa.c
index 4fac664..94ca4fe 100644
--- a/tools/libxl/libxl_numa.c
+++ b/tools/libxl/libxl_numa.c
@@ -308,6 +308,11 @@ int libxl__get_numa_candidate(libxl__gc *gc,
     if (ninfo == NULL)
         return ERROR_FAIL;
 
+    if (nr_nodes <= 1) {
+        *cndt_found = 0;
+        goto out;
+    }
+
     GCNEW_ARRAY(vcpus_on_node, nr_nodes);
 
     /*

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-05-02 13:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-04-30 15:44 [PATCH] libxl: bail from placement on non-NUMA boxes Dario Faggioli
2014-05-02 13:03 ` Ian Campbell

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.