qemu: memory notifiers]
v2 cover qemu: memory notifiers]
Avi, Marcelo, if there are no objections, maybe this series can be merged through the new shiny qemu-kvm upstream branch? Thanks!
----- Forwarded message from "Michael S. Tsirkin" <[email protected]> -----
Date: Mon, 4 Jan 2010 21:48:56 +0200
From: "Michael S. Tsirkin" <[email protected]>
To: Anthony Liguori <[email protected]>, [email protected],
[email protected], [email protected]
Subject: [PATCHv2 0/3] qemu: memory notifiers
User-Agent: Mutt/1.5.19 (2009-01-05)
This patch against qemu upstream adds notifiers hook which lets backends get notified on memory changes, and converts kvm to use it. It survived light testing. Avi, could you please take a look at this patch? Thanks!
--- cpu-common.h | 19 +++++++++++++++++ exec.c | 62 +++++++++++++++++++++++++++++++++++++++++++++++++++++++-- 2 files changed, 78 insertions(+), 3 deletions(-)
cpu-common.h +19 -0
@@ -8,6 +8,7 @@#endif #include "bswap.h" +#include "qemu-queue.h" /* address in the RAM (different from a physical address) */ typedef unsigned long ram_addr_t ;
@@ -61,6 +62,24 @@ void cpu_physical_memory_unmap(void *buffer, target_phys_addr_t len,void *cpu_register_map_client (void *opaque,void (*callback)(void *opaque));void cpu_unregister_map_client (void *cookie); +struct CPUPhysMemoryClient ; +typedef struct CPUPhysMemoryClient CPUPhysMemoryClient ; +struct CPUPhysMemoryClient { +void (*set_memory)(struct CPUPhysMemoryClient *client, +target_phys_addr_t start_addr, +ram_addr_t size, +ram_addr_t phys_offset); +int (*sync_dirty_bitmap)(struct CPUPhysMemoryClient *client, +target_phys_addr_t start_addr, +target_phys_addr_t end_addr); +int (*migration_log)(struct CPUPhysMemoryClient *client, +int enable); +QLIST_ENTRY (CPUPhysMemoryClient) list; +}; + +void cpu_register_phys_memory_client (CPUPhysMemoryClient *); +void cpu_unregister_phys_memory_client (CPUPhysMemoryClient *); +uint32_t ldub_phys (target_phys_addr_t addr);uint32_t lduw_phys (target_phys_addr_t addr);uint32_t ldl_phys (target_phys_addr_t addr);
exec.c +59 -3
90 lines not on this page · raw message
Signature · 16 lines
1.6.6.rc1.43.gf55cc Michael S. Tsirkin (3): qemu: memory notifiers kvm: move kvm_set_phys_mem around kvm: move kvm to use memory notifiers cpu-common.h | 19 ++++ exec.c | 108 +++++++++++++++++++-- kvm-all.c | 310 +++++++++++++++++++++++++++++++-------------------------- kvm.h | 8 -- 4 files changed, 287 insertions(+), 158 deletions(-) ----- End forwarded message -----
Quoted 3 lines · Michael S. Tsirkin
Avi, Marcelo, if there are no objections, maybe this series can be merged through the new shiny qemu-kvm upstream branch? Thanks!
FWIW, I've been waiting for at least a comment from Avi since that was requested in the original post.
Regards,
Anthony Liguori
Quoted 5 lines · Anthony Liguori
Quoted 2 lines · Michael S. Tsirkin
Avi, Marcelo, if there are no objections, maybe this series can be merged through the new shiny qemu-kvm upstream branch? Thanks!
FWIW, I've been waiting for at least a comment from Avi since that was requested in the original post.
Yeah, sorry, I'm behind due to my fpu patchset being subtly broken. Will flush the queue as I think I have things under control now.
Signature · 1 line
error compiling committee.c: too many arguments to function