Skip to contentSkip to conversation

migration: Fix typos in bitmap migration comments

PATCH In review Eric Blake 2 participants 2 messages Jul 27, 2020

lore
Share & tools
lore

Eric Blake

author
#0 lore raw

PATCH 1/1 migration: Fix typos in bitmap migration comments

Noticed while reviewing the file for newer patches.

Fixes b35ebdf076

---

This is trivial enough that I'll throw it in my pull request today.

 migration/block-dirty-bitmap.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
migration/block-dirty-bitmap.c +2 -2
index 1f675b792fc9..784330ebe130 100644
@@ -97,7 +97,7 @@
 
 #define DIRTY_BITMAP_MIG_START_FLAG_ENABLED          0x01
 #define DIRTY_BITMAP_MIG_START_FLAG_PERSISTENT       0x02
-/* 0x04 was "AUTOLOAD" flags on elder versions, no it is ignored */
+/* 0x04 was "AUTOLOAD" flags on older versions, now it is ignored */
 #define DIRTY_BITMAP_MIG_START_FLAG_RESERVED_MASK    0xf8
 
 /* State of one bitmap during save process */
@@ -180,7 +180,7 @@ static uint32_t qemu_get_bitmap_flags(QEMUFile *f)
 
 static void qemu_put_bitmap_flags(QEMUFile *f, uint32_t flags)
 {
-    /* The code currently do not send flags more than one byte */
+    /* The code currently does not send flags as more than one byte */
     assert(!(flags & (0xffffff00 | DIRTY_BITMAP_MIG_EXTRA_FLAGS)));
 
     qemu_put_byte(f, flags);
Signature · 1 line
2.27.0
Reviewed-by on v1 1/1
#1 lore raw
Quoted 16 lines · Eric Blake

Noticed while reviewing the file for newer patches.

Fixes b35ebdf076

---

This is trivial enough that I'll throw it in my pull request today.

  migration/block-dirty-bitmap.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
migration/block-dirty-bitmap.c +0 -0
index 1f675b792fc9..784330ebe130 100644

migration/block-dirty-bitmap.c line 100

Quoted 5 lines
migration/block-dirty-bitmap.c +1 -1
@@ -97,7 +97,7 @@
 
  #define DIRTY_BITMAP_MIG_START_FLAG_ENABLED          0x01
  #define DIRTY_BITMAP_MIG_START_FLAG_PERSISTENT       0x02
-/* 0x04 was "AUTOLOAD" flags on elder versions, no it is ignored */
+/* 0x04 was "AUTOLOAD" flags on older versions, now it is ignored */

may be also s/flags/flag

migration/block-dirty-bitmap.c static uint32_t qemu_get_bitmap_flags(QEMUFile *f) · line 183

Quoted 9 lines
migration/block-dirty-bitmap.c +1 -1
  #define DIRTY_BITMAP_MIG_START_FLAG_RESERVED_MASK    0xf8
 
  /* State of one bitmap during save process */
@@ -180,7 +180,7 @@ static uint32_t qemu_get_bitmap_flags(QEMUFile *f)
 
  static void qemu_put_bitmap_flags(QEMUFile *f, uint32_t flags)
  {
-    /* The code currently do not send flags more than one byte */
+    /* The code currently does not send flags as more than one byte */

Hmm, why "as more than", not just "more than"?.
(this note is about the following: the protocol allows adding more than one byte of flags with use of DIRTY_BITMAP_MIG_EXTRA_FLAGS. Still, currently this possibility is not used and we assert it.)

migration/block-dirty-bitmap.c static uint32_t qemu_get_bitmap_flags(QEMUFile *f) · line 186

Quoted 4 lines
migration/block-dirty-bitmap.c +0 -0
      assert(!(flags & (0xffffff00 | DIRTY_BITMAP_MIG_EXTRA_FLAGS)));
 
      qemu_put_byte(f, flags);

Anyway:

Signature · 2 lines
Best regards,
Vladimir