From patchwork Mon Feb 23 19:29:11 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eduardo Habkost X-Patchwork-Id: 442652 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [IPv6:2001:4830:134:3::11]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 89903140157 for ; Tue, 24 Feb 2015 06:32:15 +1100 (AEDT) Received: from localhost ([::1]:45088 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YPyjl-0008Q4-Gv for incoming@patchwork.ozlabs.org; Mon, 23 Feb 2015 14:32:13 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:58387) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YPyhh-0004XU-RD for qemu-devel@nongnu.org; Mon, 23 Feb 2015 14:30:06 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YPyhh-00039y-3A for qemu-devel@nongnu.org; Mon, 23 Feb 2015 14:30:05 -0500 Received: from mx1.redhat.com ([209.132.183.28]:56393) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YPyhg-00038h-S7 for qemu-devel@nongnu.org; Mon, 23 Feb 2015 14:30:05 -0500 Received: from int-mx13.intmail.prod.int.phx2.redhat.com (int-mx13.intmail.prod.int.phx2.redhat.com [10.5.11.26]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id t1NJU2JE015392 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Mon, 23 Feb 2015 14:30:02 -0500 Received: from localhost (ovpn-113-200.phx2.redhat.com [10.3.113.200]) by int-mx13.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t1NJU10N023081; Mon, 23 Feb 2015 14:30:02 -0500 From: Eduardo Habkost To: Peter Maydell Date: Mon, 23 Feb 2015 16:29:11 -0300 Message-Id: <1424719754-2356-5-git-send-email-ehabkost@redhat.com> In-Reply-To: <1424719754-2356-1-git-send-email-ehabkost@redhat.com> References: <1424719754-2356-1-git-send-email-ehabkost@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.26 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 209.132.183.28 Cc: Paolo Bonzini , qemu-devel@nongnu.org, "Michael S. Tsirkin" Subject: [Qemu-devel] [PULL 4/7] numa: Make max_numa_nodeid static X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Now the only code that uses the variable is inside numa.c. Reviewed-by: Paolo Bonzini Acked-by: Michael S. Tsirkin Signed-off-by: Eduardo Habkost --- include/sysemu/numa.h | 3 --- numa.c | 4 +++- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/include/sysemu/numa.h b/include/sysemu/numa.h index 514914f..eae881e 100644 --- a/include/sysemu/numa.h +++ b/include/sysemu/numa.h @@ -8,9 +8,6 @@ #include "sysemu/hostmem.h" extern int nb_numa_nodes; /* Number of NUMA nodes */ -extern int max_numa_nodeid; /* Highest specified NUMA node ID, plus one. - * For all nodes, nodeid < max_numa_nodeid - */ typedef struct node_info { uint64_t node_mem; diff --git a/numa.c b/numa.c index 61531db..84d4cb5 100644 --- a/numa.c +++ b/numa.c @@ -45,8 +45,10 @@ QemuOptsList qemu_numa_opts = { }; static int have_memdevs = -1; +static int max_numa_nodeid; /* Highest specified NUMA node ID, plus one. + * For all nodes, nodeid < max_numa_nodeid + */ int nb_numa_nodes; -int max_numa_nodeid; NodeInfo numa_info[MAX_NODES]; static void numa_node_parse(NumaNodeOptions *node, QemuOpts *opts, Error **errp)