mirror of
https://github.com/xemu-project/xemu.git
synced 2024-11-23 19:49:43 +00:00
migration/ram: Don't passs RAMState to migration_clear_memory_region_dirty_bitmap_*()
The parameter is unused, let's drop it. Reviewed-by: Peter Xu <peterx@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Reviewed-by: Juan Quintela <quintela@redhat.com> Signed-off-by: David Hildenbrand <david@redhat.com> Signed-off-by: Juan Quintela <quintela@redhat.com>
This commit is contained in:
parent
e9ab82b858
commit
1230a25f6f
@ -789,8 +789,7 @@ unsigned long migration_bitmap_find_dirty(RAMState *rs, RAMBlock *rb,
|
||||
return find_next_bit(bitmap, size, start);
|
||||
}
|
||||
|
||||
static void migration_clear_memory_region_dirty_bitmap(RAMState *rs,
|
||||
RAMBlock *rb,
|
||||
static void migration_clear_memory_region_dirty_bitmap(RAMBlock *rb,
|
||||
unsigned long page)
|
||||
{
|
||||
uint8_t shift;
|
||||
@ -818,8 +817,7 @@ static void migration_clear_memory_region_dirty_bitmap(RAMState *rs,
|
||||
}
|
||||
|
||||
static void
|
||||
migration_clear_memory_region_dirty_bitmap_range(RAMState *rs,
|
||||
RAMBlock *rb,
|
||||
migration_clear_memory_region_dirty_bitmap_range(RAMBlock *rb,
|
||||
unsigned long start,
|
||||
unsigned long npages)
|
||||
{
|
||||
@ -832,7 +830,7 @@ migration_clear_memory_region_dirty_bitmap_range(RAMState *rs,
|
||||
* exclusive.
|
||||
*/
|
||||
for (i = chunk_start; i < chunk_end; i += chunk_pages) {
|
||||
migration_clear_memory_region_dirty_bitmap(rs, rb, i);
|
||||
migration_clear_memory_region_dirty_bitmap(rb, i);
|
||||
}
|
||||
}
|
||||
|
||||
@ -850,7 +848,7 @@ static inline bool migration_bitmap_clear_dirty(RAMState *rs,
|
||||
* the page in the chunk we clear the remote dirty bitmap for all.
|
||||
* Clearing it earlier won't be a problem, but too late will.
|
||||
*/
|
||||
migration_clear_memory_region_dirty_bitmap(rs, rb, page);
|
||||
migration_clear_memory_region_dirty_bitmap(rb, page);
|
||||
|
||||
ret = test_and_clear_bit(page, rb->bmap);
|
||||
if (ret) {
|
||||
@ -2777,8 +2775,7 @@ void qemu_guest_free_page_hint(void *addr, size_t len)
|
||||
* are initially set. Otherwise those skipped pages will be sent in
|
||||
* the next round after syncing from the memory region bitmap.
|
||||
*/
|
||||
migration_clear_memory_region_dirty_bitmap_range(ram_state, block,
|
||||
start, npages);
|
||||
migration_clear_memory_region_dirty_bitmap_range(block, start, npages);
|
||||
ram_state->migration_dirty_pages -=
|
||||
bitmap_count_one_with_offset(block->bmap, start, npages);
|
||||
bitmap_clear(block->bmap, start, npages);
|
||||
|
Loading…
Reference in New Issue
Block a user