* [Qemu-devel] [PATCH v2] migration: rename migration_bitmap_sync_range to ramblock_sync_dirty_bitmap
@ 2019-08-08 3:31 Wei Yang
2019-08-08 17:36 ` Dr. David Alan Gilbert
0 siblings, 1 reply; 2+ messages in thread
From: Wei Yang @ 2019-08-08 3:31 UTC (permalink / raw)
To: qemu-devel; +Cc: pbonzini, Wei Yang, dgilbert, quintela
Rename for better understanding of the code.
Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Wei Yang <richardw.yang@linux.intel.com>
---
v2:
* rebase on top of "just pass RAMBlock is enough"
---
migration/ram.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/migration/ram.c b/migration/ram.c
index eee68a7991..0d12fa8e92 100644
--- a/migration/ram.c
+++ b/migration/ram.c
@@ -1748,7 +1748,7 @@ static inline bool migration_bitmap_clear_dirty(RAMState *rs,
}
/* Called with RCU critical section */
-static void migration_bitmap_sync_range(RAMState *rs, RAMBlock *rb)
+static void ramblock_sync_dirty_bitmap(RAMState *rs, RAMBlock *rb)
{
rs->migration_dirty_pages +=
cpu_physical_memory_sync_dirty_bitmap(rb, 0, rb->used_length,
@@ -1840,7 +1840,7 @@ static void migration_bitmap_sync(RAMState *rs)
qemu_mutex_lock(&rs->bitmap_mutex);
rcu_read_lock();
RAMBLOCK_FOREACH_NOT_IGNORED(block) {
- migration_bitmap_sync_range(rs, block);
+ ramblock_sync_dirty_bitmap(rs, block);
}
ram_counters.remaining = ram_bytes_remaining();
rcu_read_unlock();
@@ -4261,7 +4261,7 @@ static void colo_flush_ram_cache(void)
memory_global_dirty_log_sync();
rcu_read_lock();
RAMBLOCK_FOREACH_NOT_IGNORED(block) {
- migration_bitmap_sync_range(ram_state, block);
+ ramblock_sync_dirty_bitmap(ram_state, block);
}
rcu_read_unlock();
--
2.17.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH v2] migration: rename migration_bitmap_sync_range to ramblock_sync_dirty_bitmap
2019-08-08 3:31 [Qemu-devel] [PATCH v2] migration: rename migration_bitmap_sync_range to ramblock_sync_dirty_bitmap Wei Yang
@ 2019-08-08 17:36 ` Dr. David Alan Gilbert
0 siblings, 0 replies; 2+ messages in thread
From: Dr. David Alan Gilbert @ 2019-08-08 17:36 UTC (permalink / raw)
To: Wei Yang; +Cc: pbonzini, qemu-devel, quintela
* Wei Yang (richardw.yang@linux.intel.com) wrote:
> Rename for better understanding of the code.
>
> Suggested-by: Paolo Bonzini <pbonzini@redhat.com>
> Signed-off-by: Wei Yang <richardw.yang@linux.intel.com>
Reviewed-by: Dr. David Alan Gilbert <dgilbert@redhat.com>
and queued.
>
> ---
> v2:
> * rebase on top of "just pass RAMBlock is enough"
>
> ---
> migration/ram.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/migration/ram.c b/migration/ram.c
> index eee68a7991..0d12fa8e92 100644
> --- a/migration/ram.c
> +++ b/migration/ram.c
> @@ -1748,7 +1748,7 @@ static inline bool migration_bitmap_clear_dirty(RAMState *rs,
> }
>
> /* Called with RCU critical section */
> -static void migration_bitmap_sync_range(RAMState *rs, RAMBlock *rb)
> +static void ramblock_sync_dirty_bitmap(RAMState *rs, RAMBlock *rb)
> {
> rs->migration_dirty_pages +=
> cpu_physical_memory_sync_dirty_bitmap(rb, 0, rb->used_length,
> @@ -1840,7 +1840,7 @@ static void migration_bitmap_sync(RAMState *rs)
> qemu_mutex_lock(&rs->bitmap_mutex);
> rcu_read_lock();
> RAMBLOCK_FOREACH_NOT_IGNORED(block) {
> - migration_bitmap_sync_range(rs, block);
> + ramblock_sync_dirty_bitmap(rs, block);
> }
> ram_counters.remaining = ram_bytes_remaining();
> rcu_read_unlock();
> @@ -4261,7 +4261,7 @@ static void colo_flush_ram_cache(void)
> memory_global_dirty_log_sync();
> rcu_read_lock();
> RAMBLOCK_FOREACH_NOT_IGNORED(block) {
> - migration_bitmap_sync_range(ram_state, block);
> + ramblock_sync_dirty_bitmap(ram_state, block);
> }
> rcu_read_unlock();
>
> --
> 2.17.1
>
--
Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-08-08 17:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-08-08 3:31 [Qemu-devel] [PATCH v2] migration: rename migration_bitmap_sync_range to ramblock_sync_dirty_bitmap Wei Yang
2019-08-08 17:36 ` Dr. David Alan Gilbert
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.