@@ -10,18 +10,18 @@ struct kvm;
struct kvm_cpu {
pthread_t thread;
- unsigned long cpu_id;
- unsigned long cpu_type;
- const char *cpu_compatible;
+ unsigned long cpu_id;
+ struct kvm_vcpu_init init;
+ const char *cpu_compatible;
- struct kvm *kvm;
- int vcpu_fd;
- struct kvm_run *kvm_run;
+ struct kvm *kvm;
+ int vcpu_fd;
+ struct kvm_run *kvm_run;
struct kvm_cpu_task *task;
- u8 is_running;
- u8 paused;
- u8 needs_nmi;
+ u8 is_running;
+ u8 paused;
+ u8 needs_nmi;
struct kvm_coalesced_mmio_ring *ring;
@@ -128,7 +128,7 @@ struct kvm_cpu *kvm_cpu__arch_init(struct kvm *kvm, unsigned long cpu_id)
/* Populate the vcpu structure. */
vcpu->kvm = kvm;
vcpu->cpu_id = cpu_id;
- vcpu->cpu_type = vcpu_init.target;
+ vcpu->init = vcpu_init;
vcpu->cpu_compatible = target->compatible;
vcpu->is_running = true;
A subsequent change to kvmtool will require that a vCPU be reset more than once. Derive a valid target/feature set exactly once and stash that for later use. Signed-off-by: Oliver Upton <oupton@google.com> --- arm/include/arm-common/kvm-cpu-arch.h | 18 +++++++++--------- arm/kvm-cpu.c | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-)