From 3c9827591184f857037b6a83d13b7779f76b1bd4 Mon Sep 17 00:00:00 2001 From: Xiao Guangrong Date: Tue, 21 Aug 2012 10:58:45 +0800 Subject: [PATCH] --- yaml --- r: 329863 b: refs/heads/master c: 67b29204c8c9ecb4b2799a06ab646eeb363a0fe6 h: refs/heads/master i: 329861: 3ca1fcf9fd0bf9ae014e643a025892e405f7ef06 329859: 789a33daaf7ababf178070b83baf3dac7db7c441 329855: abc11424604d8fa5ad88b1f092a938077e35435d v: v3 --- [refs] | 2 +- trunk/include/linux/kvm.h | 7 +++++-- trunk/include/linux/kvm_host.h | 7 +++++++ 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/[refs] b/[refs] index b45448ff9f3e..31ca0fb094c2 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: a50d64d6590f470b712758598a077ef4fd0fc40a +refs/heads/master: 67b29204c8c9ecb4b2799a06ab646eeb363a0fe6 diff --git a/trunk/include/linux/kvm.h b/trunk/include/linux/kvm.h index 2ce09aa7d3b3..2de335d7f63e 100644 --- a/trunk/include/linux/kvm.h +++ b/trunk/include/linux/kvm.h @@ -101,9 +101,12 @@ struct kvm_userspace_memory_region { __u64 userspace_addr; /* start of the userspace allocated memory */ }; -/* for kvm_memory_region::flags */ +/* + * The bit 0 ~ bit 15 of kvm_memory_region::flags are visible for userspace, + * other bits are reserved for kvm internal use which are defined in + * include/linux/kvm_host.h. + */ #define KVM_MEM_LOG_DIRTY_PAGES 1UL -#define KVM_MEMSLOT_INVALID (1UL << 1) /* for KVM_IRQ_LINE */ struct kvm_irq_level { diff --git a/trunk/include/linux/kvm_host.h b/trunk/include/linux/kvm_host.h index d2b897ee3ac4..d4bd4d41e355 100644 --- a/trunk/include/linux/kvm_host.h +++ b/trunk/include/linux/kvm_host.h @@ -35,6 +35,13 @@ #define KVM_MMIO_SIZE 8 #endif +/* + * The bit 16 ~ bit 31 of kvm_memory_region::flags are internally used + * in kvm, other bits are visible for userspace which are defined in + * include/linux/kvm_h. + */ +#define KVM_MEMSLOT_INVALID (1UL << 16) + /* * If we support unaligned MMIO, at most one fragment will be split into two: */