mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-07 01:33:56 -06:00
cpu: Replace cpu_single_env with CPUState current_cpu
Move it to qom/cpu.h. Signed-off-by: Andreas Färber <afaerber@suse.de>
This commit is contained in:
parent
80b7cd7354
commit
4917cf4432
23 changed files with 120 additions and 115 deletions
|
@ -49,13 +49,11 @@ typedef struct {
|
|||
|
||||
static inline int get_current_cpu(ARMMPTimerState *s)
|
||||
{
|
||||
CPUState *cpu_single_cpu = ENV_GET_CPU(cpu_single_env);
|
||||
|
||||
if (cpu_single_cpu->cpu_index >= s->num_cpu) {
|
||||
if (current_cpu->cpu_index >= s->num_cpu) {
|
||||
hw_error("arm_mptimer: num-cpu %d but this cpu is %d!\n",
|
||||
s->num_cpu, cpu_single_cpu->cpu_index);
|
||||
s->num_cpu, current_cpu->cpu_index);
|
||||
}
|
||||
return cpu_single_cpu->cpu_index;
|
||||
return current_cpu->cpu_index;
|
||||
}
|
||||
|
||||
static inline void timerblock_update_irq(TimerBlock *tb)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue