From fd4aa979033ca604ad829cf95055d4b5c5ed1063 Mon Sep 17 00:00:00 2001 From: Blue Swirl Date: Sun, 16 Oct 2011 16:04:59 +0000 Subject: memory: change dirty setting APIs to take a size Instead of each target knowing or guessing the guest page size, just pass the desired size of dirtied memory area. Signed-off-by: Blue Swirl --- kvm-all.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'kvm-all.c') diff --git a/kvm-all.c b/kvm-all.c index e411d3cde6..7d4e544c52 100644 --- a/kvm-all.c +++ b/kvm-all.c @@ -368,7 +368,7 @@ static int kvm_get_dirty_pages_log_range(MemoryRegionSection *section, page_number = i * HOST_LONG_BITS + j; addr1 = page_number * TARGET_PAGE_SIZE; addr = section->offset_within_region + addr1; - memory_region_set_dirty(section->mr, addr); + memory_region_set_dirty(section->mr, addr, TARGET_PAGE_SIZE); } while (c != 0); } } @@ -379,8 +379,9 @@ static int kvm_get_dirty_pages_log_range(MemoryRegionSection *section, /** * kvm_physical_sync_dirty_bitmap - Grab dirty bitmap from kernel space - * This function updates qemu's dirty bitmap using cpu_physical_memory_set_dirty(). - * This means all bits are set to dirty. + * This function updates qemu's dirty bitmap using + * memory_region_set_dirty(). This means all bits are set + * to dirty. * * @start_add: start of logged region. * @end_addr: end of logged region. -- cgit v1.2.1