From: Avi Kivity <[EMAIL PROTECTED]>

As guest memory can be discontiguous, kvm->physical_memory is meaningless.
Luckily it is no longer used, so we can remove it.

Signed-off-by: Avi Kivity <[EMAIL PROTECTED]>

diff --git a/libkvm/kvm-common.h b/libkvm/kvm-common.h
index b8a88ee..a3549e2 100644
--- a/libkvm/kvm-common.h
+++ b/libkvm/kvm-common.h
@@ -39,8 +39,6 @@ struct kvm_context {
        /// Callbacks that KVM uses to emulate various unvirtualizable 
functionality
        struct kvm_callbacks *callbacks;
        void *opaque;
-       /// A pointer to the memory used as the physical memory for the guest
-       void *physical_memory;
        /// is dirty pages logging enabled for all regions or not
        int dirty_pages_log_all;
        /// do not create in-kernel irqchip if set
diff --git a/libkvm/libkvm.c b/libkvm/libkvm.c
index f4852b6..d1e95a4 100644
--- a/libkvm/libkvm.c
+++ b/libkvm/libkvm.c
@@ -341,7 +341,6 @@ static int kvm_create_default_phys_mem(kvm_context_t kvm,
        if (r < 0)
                return r;
 
-       kvm->physical_memory = *vm_mem;
        return 0;
 }
 
@@ -549,9 +548,6 @@ int kvm_register_userspace_phys_mem(kvm_context_t kvm,
        };
        int r;
 
-       if (!kvm->physical_memory)
-               kvm->physical_memory = userspace_addr - phys_start;
-
        memory.slot = get_free_slot(kvm);
        r = ioctl(kvm->vm_fd, KVM_SET_USER_MEMORY_REGION, &memory);
        if (r == -1) {

-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
kvm-commits mailing list
kvm-commits@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/kvm-commits

Reply via email to