From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44306) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XPQCB-0003fm-A0 for qemu-devel@nongnu.org; Thu, 04 Sep 2014 02:07:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XPQBx-0004Hf-Sx for qemu-devel@nongnu.org; Thu, 04 Sep 2014 02:06:59 -0400 Received: from e28smtp03.in.ibm.com ([122.248.162.3]:57344) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XPQBw-0004Gf-Lw for qemu-devel@nongnu.org; Thu, 04 Sep 2014 02:06:45 -0400 Received: from /spool/local by e28smtp03.in.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 4 Sep 2014 11:36:41 +0530 Received: from d28relay03.in.ibm.com (d28relay03.in.ibm.com [9.184.220.60]) by d28dlp01.in.ibm.com (Postfix) with ESMTP id 3E3B5E006B for ; Thu, 4 Sep 2014 11:38:57 +0530 (IST) Received: from d28av01.in.ibm.com (d28av01.in.ibm.com [9.184.220.63]) by d28relay03.in.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id s8468vGk4456844 for ; Thu, 4 Sep 2014 11:38:58 +0530 Received: from d28av01.in.ibm.com (localhost [127.0.0.1]) by d28av01.in.ibm.com (8.14.4/8.14.4/NCO v10.0 AVout) with ESMTP id s8466Y8S017810 for ; Thu, 4 Sep 2014 11:36:34 +0530 From: Bharata B Rao Date: Thu, 4 Sep 2014 11:36:19 +0530 Message-Id: <1409810785-12391-10-git-send-email-bharata@linux.vnet.ibm.com> In-Reply-To: <1409810785-12391-1-git-send-email-bharata@linux.vnet.ibm.com> References: <1409810785-12391-1-git-send-email-bharata@linux.vnet.ibm.com> Subject: [Qemu-devel] [RFC PATCH v0 09/15] ppc: Consider max_cpus during xics initialization List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: mdroth@linux.vnet.ibm.com, Bharata B Rao Use max_cpus instead of smp_cpus when intializating xics system. Also report max_cpus in ibm,interrupt-server-ranges device tree property of interrupt controller node. Signed-off-by: Bharata B Rao --- hw/ppc/spapr.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c index fc6b923..b2ca527 100644 --- a/hw/ppc/spapr.c +++ b/hw/ppc/spapr.c @@ -633,7 +633,7 @@ static void *spapr_create_fdt_skel(hwaddr initrd_base, GString *hypertas = g_string_sized_new(256); GString *qemu_hypertas = g_string_sized_new(256); uint32_t refpoints[] = {cpu_to_be32(0x4), cpu_to_be32(0x4)}; - uint32_t interrupt_server_ranges_prop[] = {0, cpu_to_be32(smp_cpus)}; + uint32_t interrupt_server_ranges_prop[] = {0, cpu_to_be32(max_cpus)}; int smt = kvmppc_smt_threads(); unsigned char vec5[] = {0x0, 0x0, 0x0, 0x0, 0x0, 0x80}; QemuOpts *opts = qemu_opts_find(qemu_find_opts("smp-opts"), NULL); @@ -1684,7 +1684,7 @@ static void ppc_spapr_init(MachineState *machine) } /* Set up Interrupt Controller before we create the VCPUs */ - spapr->icp = xics_system_init(smp_cpus * kvmppc_smt_threads() / smp_threads, + spapr->icp = xics_system_init(max_cpus * kvmppc_smt_threads() / smp_threads, XICS_IRQS); spapr_init_drc_table(); -- 1.7.11.7