Hello,
Philippe Mathieu-Daudé writes:
> On 21/6/23 11:39, Philippe Mathieu-Daudé wrote:
>> On 21/6/23 07:19, Richard Henderson wrote:
>>> On 6/20/23 19:57, Peter Maydell wrote:
This manifests specifically in 'make check-tcg' failing, because code
in cpus-common.c that sets up the
>> This looks like the correct fix indeed :)
>> (Maybe worth adding a comment around).
>
> Agreed on both counts.
>
>> Thanks for investigating!
>
> And here as well :)
Thank you very much for investigating and fixing this problem, Laurent!
Sorry for not working on this issue. I was out on an extended weekend
and just came back.
--
Thiago Jung Bauermann
IBM Linux Technology Center
Philippe Mathieu-Daudé writes:
> On 8/26/20 7:55 AM, Thiago Jung Bauermann wrote:
>> Instead of setting CPUState::halted to 1 in ppce500_cpu_reset_sec(), use
>> the start-powered-off property which makes cpu_common_reset() initialize it
>> to 1 in common code.
>&g
David Gibson writes:
> On Wed, Aug 26, 2020 at 02:55:27AM -0300, Thiago Jung Bauermann wrote:
>> This version fixes `make check` failures in ppc/e500.c, mips/cps.c and
>> sparc/sun4m.c. This was done by moving the qdev_realize_and_unref() call as
>> close as possible to
wed-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
target/s390x/cpu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/s390x/cpu.c b/target/s390x/cpu.c
index 08eb674d22..73d7d6007e 100644
--- a/target/s390x/cpu.c
+++ b/target/s390x/cpu.c
@@ -291,7 +29
the CPU and it's not
possible to set a property after the object is realized.
Signed-off-by: Thiago Jung Bauermann
---
hw/mips/cps.c | 15 +++
1 file changed, 11 insertions(+), 4 deletions(-)
diff --git a/hw/mips/cps.c b/hw/mips/cps.c
index 615e1a1ad2..23c0f87e41 100644
--- a/hw/mips/cps.c
CPU and it's
not possible to set a property after the object is realized.
Suggested-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 25 ++---
1 file changed, 6 insertions(+), 19 deletions(-)
diff --git a/hw/sparc/sun4m.c b/hw/sparc/sun4
We rely on cpu_common_reset() to set cs->halted to 0, it's redundant to do
it in main_cpu_reset().
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/hw/sparc/sun4m.c b/hw/sparc/sun4m.c
index cf7dfa4af5..7484aa4438 100644
--- a/hw/sp
This change is in a separate patch because it's not so obvious that it
won't cause a regression.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Reviewed-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
hw/core/cpu.c| 2 +-
target/arm
the CPU and it's not
possible to set a property after the object is realized.
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/e500.c | 13 +
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c
index ab9884e315..ae39b9358e 100644
--- a/hw/ppc
et() function for main and secondary CPUs"
- Dropped.
Patch "target/s390x: Use start-powered-off CPUState property"
- Set the CPUState::start_powered_off variable directly rather than using
object_property_set_bool(). Suggested by Philippe.
- Mention in the commit message Eduardo's observati
it
wouldn't be a trivial change.
This change should not cause any change in behavior.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Reviewed-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
exec.c| 1 +
include/hw/core/cpu.h | 4
-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/spapr_cpu_core.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/hw/ppc/spapr_cpu_core.c b/hw/ppc/spapr_cpu_core.c
index c4f47dcc04..2125fdac34 100644
--- a/hw/ppc/spapr_cpu_core.c
+++ b/hw/ppc/spapr_cpu_core.c
Philippe Mathieu-Daudé writes:
> On 8/22/20 10:59 AM, Cédric Le Goater wrote:
>> Hello,
>>
>> On 8/19/20 6:43 PM, Thiago Jung Bauermann wrote:
>>> Instead of setting CPUState::halted to 1 in ppce500_cpu_reset_sec(), use
>>> the start-powered-of
Thiago Jung Bauermann writes:
> We rely on cpu_common_reset() to set cs->halted to 0, so main_cpu_reset()
> is pointless.
>
> Suggested-by: Philippe Mathieu-Daudé
> Reviewed-by: Philippe Mathieu-Daudé
> Reviewed-by: David Gibson
> Signed-off-by: Thiago Jung Baue
Philippe Mathieu-Daudé writes:
> On 8/22/20 10:59 AM, Cédric Le Goater wrote:
>> Hello,
>>
>> On 8/19/20 6:43 PM, Thiago Jung Bauermann wrote:
>>> Instead of setting CPUState::halted to 1 in ppce500_cpu_reset_sec(), use
>>> the start-powered-of
David Gibson writes:
> On Sat, Aug 22, 2020 at 10:59:56AM +0200, Cédric Le Goater wrote:
>> Hello,
>>
>> On 8/19/20 6:43 PM, Thiago Jung Bauermann wrote:
>> > Instead of setting CPUState::halted to 1 in ppce500_cpu_reset_sec(), use
>> > the
David Gibson writes:
> On Wed, Aug 19, 2020 at 01:42:58PM -0300, Thiago Jung Bauermann wrote:
>> This version has one small fix in patch 7, and adds Philippe's Reviewed-bys.
>>
>> Applies cleanly on dgibson/ppc-for-5.2.
>>
>> Original cover le
Philippe Mathieu-Daudé writes:
> On 8/19/20 6:43 PM, Thiago Jung Bauermann wrote:
>> Instead of setting CPUState::halted to 1 in secondary_cpu_reset(), use the
>> start-powered-off property which makes cpu_common_reset() initialize it
>> to 1 in common co
the CPU and it's not
possible to set a property after the object is realized.
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/mips/cps.c | 14 ++
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/hw/mips/cps.c b/hw/mips/cps.c
index 615e1a1ad2
wed-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
target/s390x/cpu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/s390x/cpu.c b/target/s390x/cpu.c
index 08eb674d22..73d7d6007e 100644
--- a/target/s390x/cpu.c
+++ b/target/s390x/cpu.c
@@ -291,7 +29
ter the object is realized.
Suggested-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 20
1 file changed, 4 insertions(+), 16 deletions(-)
diff --git a/hw/sparc/sun4m.c b/hw/sparc/sun4m.c
index 22c51dac8a..23991ccd47 100644
--- a/hw/sparc/sun4
the CPU and it's not
possible to set a property after the object is realized.
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/e500.c | 14 ++
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c
index
and secondary CPUs"
- Dropped.
Patch "target/s390x: Use start-powered-off CPUState property"
- Set the CPUState::start_powered_off variable directly rather than using
object_property_set_bool(). Suggested by Philippe.
- Mention in the commit message Eduardo's observation that before
-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/spapr_cpu_core.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/hw/ppc/spapr_cpu_core.c b/hw/ppc/spapr_cpu_core.c
index c4f47dcc04..2125fdac34 100644
--- a/hw/ppc/spapr_cpu_core.c
+++ b/hw/ppc/spapr_cpu_core.c
We rely on cpu_common_reset() to set cs->halted to 0, so main_cpu_reset()
is pointless.
Suggested-by: Philippe Mathieu-Daudé
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 13 +
1 file changed, 1 insert
This change is in a separate patch because it's not so obvious that it
won't cause a regression.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Reviewed-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
hw/core/cpu.c| 2 +-
target/arm
it
wouldn't be a trivial change.
This change should not cause any change in behavior.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Reviewed-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
exec.c| 1 +
include/hw/core/cpu.h | 4
Hi Philippe,
Philippe Mathieu-Daudé writes:
> On 8/19/20 4:42 AM, Thiago Jung Bauermann wrote:
>> Instead of setting CPUState::halted to 1 in secondary_cpu_reset(), use the
>> start-powered-off property which makes cpu_common_reset() initialize it
>> to 1 in common c
the CPU and it's not
possible to set a property after the object is realized.
Signed-off-by: Thiago Jung Bauermann
---
hw/mips/cps.c | 14 ++
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/hw/mips/cps.c b/hw/mips/cps.c
index 615e1a1ad2..4a98cf2287 100644
--- a/hw/mips/cps.c
ter the object is realized.
Suggested-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 21 +
1 file changed, 5 insertions(+), 16 deletions(-)
diff --git a/hw/sparc/sun4m.c b/hw/sparc/sun4m.c
index 22c51dac8a..1925f415e7 100644
--- a/hw/sparc/sun4
We rely on cpu_common_reset() to set cs->halted to 0, so main_cpu_reset()
is pointless.
Suggested-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 13 +
1 file changed, 1 insertion(+), 12 deletions(-)
diff --git a
the CPU and it's not
possible to set a property after the object is realized.
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/e500.c | 14 ++
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c
index ab9884e315..d7b803ef26 100644
--- a/hw/ppc
y rather than using
object_property_set_bool(). Suggested by Philippe.
- Mention in the commit message Eduardo's observation that before this
patch, the code didn't set cs->halted on reset.
Thiago Jung Bauermann (8):
target/arm: Move start-powered-off property to generic CPUState
target
it
wouldn't be a trivial change.
This change should not cause any change in behavior.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Reviewed-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
exec.c| 1 +
include/hw/core/cpu.h | 4
off-by: Thiago Jung Bauermann
---
target/s390x/cpu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/s390x/cpu.c b/target/s390x/cpu.c
index 08eb674d22..73d7d6007e 100644
--- a/target/s390x/cpu.c
+++ b/target/s390x/cpu.c
@@ -291,7 +291,7 @@ static void s390_cpu_initfn(Obj
This change is in a separate patch because it's not so obvious that it
won't cause a regression.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Reviewed-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
hw/core/cpu.c| 2 +-
target/arm
-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/spapr_cpu_core.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/hw/ppc/spapr_cpu_core.c b/hw/ppc/spapr_cpu_core.c
index c4f47dcc04..2125fdac34 100644
--- a/hw/ppc/spapr_cpu_core.c
+++ b/hw/ppc/spapr_cpu_core.c
Philippe Mathieu-Daudé writes:
> On 8/18/20 5:33 AM, Thiago Jung Bauermann wrote:
>> Instead of setting CPUState::halted to 1 in main_cpu_reset(), use the
>> start-powered-off property which makes cpu_common_reset() initialize it
>> to 1 in common code.
>>
>> A
Thiago Jung Bauermann writes:
> Hello Philippe,
>
> Thanks for your review.
>
> Philippe Mathieu-Daudé writes:
>
>> On 8/18/20 9:22 AM, Philippe Mathieu-Daudé wrote:
>>>> @@ -897,6 +895,19 @@ void ppce500_init(MachineState *machine)
>>>>
Hello Philippe,
Thanks for your review.
Philippe Mathieu-Daudé writes:
> On 8/18/20 9:22 AM, Philippe Mathieu-Daudé wrote:
>> On 8/18/20 5:33 AM, Thiago Jung Bauermann wrote:
>>> Instead of setting CPUState::halted to 1 in ppce500_cpu_reset_sec(), use
>>> the start
Hi Igor,
Thank you for reviewing these patches, and the tips you provided here
and on other messages on how to fix the refcount issues.
Igor Mammedov writes:
> On Tue, 18 Aug 2020 00:33:19 -0300
> Thiago Jung Bauermann wrote:
>
> [...]
>
>> Also change creation of CPU o
off-by: Thiago Jung Bauermann
---
target/s390x/cpu.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/target/s390x/cpu.c b/target/s390x/cpu.c
index 08eb674d22..73d7d6007e 100644
--- a/target/s390x/cpu.c
+++ b/target/s390x/cpu.c
@@ -291,7 +291,7 @@ static void s390_cpu_initfn(Obj
ect is realized.
Suggested-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 26 ++
1 file changed, 10 insertions(+), 16 deletions(-)
diff --git a/hw/sparc/sun4m.c b/hw/sparc/sun4m.c
index f1d92df781..41a7c5fa86 100644
--- a/hw/sparc/sun4
We rely on cpu_common_reset() to set cs->halted to 0, so main_cpu_reset()
is pointless.
Suggested-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 13 +
1 file changed, 1 insertion(+), 12 deletions(-)
diff --git a
not possible to
set a property after the object is realized.
Signed-off-by: Thiago Jung Bauermann
---
hw/mips/cps.c | 16
1 file changed, 12 insertions(+), 4 deletions(-)
diff --git a/hw/mips/cps.c b/hw/mips/cps.c
index 615e1a1ad2..be85357dc0 100644
--- a/hw/mips/cps.c
+++ b/hw
it
wouldn't be a trivial change.
This change should not cause any change in behavior.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Reviewed-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
exec.c| 1 +
include/hw/core/cpu.h | 4
and it's not possible
to set a property after the object is realized.
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/e500.c | 19 +++
1 file changed, 15 insertions(+), 4 deletions(-)
diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c
index ab9884e315..0077aca74d 100644
--- a/hw/ppc/e500
This change is in a separate patch because it's not so obvious that it
won't cause a regression.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Reviewed-by: David Gibson
Reviewed-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
hw/core/cpu.c| 2 +-
target/arm
-by: Greg Kurz
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/spapr_cpu_core.c | 10 +-
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/hw/ppc/spapr_cpu_core.c b/hw/ppc/spapr_cpu_core.c
index c4f47dcc04..2125fdac34 100644
--- a/hw/ppc/spapr_cpu_core.c
+++ b/hw/ppc/spapr_cpu_core.c
y"
- Set the CPUState::start_powered_off variable directly rather than using
object_property_set_bool(). Suggested by Philippe.
- Mention in the commit message Eduardo's observation that before this
patch, the code didn't set cs->halted on reset.
Thiago Jung Bauermann (8):
target/arm: Move star
David Gibson writes:
> On Mon, Aug 17, 2020 at 07:24:43AM +0200, Philippe Mathieu-Daudé wrote:
>> On 8/17/20 6:47 AM, David Gibson wrote:
>> > On Wed, Jul 22, 2020 at 11:56:49PM -0300, Thiago Jung Bauermann wrote:
>> >> The ARM code has a start-powered
Cornelia Huck writes:
> On Thu, 30 Jul 2020 11:45:41 +0200
> Cornelia Huck wrote:
>
>> On Tue, 28 Jul 2020 21:51:33 -0300
>> Thiago Jung Bauermann wrote:
>>
>> > Hi,
>> >
>> > Cornelia Huck writes:
>> >
>> >
Peter Maydell writes:
> On Wed, 5 Aug 2020 at 18:01, Thiago Jung Bauermann
> wrote:
>> Any news on this? Is there something I should be doing? I saw -rc3 today
>> but not these patches.
>
> Sorry, you've missed the bus for 5.1 at this point. I'd assumed
Thiago Jung Bauermann writes:
> Philippe Mathieu-Daudé writes:
>
>> Le jeu. 30 juil. 2020 03:00, David Gibson a
>> écrit :
>>
>>> On Tue, Jul 28, 2020 at 09:56:36PM -0300, Thiago Jung Bauermann wrote:
>>> >
>>> > Thiago Jung Bauerman
Philippe Mathieu-Daudé writes:
> Le jeu. 30 juil. 2020 03:00, David Gibson a
> écrit :
>
>> On Tue, Jul 28, 2020 at 09:56:36PM -0300, Thiago Jung Bauermann wrote:
>> >
>> > Thiago Jung Bauermann writes:
>> >
>> > > The ARM
Thiago Jung Bauermann writes:
> The ARM code has a start-powered-off property in ARMCPU, which is a
> subclass of CPUState. This property causes arm_cpu_reset() to set
> CPUState::halted to 1, signalling that the CPU should start in a halted
> state. Other architectures also hav
Hi,
Cornelia Huck writes:
> On Wed, 22 Jul 2020 23:56:57 -0300
> Thiago Jung Bauermann wrote:
>
>> Instead of setting CPUState::halted to 1 in s390_cpu_initfn(), use the
>> start-powered-off property which makes cpu_common_reset() initialize it
>> to 1
Greg Kurz writes:
> On Wed, 22 Jul 2020 23:56:52 -0300
> Thiago Jung Bauermann wrote:
>
>> PowerPC sPAPR CPUs start in the halted state, and spapr_reset_vcpu()
>> attempts to implement this by setting CPUState::halted to 1. But that's too
>> late for the case of h
Greg Kurz writes:
> On Thu, 23 Jul 2020 13:06:09 +1000
> David Gibson wrote:
>
>> On Wed, Jul 22, 2020 at 11:56:50PM -0300, Thiago Jung Bauermann wrote:
>> > There are other platforms which also have CPUs that start powered off, so
>> > generalize the start-po
David Gibson writes:
> On Wed, Jul 22, 2020 at 11:56:50PM -0300, Thiago Jung Bauermann wrote:
>> There are other platforms which also have CPUs that start powered off, so
>> generalize the start-powered-off property so that it can be used by them.
>>
>> Not
Hello David,
David Gibson writes:
> On Wed, Jul 22, 2020 at 12:50:08AM -0300, Thiago Jung Bauermann wrote:
>> There are other platforms which also have CPUs that start powered off, so
>> generalize the start-powered-off property so that it can be used by them.
>>
>
ems out of
place when compared to similar code in other architectures (e.g.,
ppce500_init() in hw/ppc/e500.c).
Suggested-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 17 ++---
1 file changed, 2 insertions(+), 15 deletions(-)
NB: I was only a
We rely on cpu_common_reset() to set cs->halted to 0, so main_cpu_reset()
is pointless.
Suggested-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 13 +
1 file changed, 1 insertion(+), 12 deletions(-)
NB: I was only able to t
Instead of setting CPUState::halted to 1 in s390_cpu_initfn(), use the
start-powered-off property which makes cpu_common_reset() initialize it
to 1 in common code.
Note that this changes behavior by setting cs->halted to 1 on reset, which
didn't happen before.
Signed-off-by: Thiago J
causes it to see a stray vCPU that doesn't belong to
any guest.
Fix by setting the start-powered-off CPUState property in
spapr_create_vcpu(), which makes cpu_common_reset() initialize
CPUState::halted to 1 at an earlier moment.
Suggested-by: Eduardo Habkost
Signed-off-by: Thiago Jung Bauermann
Instead of setting CPUState::halted to 1 in ppce500_cpu_reset_sec(), use
the start-powered-off property which makes cpu_common_reset() initialize it
to 1 in common code.
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/e500.c | 10 +++---
1 file changed
roperty_set_bool(). Suggested by Philippe.
- Mention in the commit message Eduardo's observation that before this
patch, the code didn't set cs->halted on reset.
Thiago Jung Bauermann (8):
target/arm: Move start-powered-off property to generic CPUState
target/arm: Move setting of CPU hal
Instead of setting CPUState::halted to 1 in main_cpu_reset(), use the
start-powered-off property which makes cpu_common_reset() initialize it
to 1 in common code.
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/mips/cps.c | 6 +++---
1 file changed, 3 insertions
it
wouldn't be a trivial change.
This change should not cause any change in behavior.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
exec.c| 1 +
include/hw/core/cpu.h | 4
target/arm/cpu.c | 5 ++---
target/arm
This change is in a separate patch because it's not so obvious that it
won't cause a regression.
Suggested-by: Eduardo Habkost
Reviewed-by: Philippe Mathieu-Daudé
Signed-off-by: Thiago Jung Bauermann
---
hw/core/cpu.c| 2 +-
target/arm/cpu.c | 1 -
2 files changed, 1 insertion(+), 2
Eduardo Habkost writes:
> On Wed, Jul 22, 2020 at 12:50:16AM -0300, Thiago Jung Bauermann wrote:
>> Instead of setting CPUState::halted to 1 in s390_cpu_initfn(), use the
>> start-powered-off property which makes cpu_common_reset() initialize it to
>> 1 in common c
Philippe Mathieu-Daudé writes:
> On 7/22/20 5:50 AM, Thiago Jung Bauermann wrote:
>> Instead of setting CPUState::halted to 1 in s390_cpu_initfn(), use the
>> start-powered-off property which makes cpu_common_reset() initialize it to
>> 1 in common code.
>>
&g
Philippe Mathieu-Daudé writes:
> On 7/22/20 5:50 AM, Thiago Jung Bauermann wrote:
>> If we rely on cpu_common_reset() setting CPUState::halted according to the
>> start-powered-off property, both reset functions become equivalent and we
>> can use only one.
>>
&g
Philippe Mathieu-Daudé writes:
> On 7/22/20 5:50 AM, Thiago Jung Bauermann wrote:
>> Remove setting of cs->halted from cpu_devinit(), which seems out of place
>> when compared to similar code in other architectures (e.g., ppce500_init()
>> in hw/ppc/e500.c).
>>
Philippe Mathieu-Daudé writes:
> On 7/22/20 5:50 AM, Thiago Jung Bauermann wrote:
>> Instead of setting CPUState::halted to 1 in main_cpu_reset(), use the
>> start-powered-off property which makes cpu_common_reset() initialize it
>> to 1 in common code.
>>
&g
Philippe Mathieu-Daudé writes:
> On 7/22/20 5:50 AM, Thiago Jung Bauermann wrote:
>> PowerPC sPAPR CPUs start in the halted state, and spapr_reset_vcpu()
>> attempts to implement this by setting CPUState::halted to 1. But that's too
>> late for the case of hotplug
Philippe Mathieu-Daudé writes:
> Hi Thiago,
>
> On 7/22/20 5:50 AM, Thiago Jung Bauermann wrote:
>> There are other platforms which also have CPUs that start powered off, so
>> generalize the start-powered-off property so that it can be used by them.
>>
>&g
Instead of setting CPUState::halted to 1 in s390_cpu_initfn(), use the
start-powered-off property which makes cpu_common_reset() initialize it to
1 in common code.
Signed-off-by: Thiago Jung Bauermann
---
target/s390x/cpu.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
NB: I was only
Remove setting of cs->halted from cpu_devinit(), which seems out of place
when compared to similar code in other architectures (e.g., ppce500_init()
in hw/ppc/e500.c).
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 1 -
1 file changed, 1 deletion(-)
NB: I was only able to t
Instead of setting CPUState::halted to 1 in ppce500_cpu_reset_sec(), use
the start-powered-off property which makes cpu_common_reset() initialize it
to 1 in common code.
Signed-off-by: Thiago Jung Bauermann
---
hw/ppc/e500.c | 10 +++---
1 file changed, 7 insertions(+), 3 deletions(-)
NB
If we rely on cpu_common_reset() setting CPUState::halted according to the
start-powered-off property, both reset functions become equivalent and we
can use only one.
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 21 -
1 file changed, 4 insertions(+), 17
Instead of setting CPUState::halted to 1 in main_cpu_reset(), use the
start-powered-off property which makes cpu_common_reset() initialize it
to 1 in common code.
Signed-off-by: Thiago Jung Bauermann
---
hw/mips/cps.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
NB: I was only
Instead of setting CPUState::halted to 1 in secondary_cpu_reset(), use the
start-powered-off property which makes cpu_common_reset() initialize it
to 1 in common code.
Signed-off-by: Thiago Jung Bauermann
---
hw/sparc/sun4m.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
NB: I
causes it to see a stray vCPU that doesn't belong to
any guest.
Fix by setting the start-powered-off CPUState property in
spapr_create_vcpu(), which makes cpu_common_reset() initialize
CPUState::halted to 1 at an earlier moment.
Suggested-by: Eduardo Habkost
Signed-off-by: Thiago Jung Bauermann
it
wouldn't be a trivial change.
This change should not cause any change in behavior.
Suggested-by: Eduardo Habkost
Signed-off-by: Thiago Jung Bauermann
---
exec.c| 1 +
include/hw/core/cpu.h | 4
target/arm/cpu.c | 5 ++---
target/arm/cpu.h | 3 ---
target/arm/kvm32.c
This change is in a separate patch because it's not so obvious that it
won't cause a regression.
Suggested-by: Eduardo Habkost
Signed-off-by: Thiago Jung Bauermann
---
hw/core/cpu.c| 2 +-
target/arm/cpu.c | 1 -
2 files changed, 1 insertion(+), 2 deletions(-)
NB: I was only able to test
QOM lifecycle is basically non-existant so
please be aware of that when reviewing this series.
The last 3 patches I think are good cleanups but I'm even less confident in
their correctness compared to the other patches, so I marked them as RFC.
Applies cleanly on yesterday's master.
Thiago J
Alex Bennée writes:
> Thiago Jung Bauermann writes:
>
>> Eduardo Habkost writes:
>>
>>> On Wed, Jul 08, 2020 at 09:11:55PM +0100, Peter Maydell wrote:
>>>> On Wed, 8 Jul 2020 at 18:36, Eduardo Habkost wrote:
>>>> >
>>>&g
Philippe Mathieu-Daudé writes:
> On 7/9/20 5:26 AM, Thiago Jung Bauermann wrote:
>>
>> Thiago Jung Bauermann writes:
>>
>>> I'm seeing the vcpu being KVM_RUN'd too early twice during hotplug.
>>> Both of them are before cpu_reset() and ppc_cpu_r
Thiago Jung Bauermann writes:
> I'm seeing the vcpu being KVM_RUN'd too early twice during hotplug.
> Both of them are before cpu_reset() and ppc_cpu_reset().
Hm, rereading the message obviously the above is partially wrong. The
second case happens during ppc_cpu_reset().
> Here's t
Is there
something wrong with that? I don't know anything about the QEMU device
model to be able to tell.
One other way I found to avoid the spurious KVM_RUN calls is to remove
the cpu_resume() call in cpu_common_realizefn(), which to me seems to
be placed way too early in the CPU hotplug path. Simply removing it
makes CPU hotplug stop working though. :-) I still have to see if I can
find a better place for it...
--
Thiago Jung Bauermann
IBM Linux Technology Center
Hello Eduardo,
Eduardo Habkost writes:
> On Tue, Jul 07, 2020 at 05:43:33PM -0300, Thiago Jung Bauermann wrote:
>> PowerPC sPAPRs CPUs start in the halted state, but generic QEMU code
>> assumes that CPUs start in the non-halted state. spapr_reset_vcpu()
>> attempts to re
call to map vCPUs to guests, and
this issue causes it to see a stray vCPU that doesn't belong to any guest.
Fix by adding a starts_halted() method to the CPUState class, and making it
return 1 if the machine is an sPAPR guest.
Signed-off-by: Thiago Jung Bauermann
---
hw/core/cpu.c
David Gibson writes:
> On Fri, Jun 05, 2020 at 05:01:07PM -0300, Thiago Jung Bauermann wrote:
>>
>> Paolo Bonzini writes:
>>
>> > On 05/06/20 01:30, Thiago Jung Bauermann wrote:
>> >> Paolo Bonzini writes:
>> >>> On 04/06/20 23:5
Paolo Bonzini writes:
> On 05/06/20 01:30, Thiago Jung Bauermann wrote:
>> Paolo Bonzini writes:
>>> On 04/06/20 23:54, Thiago Jung Bauermann wrote:
>>>> QEMU could always create a PEF object, and if the command line defines
>>>> one, it will corresp
Paolo Bonzini writes:
> On 04/06/20 23:54, Thiago Jung Bauermann wrote:
>> QEMU could always create a PEF object, and if the command line defines
>> one, it will correspond to it. And if the command line doesn't define one,
>> then it would also work because the
David Gibson writes:
> On Thu, Jun 04, 2020 at 01:39:22AM -0300, Thiago Jung Bauermann wrote:
>>
>> Hello David,
>>
>> David Gibson writes:
>>
>> > A number of hardware platforms are implementing mechanisms whereby the
>> > hypervi
emory-protection property is specified?
Regardless, I was able to successfuly launch POWER PEF guests using
these patches:
Tested-by: Thiago Jung Bauermann
> can be extended to cover the Intel and s390 mechanisms as well,
> though.
>
> Note: I'm using the term "guest memory protecti
Markus Armbruster <arm...@redhat.com> writes:
> Thiago Jung Bauermann <bauer...@linux.vnet.ibm.com> writes:
>
>> At least in some configurations, setting c-file-style is not enough to
>> conform to the QEMU coding style, so explicitly set c-basic-offset as well.
&g
1 - 100 of 104 matches
Mail list logo