[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] Implement cpu_physical_memory_reset_dirty()
# HG changeset patch # User adsharma@xxxxxxxxxxxxxxxxxxxx # Node ID 9c011dd3f6b7f38ba03de644018d366aa750cf4b # Parent 20bbe519f743223a8ce2ae4ce17def7ac4f1f32e Implement cpu_physical_memory_reset_dirty() Signed-off-by: Don Dugger <donald.d.dugger@xxxxxxxxx> Signed-off-by: Arun Sharma <arun.sharma@xxxxxxxxx> diff -r 20bbe519f743 -r 9c011dd3f6b7 tools/ioemu/cpu-all.h --- a/tools/ioemu/cpu-all.h Mon Aug 22 18:04:15 2005 +++ b/tools/ioemu/cpu-all.h Mon Aug 22 18:31:19 2005 @@ -672,6 +672,8 @@ int cpu_memory_rw_debug(CPUState *env, target_ulong addr, uint8_t *buf, int len, int is_write); +#define VGA_DIRTY_FLAG 0x01 + /* read dirty bit (return 0 or 1) */ static inline int cpu_physical_memory_is_dirty(target_ulong addr) { diff -r 20bbe519f743 -r 9c011dd3f6b7 tools/ioemu/exec.c --- a/tools/ioemu/exec.c Mon Aug 22 18:04:15 2005 +++ b/tools/ioemu/exec.c Mon Aug 22 18:31:19 2005 @@ -461,4 +461,14 @@ void cpu_physical_memory_reset_dirty(target_ulong start, target_ulong end) { -} + uint8_t *p; + int len; + + if ((len = (end - start)) <= 0) + return; + p = phys_ram_dirty + (start >> TARGET_PAGE_BITS); + len = len >> TARGET_PAGE_BITS; + while (len > 0) + p[--len] &= ~VGA_DIRTY_FLAG; + return; +} diff -r 20bbe519f743 -r 9c011dd3f6b7 tools/ioemu/hw/vga.c --- a/tools/ioemu/hw/vga.c Mon Aug 22 18:04:15 2005 +++ b/tools/ioemu/hw/vga.c Mon Aug 22 18:31:19 2005 @@ -1620,7 +1620,6 @@ static void vga_save(QEMUFile *f, void *opaque) { VGAState *s = opaque; - int i; qemu_put_be32s(f, &s->latch); qemu_put_8s(f, &s->sr_index); @@ -1661,7 +1660,7 @@ static int vga_load(QEMUFile *f, void *opaque, int version_id) { VGAState *s = opaque; - int is_vbe, i; + int is_vbe; if (version_id != 1) return -EINVAL; _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |