Skip to content

Commit

Permalink
target/arm: Move setting of CPU halted state to generic code
Browse files Browse the repository at this point in the history
This change is in a separate patch because it's not so obvious that it
won't cause a regression.

Suggested-by: Eduardo Habkost <ehabkost@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Reviewed-by: David Gibson <david@gibson.dropbear.id.au>
Reviewed-by: Greg Kurz <groug@kaod.org>
Signed-off-by: Thiago Jung Bauermann <bauerman@linux.ibm.com>
Message-Id: <20200826055535.951207-3-bauerman@linux.ibm.com>
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
  • Loading branch information
bauermann authored and dgibson committed Sep 8, 2020
1 parent c1b7015 commit 6ad1da6
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
2 changes: 1 addition & 1 deletion hw/core/cpu.c
Expand Up @@ -258,7 +258,7 @@ static void cpu_common_reset(DeviceState *dev)
}

cpu->interrupt_request = 0;
cpu->halted = 0;
cpu->halted = cpu->start_powered_off;
cpu->mem_io_pc = 0;
cpu->icount_extra = 0;
atomic_set(&cpu->icount_decr_ptr->u32, 0);
Expand Down
1 change: 0 additions & 1 deletion target/arm/cpu.c
Expand Up @@ -175,7 +175,6 @@ static void arm_cpu_reset(DeviceState *dev)
env->vfp.xregs[ARM_VFP_MVFR2] = cpu->isar.mvfr2;

cpu->power_state = s->start_powered_off ? PSCI_OFF : PSCI_ON;
s->halted = s->start_powered_off;

if (arm_feature(env, ARM_FEATURE_IWMMXT)) {
env->iwmmxt.cregs[ARM_IWMMXT_wCID] = 0x69051000 | 'Q';
Expand Down

0 comments on commit 6ad1da6

Please sign in to comment.