Re: [PATCH 5/6] qemu-x86: Set tsc_khz in kvm when supported

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

 



On 2011-08-05 22:55, Marcelo Tosatti wrote:
> From: Joerg Roedel <joerg.roedel@xxxxxxx>
> 
> Make use of the KVM_TSC_CONTROL feature if available.
> 
> Signed-off-by: Joerg Roedel <joerg.roedel@xxxxxxx>
> Signed-off-by: Marcelo Tosatti <mtosatti@xxxxxxxxxx>
> ---
>  target-i386/kvm.c |   18 +++++++++++++++++-
>  1 files changed, 17 insertions(+), 1 deletions(-)
> 
> diff --git a/target-i386/kvm.c b/target-i386/kvm.c
> index 10fb2c4..923d2d5 100644
> --- a/target-i386/kvm.c
> +++ b/target-i386/kvm.c
> @@ -354,6 +354,7 @@ int kvm_arch_init_vcpu(CPUState *env)
>      uint32_t unused;
>      struct kvm_cpuid_entry2 *c;
>      uint32_t signature[3];
> +    int r;
>  
>      env->cpuid_features &= kvm_arch_get_supported_cpuid(s, 1, 0, R_EDX);
>  
> @@ -499,7 +500,22 @@ int kvm_arch_init_vcpu(CPUState *env)
>  
>      qemu_add_vm_change_state_handler(cpu_update_state, env);
>  
> -    return kvm_vcpu_ioctl(env, KVM_SET_CPUID2, &cpuid_data);
> +    r = kvm_vcpu_ioctl(env, KVM_SET_CPUID2, &cpuid_data);
> +    if (r)
> +	    return r;

Coding style...

Jan

Attachment: signature.asc
Description: OpenPGP digital signature


[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