diff options
Diffstat (limited to 'hw')
| -rw-r--r-- | hw/alpha/typhoon.c | 14 | ||||
| -rw-r--r-- | hw/i386/kvm/apic.c | 2 | ||||
| -rw-r--r-- | hw/i386/kvmvapic.c | 4 | ||||
| -rw-r--r-- | hw/i386/multiboot.c | 2 | ||||
| -rw-r--r-- | hw/i386/pc.c | 2 | ||||
| -rw-r--r-- | hw/mips/mips_fulong2e.c | 2 | ||||
| -rw-r--r-- | hw/mips/mips_jazz.c | 2 | ||||
| -rw-r--r-- | hw/mips/mips_malta.c | 2 | ||||
| -rw-r--r-- | hw/misc/vmport.c | 2 | ||||
| -rw-r--r-- | hw/ppc/ppce500_spin.c | 2 | ||||
| -rw-r--r-- | hw/ppc/prep.c | 2 | ||||
| -rw-r--r-- | hw/ppc/spapr_rtas.c | 2 |
12 files changed, 21 insertions, 17 deletions
diff --git a/hw/alpha/typhoon.c b/hw/alpha/typhoon.c index 1ead1877c7..207dcad2a3 100644 --- a/hw/alpha/typhoon.c +++ b/hw/alpha/typhoon.c @@ -197,7 +197,8 @@ static uint64_t cchip_read(void *opaque, hwaddr addr, unsigned size) break; default: - cpu_unassigned_access(cpu_single_env, addr, 0, 0, 0, size); + cpu = CPU(alpha_env_get_cpu(cpu_single_env)); + cpu_unassigned_access(cpu, addr, false, false, 0, size); return -1; } @@ -214,6 +215,7 @@ static uint64_t dchip_read(void *opaque, hwaddr addr, unsigned size) static uint64_t pchip_read(void *opaque, hwaddr addr, unsigned size) { TyphoonState *s = opaque; + CPUState *cs; uint64_t ret = 0; if (addr & 4) { @@ -300,7 +302,8 @@ static uint64_t pchip_read(void *opaque, hwaddr addr, unsigned size) break; default: - cpu_unassigned_access(cpu_single_env, addr, 0, 0, 0, size); + cs = CPU(alpha_env_get_cpu(cpu_single_env)); + cpu_unassigned_access(cs, addr, false, false, 0, size); return -1; } @@ -312,6 +315,7 @@ static void cchip_write(void *opaque, hwaddr addr, uint64_t v32, unsigned size) { TyphoonState *s = opaque; + CPUState *cpu_single_cpu = CPU(alpha_env_get_cpu(cpu_single_env)); uint64_t val, oldval, newval; if (addr & 4) { @@ -461,7 +465,7 @@ static void cchip_write(void *opaque, hwaddr addr, break; default: - cpu_unassigned_access(cpu_single_env, addr, 1, 0, 0, size); + cpu_unassigned_access(cpu_single_cpu, addr, true, false, 0, size); return; } } @@ -476,6 +480,7 @@ static void pchip_write(void *opaque, hwaddr addr, uint64_t v32, unsigned size) { TyphoonState *s = opaque; + CPUState *cs; uint64_t val, oldval; if (addr & 4) { @@ -577,7 +582,8 @@ static void pchip_write(void *opaque, hwaddr addr, break; default: - cpu_unassigned_access(cpu_single_env, addr, 1, 0, 0, size); + cs = CPU(alpha_env_get_cpu(cpu_single_env)); + cpu_unassigned_access(cs, addr, true, false, 0, size); return; } } diff --git a/hw/i386/kvm/apic.c b/hw/i386/kvm/apic.c index 8f80425ccc..bd0bdd8590 100644 --- a/hw/i386/kvm/apic.c +++ b/hw/i386/kvm/apic.c @@ -129,7 +129,7 @@ static void do_inject_external_nmi(void *data) uint32_t lvt; int ret; - cpu_synchronize_state(&s->cpu->env); + cpu_synchronize_state(cpu); lvt = s->lvt[APIC_LVT_LINT1]; if (!(lvt & APIC_LVT_MASKED) && ((lvt >> 8) & 7) == APIC_DM_NMI) { diff --git a/hw/i386/kvmvapic.c b/hw/i386/kvmvapic.c index 655483bd1d..f93629f9d4 100644 --- a/hw/i386/kvmvapic.c +++ b/hw/i386/kvmvapic.c @@ -456,7 +456,7 @@ void vapic_report_tpr_access(DeviceState *dev, CPUState *cs, target_ulong ip, X86CPU *cpu = X86_CPU(cs); CPUX86State *env = &cpu->env; - cpu_synchronize_state(env); + cpu_synchronize_state(cs); if (evaluate_tpr_instruction(s, env, &ip, access) < 0) { if (s->state == VAPIC_ACTIVE) { @@ -627,7 +627,7 @@ static void vapic_write(void *opaque, hwaddr addr, uint64_t data, hwaddr rom_paddr; VAPICROMState *s = opaque; - cpu_synchronize_state(env); + cpu_synchronize_state(CPU(x86_env_get_cpu(env))); /* * The VAPIC supports two PIO-based hypercalls, both via port 0x7E. diff --git a/hw/i386/multiboot.c b/hw/i386/multiboot.c index 09211e0534..985ca1ed84 100644 --- a/hw/i386/multiboot.c +++ b/hw/i386/multiboot.c @@ -315,8 +315,6 @@ int load_multiboot(FWCfgState *fw_cfg, | MULTIBOOT_FLAGS_CMDLINE | MULTIBOOT_FLAGS_MODULES | MULTIBOOT_FLAGS_MMAP); - stl_p(bootinfo + MBI_MEM_LOWER, 640); - stl_p(bootinfo + MBI_MEM_UPPER, (ram_size / 1024) - 1024); stl_p(bootinfo + MBI_BOOT_DEVICE, 0x8000ffff); /* XXX: use the -boot switch? */ stl_p(bootinfo + MBI_MMAP_ADDR, ADDR_E820_MAP); diff --git a/hw/i386/pc.c b/hw/i386/pc.c index 5e8f143bc2..78f92e29a7 100644 --- a/hw/i386/pc.c +++ b/hw/i386/pc.c @@ -1109,7 +1109,7 @@ static void cpu_request_exit(void *opaque, int irq, int level) CPUX86State *env = cpu_single_env; if (env && level) { - cpu_exit(env); + cpu_exit(CPU(x86_env_get_cpu(env))); } } diff --git a/hw/mips/mips_fulong2e.c b/hw/mips/mips_fulong2e.c index 1aac93a414..00c9071af1 100644 --- a/hw/mips/mips_fulong2e.c +++ b/hw/mips/mips_fulong2e.c @@ -253,7 +253,7 @@ static void cpu_request_exit(void *opaque, int irq, int level) CPUMIPSState *env = cpu_single_env; if (env && level) { - cpu_exit(env); + cpu_exit(CPU(mips_env_get_cpu(env))); } } diff --git a/hw/mips/mips_jazz.c b/hw/mips/mips_jazz.c index 94d95702a4..2ad0c0b414 100644 --- a/hw/mips/mips_jazz.c +++ b/hw/mips/mips_jazz.c @@ -102,7 +102,7 @@ static void cpu_request_exit(void *opaque, int irq, int level) CPUMIPSState *env = cpu_single_env; if (env && level) { - cpu_exit(env); + cpu_exit(CPU(mips_env_get_cpu(env))); } } diff --git a/hw/mips/mips_malta.c b/hw/mips/mips_malta.c index 5033d51224..8a4459d0b2 100644 --- a/hw/mips/mips_malta.c +++ b/hw/mips/mips_malta.c @@ -773,7 +773,7 @@ static void cpu_request_exit(void *opaque, int irq, int level) CPUMIPSState *env = cpu_single_env; if (env && level) { - cpu_exit(env); + cpu_exit(CPU(mips_env_get_cpu(env))); } } diff --git a/hw/misc/vmport.c b/hw/misc/vmport.c index 57b71f5248..8363dfdf92 100644 --- a/hw/misc/vmport.c +++ b/hw/misc/vmport.c @@ -66,7 +66,7 @@ static uint64_t vmport_ioport_read(void *opaque, hwaddr addr, unsigned char command; uint32_t eax; - cpu_synchronize_state(env); + cpu_synchronize_state(CPU(x86_env_get_cpu(env))); eax = env->regs[R_EAX]; if (eax != VMPORT_MAGIC) diff --git a/hw/ppc/ppce500_spin.c b/hw/ppc/ppce500_spin.c index 1290d37bb9..ea6541413f 100644 --- a/hw/ppc/ppce500_spin.c +++ b/hw/ppc/ppce500_spin.c @@ -98,7 +98,7 @@ static void spin_kick(void *data) hwaddr map_size = 64 * 1024 * 1024; hwaddr map_start; - cpu_synchronize_state(env); + cpu_synchronize_state(cpu); stl_p(&curspin->pir, env->spr[SPR_PIR]); env->nip = ldq_p(&curspin->addr) & (map_size - 1); env->gpr[3] = ldq_p(&curspin->r3); diff --git a/hw/ppc/prep.c b/hw/ppc/prep.c index 4fdc1649fd..90828f2635 100644 --- a/hw/ppc/prep.c +++ b/hw/ppc/prep.c @@ -420,7 +420,7 @@ static void cpu_request_exit(void *opaque, int irq, int level) CPUPPCState *env = cpu_single_env; if (env && level) { - cpu_exit(env); + cpu_exit(CPU(ppc_env_get_cpu(env))); } } diff --git a/hw/ppc/spapr_rtas.c b/hw/ppc/spapr_rtas.c index f4bd3c9d86..42ed7dc093 100644 --- a/hw/ppc/spapr_rtas.c +++ b/hw/ppc/spapr_rtas.c @@ -184,7 +184,7 @@ static void rtas_start_cpu(sPAPREnvironment *spapr, /* This will make sure qemu state is up to date with kvm, and * mark it dirty so our changes get flushed back before the * new cpu enters */ - kvm_cpu_synchronize_state(env); + kvm_cpu_synchronize_state(cs); env->msr = (1ULL << MSR_SF) | (1ULL << MSR_ME); env->nip = start; |