Skip to content

Commit

Permalink
exec, memory: Call to xen_modified_memory.
Browse files Browse the repository at this point in the history
This patch add some calls to xen_modified_memory to notify Xen about dirtybits
during migration.

Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
Reviewed-by: Avi Kivity <avi@redhat.com>
  • Loading branch information
anthonyper-ctx authored and Stefano Stabellini committed Oct 3, 2012
1 parent 51d7a9e commit e226939
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions exec-obsolete.h
Expand Up @@ -24,6 +24,7 @@
#endif

#ifndef CONFIG_USER_ONLY
#include "hw/xen.h"

ram_addr_t qemu_ram_alloc_from_ptr(ram_addr_t size, void *host,
MemoryRegion *mr);
Expand Down Expand Up @@ -111,6 +112,7 @@ static inline void cpu_physical_memory_set_dirty_range(ram_addr_t start,
for (addr = start; addr < end; addr += TARGET_PAGE_SIZE) {
cpu_physical_memory_set_dirty_flags(addr, dirty_flags);
}
xen_modified_memory(addr, length);
}

static inline void cpu_physical_memory_mask_dirty_range(ram_addr_t start,
Expand Down
1 change: 1 addition & 0 deletions exec.c
Expand Up @@ -3427,6 +3427,7 @@ static void invalidate_and_set_dirty(target_phys_addr_t addr,
/* set dirty bit */
cpu_physical_memory_set_dirty_flags(addr, (0xff & ~CODE_DIRTY_FLAG));
}
xen_modified_memory(addr, length);
}

void cpu_physical_memory_rw(target_phys_addr_t addr, uint8_t *buf,
Expand Down

0 comments on commit e226939

Please sign in to comment.