From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49246) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZuNos-0002C4-Me for qemu-devel@nongnu.org; Thu, 05 Nov 2015 11:55:30 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZuNom-0004Jm-IV for qemu-devel@nongnu.org; Thu, 05 Nov 2015 11:55:26 -0500 References: <1446736357-17610-1-git-send-email-wei@redhat.com> From: Wei Huang Message-ID: <563B89ED.70606@redhat.com> Date: Thu, 5 Nov 2015 10:55:09 -0600 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH Trivial] hw/intc/arm_gic: Use pre-defined macro for cpu_num in code List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: QEMU Trivial , qemu-arm@nongnu.org, =?UTF-8?Q?Andreas_F=c3=a4rber?= , QEMU Developers On 11/05/2015 09:31 AM, Peter Maydell wrote: > On 5 November 2015 at 15:12, Wei Huang wrote: >> Given that there is a macro, NUM_CPU(s), defined for CPU number in >> arm_gic.c, it is better to use it instead of using s->num_cpu in >> this file. Code is more consistent after this change. > > Hi. I think that actually since the NUM_CPU is just a relic from Looks like the relic was from c988bfadc9cab. I prefer macro for this case; but will fix based on your comments. Thanks, -Wei > when it used to possibly defined as something other than s->num_cpu, > we should go in the opposite direction, and remove the macro entirely > in favour of just using s->num_cpu directly. > > (PS: you forgot to cc qemu-devel.) > > thanks > -- PMM >