aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/kvm_host.h
diff options
context:
space:
mode:
authorAlex Williamson <alex.williamson@redhat.com>2012-12-10 12:33:21 -0500
committerMarcelo Tosatti <mtosatti@redhat.com>2012-12-13 20:24:38 -0500
commitf82a8cfe9354f5cdea55ebeceba3fd19051d3ee8 (patch)
tree335e968cef697b7831c48849677de628cee4e73d /include/linux/kvm_host.h
parent0743247fbf0c4a27185b2aa1fdda91d0745dfed1 (diff)
KVM: struct kvm_memory_slot.user_alloc -> bool
There's no need for this to be an int, it holds a boolean. Move to the end of the struct for alignment. Reviewed-by: Gleb Natapov <gleb@redhat.com> Signed-off-by: Alex Williamson <alex.williamson@redhat.com> Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'include/linux/kvm_host.h')
-rw-r--r--include/linux/kvm_host.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/include/linux/kvm_host.h b/include/linux/kvm_host.h
index 5a3581ceb036..d897f035749f 100644
--- a/include/linux/kvm_host.h
+++ b/include/linux/kvm_host.h
@@ -270,8 +270,8 @@ struct kvm_memory_slot {
270 unsigned long *dirty_bitmap; 270 unsigned long *dirty_bitmap;
271 struct kvm_arch_memory_slot arch; 271 struct kvm_arch_memory_slot arch;
272 unsigned long userspace_addr; 272 unsigned long userspace_addr;
273 int user_alloc;
274 int id; 273 int id;
274 bool user_alloc;
275}; 275};
276 276
277static inline unsigned long kvm_dirty_bitmap_bytes(struct kvm_memory_slot *memslot) 277static inline unsigned long kvm_dirty_bitmap_bytes(struct kvm_memory_slot *memslot)
@@ -451,10 +451,10 @@ id_to_memslot(struct kvm_memslots *slots, int id)
451 451
452int kvm_set_memory_region(struct kvm *kvm, 452int kvm_set_memory_region(struct kvm *kvm,
453 struct kvm_userspace_memory_region *mem, 453 struct kvm_userspace_memory_region *mem,
454 int user_alloc); 454 bool user_alloc);
455int __kvm_set_memory_region(struct kvm *kvm, 455int __kvm_set_memory_region(struct kvm *kvm,
456 struct kvm_userspace_memory_region *mem, 456 struct kvm_userspace_memory_region *mem,
457 int user_alloc); 457 bool user_alloc);
458void kvm_arch_free_memslot(struct kvm_memory_slot *free, 458void kvm_arch_free_memslot(struct kvm_memory_slot *free,
459 struct kvm_memory_slot *dont); 459 struct kvm_memory_slot *dont);
460int kvm_arch_create_memslot(struct kvm_memory_slot *slot, unsigned long npages); 460int kvm_arch_create_memslot(struct kvm_memory_slot *slot, unsigned long npages);
@@ -462,11 +462,11 @@ int kvm_arch_prepare_memory_region(struct kvm *kvm,
462 struct kvm_memory_slot *memslot, 462 struct kvm_memory_slot *memslot,
463 struct kvm_memory_slot old, 463 struct kvm_memory_slot old,
464 struct kvm_userspace_memory_region *mem, 464 struct kvm_userspace_memory_region *mem,
465 int user_alloc); 465 bool user_alloc);
466void kvm_arch_commit_memory_region(struct kvm *kvm, 466void kvm_arch_commit_memory_region(struct kvm *kvm,
467 struct kvm_userspace_memory_region *mem, 467 struct kvm_userspace_memory_region *mem,
468 struct kvm_memory_slot old, 468 struct kvm_memory_slot old,
469 int user_alloc); 469 bool user_alloc);
470bool kvm_largepages_enabled(void); 470bool kvm_largepages_enabled(void);
471void kvm_disable_largepages(void); 471void kvm_disable_largepages(void);
472/* flush all memory translations */ 472/* flush all memory translations */
@@ -553,7 +553,7 @@ int kvm_vm_ioctl_get_dirty_log(struct kvm *kvm,
553int kvm_vm_ioctl_set_memory_region(struct kvm *kvm, 553int kvm_vm_ioctl_set_memory_region(struct kvm *kvm,
554 struct 554 struct
555 kvm_userspace_memory_region *mem, 555 kvm_userspace_memory_region *mem,
556 int user_alloc); 556 bool user_alloc);
557int kvm_vm_ioctl_irq_line(struct kvm *kvm, struct kvm_irq_level *irq_level); 557int kvm_vm_ioctl_irq_line(struct kvm *kvm, struct kvm_irq_level *irq_level);
558long kvm_arch_vm_ioctl(struct file *filp, 558long kvm_arch_vm_ioctl(struct file *filp,
559 unsigned int ioctl, unsigned long arg); 559 unsigned int ioctl, unsigned long arg);