Skip to contentSkip to conversation

make migration work again

PATCH In review Glauber Costa 2 participants 3 messages May 8, 2009 – May 11, 2009 KVM

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 make migration work again

Due to a small messup in version checking, migration was not working. fix it.

---
 migration-tcp.c       |    1 +
 savevm.c              |    1 +
 target-i386/helper.c  |    1 +
 target-i386/machine.c |    8 ++++----
 4 files changed, 7 insertions(+), 4 deletions(-)
target-i386/machine.c +4 -4
index 7f75d31..c1e05c5 100644
@@ -194,11 +194,11 @@ int cpu_load(QEMUFile *f, void *opaque, int version_id)
     int32_t a20_mask;
 
     if (version_id != 3 && version_id != 4 && version_id != 5
-        && version_id != 6 && version_id != 7 && version_id != 8)
-        return -EINVAL;
-    /* KVM cannot accept migrations from QEMU today */
-    if (version_id != 9)
+        && version_id != 6 && version_id != 7 && version_id != 8
+        /* KVM cannot accept migrations from QEMU today */
+        && version_id != 9)
         return -EINVAL;
+
     for(i = 0; i < CPU_NB_REGS; i++)
         qemu_get_betls(f, &env->regs[i]);
     qemu_get_betls(f, &env->eip);
Signature · 1 line
1.6.2.2
#1 lore raw
Quoted 12 lines · Glauber Costa

Due to a small messup in version checking, migration was not working. fix it.

---
 migration-tcp.c       |    1 +
 savevm.c              |    1 +
 target-i386/helper.c  |    1 +
 target-i386/machine.c |    8 ++++----
 4 files changed, 7 insertions(+), 4 deletions(-)

Strange diffstat.

Quoted 7 lines
target-i386/machine.c +0 -0
index 7f75d31..c1e05c5 100644
@@ -194,11 +194,11 @@ int cpu_load(QEMUFile *f, void *opaque, int version_id)
     int32_t a20_mask;
 

target-i386/machine.c int cpu_load(QEMUFile *f, void *opaque, int version_id) · line 201

Quoted 10 lines
target-i386/machine.c +3 -4
     if (version_id != 3 && version_id != 4 && version_id != 5
-        && version_id != 6 && version_id != 7 && version_id != 8)
-        return -EINVAL;
-    /* KVM cannot accept migrations from QEMU today */
-    if (version_id != 9)
+        && version_id != 6 && version_id != 7 && version_id != 8
+        /* KVM cannot accept migrations from QEMU today */
+        && version_id != 9)
         return -EINVAL;
 

I think you want to remove the first line as well? Only accept version_id == 9? And keep the comment.

Signature · 1 line
error compiling committee.c: too many arguments to function
#2 lore raw
Quoted 6 lines · Avi Kivity
Quoted 2 lines · Glauber Costa

Due to a small messup in version checking, migration was not working. fix it.

I think you want to remove the first line as well? Only accept version_id == 9? And keep the comment.

Meanwhile I've reverted the offending patch, 7b2e5aba.

Signature · 1 line
error compiling committee.c: too many arguments to function