summaryrefslogtreecommitdiffstats
path: root/hw
diff options
context:
space:
mode:
Diffstat (limited to 'hw')
-rw-r--r--hw/s390x/ipl.c2
-rw-r--r--hw/s390x/s390-virtio.c32
-rw-r--r--hw/s390x/virtio-ccw.c2
3 files changed, 2 insertions, 34 deletions
diff --git a/hw/s390x/ipl.c b/hw/s390x/ipl.c
index 4fa9cffded..3b77c9a227 100644
--- a/hw/s390x/ipl.c
+++ b/hw/s390x/ipl.c
@@ -176,7 +176,7 @@ static void s390_ipl_reset(DeviceState *dev)
}
}
- s390_add_running_cpu(cpu);
+ s390_cpu_set_state(CPU_STATE_OPERATING, cpu);
}
static void s390_ipl_class_init(ObjectClass *klass, void *data)
diff --git a/hw/s390x/s390-virtio.c b/hw/s390x/s390-virtio.c
index 9c61246375..af0004a0ac 100644
--- a/hw/s390x/s390-virtio.c
+++ b/hw/s390x/s390-virtio.c
@@ -125,38 +125,6 @@ static void s390_virtio_register_hcalls(void)
s390_virtio_hcall_set_status);
}
-/*
- * The number of running CPUs. On s390 a shutdown is the state of all CPUs
- * being either stopped or disabled (for interrupts) waiting. We have to
- * track this number to call the shutdown sequence accordingly. This
- * number is modified either on startup or while holding the big qemu lock.
- */
-static unsigned s390_running_cpus;
-
-void s390_add_running_cpu(S390CPU *cpu)
-{
- CPUState *cs = CPU(cpu);
-
- if (cs->halted) {
- s390_running_cpus++;
- cs->halted = 0;
- cs->exception_index = -1;
- }
-}
-
-unsigned s390_del_running_cpu(S390CPU *cpu)
-{
- CPUState *cs = CPU(cpu);
-
- if (cs->halted == 0) {
- assert(s390_running_cpus >= 1);
- s390_running_cpus--;
- cs->halted = 1;
- cs->exception_index = EXCP_HLT;
- }
- return s390_running_cpus;
-}
-
void s390_init_ipl_dev(const char *kernel_filename,
const char *kernel_cmdline,
const char *initrd_filename,
diff --git a/hw/s390x/virtio-ccw.c b/hw/s390x/virtio-ccw.c
index e7d3ea178a..18ba29fa14 100644
--- a/hw/s390x/virtio-ccw.c
+++ b/hw/s390x/virtio-ccw.c
@@ -1528,7 +1528,7 @@ static void vhost_ccw_scsi_class_init(ObjectClass *klass, void *data)
static const TypeInfo vhost_ccw_scsi = {
.name = TYPE_VHOST_SCSI_CCW,
.parent = TYPE_VIRTIO_CCW_DEVICE,
- .instance_size = sizeof(VirtIOSCSICcw),
+ .instance_size = sizeof(VHostSCSICcw),
.instance_init = vhost_ccw_scsi_instance_init,
.class_init = vhost_ccw_scsi_class_init,
};