Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759296AbbLBS3H (ORCPT ); Wed, 2 Dec 2015 13:29:07 -0500 Received: from mail-lf0-f45.google.com ([209.85.215.45]:33162 "EHLO mail-lf0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754682AbbLBS3B (ORCPT ); Wed, 2 Dec 2015 13:29:01 -0500 Subject: Re: [PATCH v3 14/19] irqchip/mips-gic: Use gic_vpes instead of NR_CPUS To: Qais Yousef , linux-kernel@vger.kernel.org References: <1449058920-21011-1-git-send-email-qais.yousef@imgtec.com> <1449058920-21011-15-git-send-email-qais.yousef@imgtec.com> Cc: tglx@linutronix.de, jason@lakedaemon.net, marc.zyngier@arm.com, jiang.liu@linux.intel.com, ralf@linux-mips.org, linux-mips@linux-mips.org From: Sergei Shtylyov Organization: Cogent Embedded Message-ID: <565F3869.4020603@cogentembedded.com> Date: Wed, 2 Dec 2015 21:28:57 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.3.0 MIME-Version: 1.0 In-Reply-To: <1449058920-21011-15-git-send-email-qais.yousef@imgtec.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1294 Lines: 40 Hello. On 12/02/2015 03:21 PM, Qais Yousef wrote: > NR_CPUS is set by Kconfig and could be much higher than what actually is in the > system. > > gic_vpes should be a true representitives of the number of cpus in the system, > so use it instead. > > Signed-off-by: Qais Yousef > --- > drivers/irqchip/irq-mips-gic.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/irqchip/irq-mips-gic.c b/drivers/irqchip/irq-mips-gic.c > index 41ccc84c68ba..c24feb739bb3 100644 > --- a/drivers/irqchip/irq-mips-gic.c > +++ b/drivers/irqchip/irq-mips-gic.c [...] > @@ -1084,7 +1084,7 @@ static void __init __gic_init(unsigned long gic_base_addr, > gic_ipi_domain->bus_token = DOMAIN_BUS_IPI; > > /* Make the last 2 * NR_CPUS available for IPIs */ Looks like you forgot to also change this comment... > - bitmap_set(ipi_resrv, gic_shared_intrs - 2 * NR_CPUS, 2 * NR_CPUS); > + bitmap_set(ipi_resrv, gic_shared_intrs - 2 * gic_vpes, 2 * gic_vpes); > > gic_basic_init(); > MBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/