Re: [PATCH uq/master] Synchronize cpu state with kernel before poking into registers.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2012-02-16 10:12, Gleb Natapov wrote:
> Call to kvm_cpu_synchronize_state() is missing. kvm_arch_stop_on_emulation_error may
> look at outdated registers here.
> 
> Signed-off-by: Gleb Natapov <gleb@xxxxxxxxxx>
> diff --git a/target-i386/kvm.c b/target-i386/kvm.c
> index 7079e87..51d0ae7 100644
> --- a/target-i386/kvm.c
> +++ b/target-i386/kvm.c
> @@ -2020,6 +2020,7 @@ int kvm_arch_handle_exit(CPUState *env, struct kvm_run *run)
>  
>  bool kvm_arch_stop_on_emulation_error(CPUState *env)
>  {
> +    kvm_cpu_synchronize_state(env);
>      return !(env->cr[0] & CR0_PE_MASK) ||
>             ((env->segs[R_CS].selector  & 3) != 3);
>  }

Reviewed-by: Jan Kiszka <jan.kiszka@xxxxxxxxxxx>

-- 
Siemens AG, Corporate Technology, CT T DE IT 1
Corporate Competence Center Embedded Linux
--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux