* [Qemu-devel] [PATCH] pseries: Fix breakage in CPU QOM conversion
@ 2013-03-15 3:59 David Gibson
2013-03-15 12:39 ` Alexander Graf
2013-03-15 17:29 ` Andreas Färber
0 siblings, 2 replies; 4+ messages in thread
From: David Gibson @ 2013-03-15 3:59 UTC (permalink / raw)
To: agraf; +Cc: David Gibson, qemu-ppc, afaerber, qemu-devel
Commit 259186a7d2f7184efc96ae99bc5658e6159f53ad "cpu: Move halted and
interrupt_request fields to CPUState" broke the pseries machine. That's
because it uses CPU() instead of ENV_GET_CPU() to convert from the global
first_cpu pointer (still a CPUArchState) to a CPUState. This patch fixes
the breakage.
Cc: Andreas Färber <afaerber@suse.de>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
---
hw/ppc/spapr.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
index 0c51d04..b776d34 100644
--- a/hw/ppc/spapr.c
+++ b/hw/ppc/spapr.c
@@ -645,7 +645,7 @@ static void ppc_spapr_reset(void)
spapr->rtas_size);
/* Set up the entry state */
- first_cpu_cpu = CPU(first_cpu);
+ first_cpu_cpu = ENV_GET_CPU(first_cpu);
first_cpu->gpr[3] = spapr->fdt_addr;
first_cpu->gpr[5] = 0;
first_cpu_cpu->halted = 0;
--
1.7.10.4
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [Qemu-devel] [PATCH] pseries: Fix breakage in CPU QOM conversion
2013-03-15 3:59 [Qemu-devel] [PATCH] pseries: Fix breakage in CPU QOM conversion David Gibson
@ 2013-03-15 12:39 ` Alexander Graf
2013-03-15 17:29 ` Andreas Färber
1 sibling, 0 replies; 4+ messages in thread
From: Alexander Graf @ 2013-03-15 12:39 UTC (permalink / raw)
To: David Gibson; +Cc: qemu-ppc, afaerber, qemu-devel
On 15.03.2013, at 04:59, David Gibson wrote:
> Commit 259186a7d2f7184efc96ae99bc5658e6159f53ad "cpu: Move halted and
> interrupt_request fields to CPUState" broke the pseries machine. That's
> because it uses CPU() instead of ENV_GET_CPU() to convert from the global
> first_cpu pointer (still a CPUArchState) to a CPUState. This patch fixes
> the breakage.
>
> Cc: Andreas Färber <afaerber@suse.de>
> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
Thanks, applied to ppc-next.
Alex
> ---
> hw/ppc/spapr.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
> index 0c51d04..b776d34 100644
> --- a/hw/ppc/spapr.c
> +++ b/hw/ppc/spapr.c
> @@ -645,7 +645,7 @@ static void ppc_spapr_reset(void)
> spapr->rtas_size);
>
> /* Set up the entry state */
> - first_cpu_cpu = CPU(first_cpu);
> + first_cpu_cpu = ENV_GET_CPU(first_cpu);
> first_cpu->gpr[3] = spapr->fdt_addr;
> first_cpu->gpr[5] = 0;
> first_cpu_cpu->halted = 0;
> --
> 1.7.10.4
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Qemu-devel] [PATCH] pseries: Fix breakage in CPU QOM conversion
2013-03-15 3:59 [Qemu-devel] [PATCH] pseries: Fix breakage in CPU QOM conversion David Gibson
2013-03-15 12:39 ` Alexander Graf
@ 2013-03-15 17:29 ` Andreas Färber
2013-03-16 9:11 ` [Qemu-devel] [Qemu-ppc] " David Gibson
1 sibling, 1 reply; 4+ messages in thread
From: Andreas Färber @ 2013-03-15 17:29 UTC (permalink / raw)
To: David Gibson; +Cc: qemu-ppc, agraf, qemu-devel
Am 15.03.2013 04:59, schrieb David Gibson:
> Commit 259186a7d2f7184efc96ae99bc5658e6159f53ad "cpu: Move halted and
> interrupt_request fields to CPUState" broke the pseries machine. That's
> because it uses CPU() instead of ENV_GET_CPU() to convert from the global
> first_cpu pointer (still a CPUArchState) to a CPUState. This patch fixes
> the breakage.
>
> Cc: Andreas Färber <afaerber@suse.de>
> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
> ---
> hw/ppc/spapr.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
> index 0c51d04..b776d34 100644
> --- a/hw/ppc/spapr.c
> +++ b/hw/ppc/spapr.c
> @@ -645,7 +645,7 @@ static void ppc_spapr_reset(void)
> spapr->rtas_size);
>
> /* Set up the entry state */
> - first_cpu_cpu = CPU(first_cpu);
> + first_cpu_cpu = ENV_GET_CPU(first_cpu);
> first_cpu->gpr[3] = spapr->fdt_addr;
> first_cpu->gpr[5] = 0;
> first_cpu_cpu->halted = 0;
Oops,
Acked-by: Andreas Färber <afaerber@suse.de>
Did you check the commit if there's more instances of that bug?
Andreas
--
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [Qemu-devel] [Qemu-ppc] [PATCH] pseries: Fix breakage in CPU QOM conversion
2013-03-15 17:29 ` Andreas Färber
@ 2013-03-16 9:11 ` David Gibson
0 siblings, 0 replies; 4+ messages in thread
From: David Gibson @ 2013-03-16 9:11 UTC (permalink / raw)
To: Andreas Färber; +Cc: qemu-ppc, qemu-devel
[-- Attachment #1: Type: text/plain, Size: 1502 bytes --]
On Fri, Mar 15, 2013 at 06:29:50PM +0100, Andreas Färber wrote:
> Am 15.03.2013 04:59, schrieb David Gibson:
> > Commit 259186a7d2f7184efc96ae99bc5658e6159f53ad "cpu: Move halted and
> > interrupt_request fields to CPUState" broke the pseries machine. That's
> > because it uses CPU() instead of ENV_GET_CPU() to convert from the global
> > first_cpu pointer (still a CPUArchState) to a CPUState. This patch fixes
> > the breakage.
> >
> > Cc: Andreas Färber <afaerber@suse.de>
> > Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
> > ---
> > hw/ppc/spapr.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/hw/ppc/spapr.c b/hw/ppc/spapr.c
> > index 0c51d04..b776d34 100644
> > --- a/hw/ppc/spapr.c
> > +++ b/hw/ppc/spapr.c
> > @@ -645,7 +645,7 @@ static void ppc_spapr_reset(void)
> > spapr->rtas_size);
> >
> > /* Set up the entry state */
> > - first_cpu_cpu = CPU(first_cpu);
> > + first_cpu_cpu = ENV_GET_CPU(first_cpu);
> > first_cpu->gpr[3] = spapr->fdt_addr;
> > first_cpu->gpr[5] = 0;
> > first_cpu_cpu->halted = 0;
>
> Oops,
>
> Acked-by: Andreas Färber <afaerber@suse.de>
>
> Did you check the commit if there's more instances of that bug?
I did not; sorry.
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-03-16 9:47 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-03-15 3:59 [Qemu-devel] [PATCH] pseries: Fix breakage in CPU QOM conversion David Gibson
2013-03-15 12:39 ` Alexander Graf
2013-03-15 17:29 ` Andreas Färber
2013-03-16 9:11 ` [Qemu-devel] [Qemu-ppc] " David Gibson
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).