summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJan Kiszka <jan.kiszka@siemens.com>2011-03-06 16:09:49 +0100
committerBlue Swirl <blauwirbel@gmail.com>2011-03-19 08:29:04 +0000
commitca22a3a3758ee7ab14166058d4ce36bc6cdfdfd8 (patch)
tree985c319acbcb0a5303bd06d447a46665fa4d575e
parent00914b7d9707586d2ebe9faeea6f733c9fd51dc8 (diff)
downloadhqemu-ca22a3a3758ee7ab14166058d4ce36bc6cdfdfd8.zip
hqemu-ca22a3a3758ee7ab14166058d4ce36bc6cdfdfd8.tar.gz
i8254: Fix migration from older versions
qdev conversion broke migration as the previous version used vmstate instance IDs derived from the iobase. Fix it by registering a legacy alias. Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
-rw-r--r--hw/i8254.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/i8254.c b/hw/i8254.c
index eaf5d3e..47c9d73 100644
--- a/hw/i8254.c
+++ b/hw/i8254.c
@@ -520,6 +520,8 @@ static int pit_initfn(ISADevice *dev)
register_ioport_read(pit->iobase, 3, 1, pit_ioport_read, pit);
isa_init_ioport(dev, pit->iobase);
+ qdev_set_legacy_instance_id(&dev->qdev, pit->iobase, 2);
+
return 0;
}
OpenPOWER on IntegriCloud