Blob Blame History Raw
From 1a8352af8e4dafcf91e2f1ee66e7695dda9d4a4d Mon Sep 17 00:00:00 2001
From: Eduardo Habkost <ehabkost@redhat.com>
Date: Wed, 16 Oct 2013 13:07:15 +0200
Subject: acpi/piix4: Enable qemu-kvm compatibility mode

RH-Author: Eduardo Habkost <ehabkost@redhat.com>
Message-id: <1381928835-10190-1-git-send-email-ehabkost@redhat.com>
Patchwork-id: 54961
O-Subject: [qemu-kvm RHEL-7 PATCH] acpi/piix4: Enable qemu-kvm compatibility mode
Bugzilla: 1019474
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
RH-Acked-by: Orit Wasserman <owasserm@redhat.com>
RH-Acked-by: Igor Mammedov <imammedo@redhat.com>

Bugzilla: 1019474
Scratch build: https://brewweb.devel.redhat.com/taskinfo?taskID=6426533
Upstream status: not applicable

>From the code comments:

  qemu-kvm 1.2 uses version 3 but advertised as 2
  To support incoming qemu-kvm 1.2 migration, change version_id
  and minimum_version_id to 2 below (which breaks migration from
  qemu 1.2).

The v2 format of qemu-0.13 (implemented by upstream commit
4cf3e6f3d85492f20a773dd6c9068ab89ba24a18, and the one that was used on
qemu-kvm) is not compatible with the v2 format of qemu-0.15 and newer
(compatibility was broken by upstream commit
23910d3f669d46073b403876e30a7314599633af). RHEL-6 is using the former
format (RHEL-6 commit c4101c5340988caa68da87066a88d3871c8c4bf1), which
is not compatible with upstream QEMU.

This sets minimum_version_id to 2, so we enable the qemu-kvm
compatibility mode, to allow us to load RHEL-6 migration data.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>

diff --git a/hw/acpi/piix4.c b/hw/acpi/piix4.c
index 913b2b0..dd1f92b 100644
--- a/hw/acpi/piix4.c
+++ b/hw/acpi/piix4.c
@@ -275,7 +275,7 @@ static const VMStateDescription vmstate_memhp_state = {
 static const VMStateDescription vmstate_acpi = {
     .name = "piix4_pm",
     .version_id = 3,
-    .minimum_version_id = 3,
+    .minimum_version_id = 2,
     .minimum_version_id_old = 1,
     .load_state_old = acpi_load_old,
     .post_load = vmstate_acpi_post_load,