From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Campbell Subject: Re: [PATCH for-4.6 1/4] xen/arm: vgic: Rename nr_lines into nr_spis Date: Tue, 13 Jan 2015 15:59:25 +0000 Message-ID: <1421164765.19103.135.camel@citrix.com> References: <1418395392-30460-1-git-send-email-julien.grall@linaro.org> <1418395392-30460-2-git-send-email-julien.grall@linaro.org> <1421163492.19103.119.camel@citrix.com> <54B53F5A.7070306@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1YB3uG-0007Bz-6N for xen-devel@lists.xenproject.org; Tue, 13 Jan 2015 16:01:24 +0000 In-Reply-To: <54B53F5A.7070306@linaro.org> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Julien Grall Cc: xen-devel@lists.xenproject.org, stefano.stabellini@citrix.com, tim@xen.org, parth.dixit@linaro.org, christoffer.dall@linaro.org List-Id: xen-devel@lists.xenproject.org On Tue, 2015-01-13 at 15:52 +0000, Julien Grall wrote: > Hi Ian, > > On 13/01/15 15:38, Ian Campbell wrote: > > On Fri, 2014-12-12 at 14:43 +0000, Julien Grall wrote: > >> The field nr_lines in the arch_domain vgic structure contains the number of > >> SPIs for the emulated GIC. Using the nr_lines make confusion with the GIC > >> code, where it means the number of IRQs. This can lead to coding error. > >> > >> Also introduce vgic_nr_lines to get the number of IRQ handled by the emulated > >> GIC. > > > > From the code you seem to have called it vgic_nr_irqs, which I prefer. > > It's an error in the commit message. I will fix it in the next version. > > > >> diff --git a/xen/arch/arm/gic-v2.c b/xen/arch/arm/gic-v2.c > >> index faad1ff..31fb81a 100644 > >> --- a/xen/arch/arm/gic-v2.c > >> +++ b/xen/arch/arm/gic-v2.c > >> @@ -432,8 +432,6 @@ static int gicv2v_setup(struct domain *d) > >> d->arch.vgic.cbase = GUEST_GICC_BASE; > >> } > >> > >> - d->arch.vgic.nr_lines = 0; > > > > Not replaced with an assignment to nr_spis, as you do in the v3 case? > > > > We should be consistent, which also makes me wonder if nr_lines^Wspis > > should be the responsibility of the common vgic code to setup. > > Actually it's already in common vgic code (see domain_vgic_init). > > The initialization in gicv2v_setup was unnecessary, so does in > gic_v3_init. I just forgot to drop it. > > Shall I create a separate patch for the 2 lines drop? Or add a comment > in the commit message? Either works for me. Ian.