From: Marcelo Tosatti Subject: [patch 3/6] remove unused kvm_get_dirty_pages Date: Mon, 03 May 2010 19:48:22 -0300 Message-ID: <20100503224905.512545018@amt.cnet> References: <20100503224819.773169076@amt.cnet> Cc: avi@redhat.com, jan.kiszka@web.de, Marcelo Tosatti To: kvm@vger.kernel.org Return-path: Received: from mx1.redhat.com ([209.132.183.28]:57541 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759582Ab0ECW5A (ORCPT ); Mon, 3 May 2010 18:57:00 -0400 Content-Disposition: inline; filename=unregister Sender: kvm-owner@vger.kernel.org List-ID: And make kvm_unregister_memory_area static. Signed-off-by: Marcelo Tosatti Index: qemu-kvm-memslot/qemu-kvm.c =================================================================== --- qemu-kvm-memslot.orig/qemu-kvm.c +++ qemu-kvm-memslot/qemu-kvm.c @@ -639,8 +639,8 @@ void kvm_destroy_phys_mem(kvm_context_t free_slot(memory.slot); } -void kvm_unregister_memory_area(kvm_context_t kvm, uint64_t phys_addr, - unsigned long size) +static void kvm_unregister_memory_area(kvm_context_t kvm, uint64_t phys_addr, + unsigned long size) { int slot = get_container_slot(phys_addr, size); @@ -667,14 +667,6 @@ static int kvm_get_map(kvm_context_t kvm return 0; } -int kvm_get_dirty_pages(kvm_context_t kvm, unsigned long phys_addr, void *buf) -{ - int slot; - - slot = get_slot(phys_addr); - return kvm_get_map(kvm, KVM_GET_DIRTY_LOG, slot, buf); -} - int kvm_get_dirty_pages_range(kvm_context_t kvm, unsigned long phys_addr, unsigned long len, void *opaque, int (*cb)(unsigned long start, Index: qemu-kvm-memslot/qemu-kvm.h =================================================================== --- qemu-kvm-memslot.orig/qemu-kvm.h +++ qemu-kvm-memslot/qemu-kvm.h @@ -381,14 +381,11 @@ void *kvm_create_phys_mem(kvm_context_t, unsigned long len, int log, int writable); void kvm_destroy_phys_mem(kvm_context_t, unsigned long phys_start, unsigned long len); -void kvm_unregister_memory_area(kvm_context_t, uint64_t phys_start, - unsigned long len); int kvm_is_containing_region(kvm_context_t kvm, unsigned long phys_start, unsigned long size); int kvm_register_phys_mem(kvm_context_t kvm, unsigned long phys_start, void *userspace_addr, unsigned long len, int log); -int kvm_get_dirty_pages(kvm_context_t, unsigned long phys_addr, void *buf); int kvm_get_dirty_pages_range(kvm_context_t kvm, unsigned long phys_addr, unsigned long end_addr, void *opaque, int (*cb)(unsigned long start,