[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH 3/6] kvm: create kvmclock when one of the flags are
From: |
Marcelo Tosatti |
Subject: |
[Qemu-devel] [PATCH 3/6] kvm: create kvmclock when one of the flags are present |
Date: |
Sat, 16 Apr 2011 19:10:05 -0300 |
From: Glauber Costa <address@hidden>
kvmclock presence can be signalled by two different flags. So for
device creation, we have to test for both.
Signed-off-by: Glauber Costa <address@hidden>
Signed-off-by: Avi Kivity <address@hidden>
---
hw/kvmclock.c | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
diff --git a/hw/kvmclock.c b/hw/kvmclock.c
index b6ceddf..004c4ad 100644
--- a/hw/kvmclock.c
+++ b/hw/kvmclock.c
@@ -103,7 +103,11 @@ static SysBusDeviceInfo kvmclock_info = {
void kvmclock_create(void)
{
if (kvm_enabled() &&
- first_cpu->cpuid_kvm_features & (1ULL << KVM_FEATURE_CLOCKSOURCE)) {
+ first_cpu->cpuid_kvm_features & ((1ULL << KVM_FEATURE_CLOCKSOURCE)
+#ifdef KVM_FEATURE_CLOCKSOURCE2
+ || (1ULL << KVM_FEATURE_CLOCKSOURCE2)
+#endif
+ )) {
sysbus_create_simple("kvmclock", -1, NULL);
}
}
--
1.7.4.2
- [Qemu-devel] [PATCH 0/6] [PULL] qemu-kvm.git uq/master queue, Marcelo Tosatti, 2011/04/16
- [Qemu-devel] [PATCH 5/6] Redirect cpu_interrupt to callback handler, Marcelo Tosatti, 2011/04/16
- [Qemu-devel] [PATCH 1/6] kvm: use kernel-provided para_features instead of statically coming up with new capabilities, Marcelo Tosatti, 2011/04/16
- [Qemu-devel] [PATCH 3/6] kvm: create kvmclock when one of the flags are present,
Marcelo Tosatti <=
- [Qemu-devel] [PATCH 4/6] Break up user and system cpu_interrupt implementations, Marcelo Tosatti, 2011/04/16
- Re: [Qemu-devel] [PATCH 0/6] [PULL] qemu-kvm.git uq/master queue, Anthony Liguori, 2011/04/16