* Re: [Qemu-devel] [PATCH Trivial] hw/intc/arm_gic: Use pre-defined macro for cpu_num in code
[not found] <1446736357-17610-1-git-send-email-wei@redhat.com>
@ 2015-11-05 15:31 ` Peter Maydell
2015-11-05 16:55 ` Wei Huang
0 siblings, 1 reply; 2+ messages in thread
From: Peter Maydell @ 2015-11-05 15:31 UTC (permalink / raw)
To: Wei Huang; +Cc: QEMU Trivial, qemu-arm, Andreas Färber, QEMU Developers
On 5 November 2015 at 15:12, Wei Huang <wei@redhat.com> 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
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
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH Trivial] hw/intc/arm_gic: Use pre-defined macro for cpu_num in code
2015-11-05 15:31 ` [Qemu-devel] [PATCH Trivial] hw/intc/arm_gic: Use pre-defined macro for cpu_num in code Peter Maydell
@ 2015-11-05 16:55 ` Wei Huang
0 siblings, 0 replies; 2+ messages in thread
From: Wei Huang @ 2015-11-05 16:55 UTC (permalink / raw)
To: Peter Maydell
Cc: QEMU Trivial, qemu-arm, Andreas Färber, QEMU Developers
On 11/05/2015 09:31 AM, Peter Maydell wrote:
> On 5 November 2015 at 15:12, Wei Huang <wei@redhat.com> 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
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-11-05 16:55 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1446736357-17610-1-git-send-email-wei@redhat.com>
2015-11-05 15:31 ` [Qemu-devel] [PATCH Trivial] hw/intc/arm_gic: Use pre-defined macro for cpu_num in code Peter Maydell
2015-11-05 16:55 ` Wei Huang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).