• Jan Kiszka's avatar
    x86/ipipe: kvm: Harden kvm_set_shared_msr in vmx_set_msr · ba6f5a46
    Jan Kiszka authored
    vmx_set_msr may be called without a ipipe notifier registered, i.e.
    outside of vcpu_run. In that case, shared MSRs may be set to guest state
    while I-pipe will have no chance to restore them when interrupting
    afterwards. Register the notifier and move the whole thing under hard
    irq protection.
    
    This fixes crashes when calling "info registers" from the QEMU console a
    number times.
    Signed-off-by: Jan Kiszka's avatarJan Kiszka <jan.kiszka@siemens.com>
    ba6f5a46
vmx.c 313 KB