Skip to content
  • Jan Kiszka's avatar
    kvm: Rework VCPU synchronization · 8d2ba1fb
    Jan Kiszka authored
    
    
    During startup and after reset we have to synchronize user space to the
    in-kernel KVM state. Namely, we need to transfer the VCPU registers when
    they change due to VCPU as well as APIC reset.
    
    This patch refactors the required hooks so that kvm_init_vcpu registers
    its own per-VCPU reset handler and adds a cpu_synchronize_state to the
    APIC reset. That way we no longer depend on the new reset order (and can
    drop this disliked interface again) and we can even drop a KVM hook in
    main().
    
    Signed-off-by: default avatarJan Kiszka <jan.kiszka@siemens.com>
    Signed-off-by: default avatarAnthony Liguori <aliguori@us.ibm.com>
    8d2ba1fb