KVM: introduce KVM_MEM_SLOTS_NUM macro
[platform/adaptation/renesas_rcar/renesas_kernel.git] / arch / x86 / include / asm / kvm_host.h
index 69b6525..1769f3d 100644 (file)
@@ -31,6 +31,8 @@
 #define KVM_MEMORY_SLOTS 32
 /* memory slots that does not exposed to userspace */
 #define KVM_PRIVATE_MEM_SLOTS 4
+#define KVM_MEM_SLOTS_NUM (KVM_MEMORY_SLOTS + KVM_PRIVATE_MEM_SLOTS)
+
 #define KVM_MMIO_SIZE 16
 
 #define KVM_PIO_PAGE_OFFSET 1
@@ -228,7 +230,7 @@ struct kvm_mmu_page {
         * One bit set per slot which has memory
         * in this shadow page.
         */
-       DECLARE_BITMAP(slot_bitmap, KVM_MEMORY_SLOTS + KVM_PRIVATE_MEM_SLOTS);
+       DECLARE_BITMAP(slot_bitmap, KVM_MEM_SLOTS_NUM);
        bool unsync;
        int root_count;          /* Currently serving as active root */
        unsigned int unsync_children;