[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 19/21] Teach analyze-migration.py about section foote
From: |
Juan Quintela |
Subject: |
[Qemu-devel] [PULL 19/21] Teach analyze-migration.py about section footers |
Date: |
Fri, 12 Jun 2015 07:03:48 +0200 |
From: "Dr. David Alan Gilbert" <address@hidden>
Signed-off-by: Dr. David Alan Gilbert <address@hidden>
Signed-off-by: Juan Quintela <address@hidden>
---
scripts/analyze-migration.py | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/scripts/analyze-migration.py b/scripts/analyze-migration.py
index 0c8b22f..f6894be 100755
--- a/scripts/analyze-migration.py
+++ b/scripts/analyze-migration.py
@@ -474,6 +474,7 @@ class MigrationDump(object):
QEMU_VM_SECTION_FULL = 0x04
QEMU_VM_SUBSECTION = 0x05
QEMU_VM_VMDESCRIPTION = 0x06
+ QEMU_VM_SECTION_FOOTER= 0x7e
def __init__(self, filename):
self.section_classes = { ( 'ram', 0 ) : [ RamSection, None ],
@@ -526,6 +527,10 @@ class MigrationDump(object):
elif section_type == self.QEMU_VM_SECTION_PART or section_type ==
self.QEMU_VM_SECTION_END:
section_id = file.read32()
self.sections[section_id].read()
+ elif section_type == self.QEMU_VM_SECTION_FOOTER:
+ read_section_id = file.read32()
+ if read_section_id != section_id:
+ raise Exception("Mismatched section footer: %x vs %x" %
(read_section_id, section_id))
else:
raise Exception("Unknown section type: %d" % section_type)
file.close()
--
2.4.3
- [Qemu-devel] [PULL 10/21] Add qemu_get_counted_string to read a string prefixed by a count byte, (continued)
- [Qemu-devel] [PULL 10/21] Add qemu_get_counted_string to read a string prefixed by a count byte, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 11/21] Split header writing out of qemu_savevm_state_begin, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 12/21] qemu_ram_foreach_block: pass up error value, and down the ramblock name, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 09/21] migration: Use normal VMStateDescriptions for Subsections, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 13/21] Create MigrationIncomingState, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 14/21] Move copy out of qemu_peek_buffer, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 15/21] Move loadvm_handlers into MigrationIncomingState, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 16/21] Merge section header writing, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 17/21] Disable section footers on older machine types, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 18/21] Add a protective section footer, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 19/21] Teach analyze-migration.py about section footers,
Juan Quintela <=
- [Qemu-devel] [PULL 20/21] Rename RDMA structures to make destination clear, Juan Quintela, 2015/06/12
- [Qemu-devel] [PULL 21/21] Remove unneeded memset, Juan Quintela, 2015/06/12
- Re: [Qemu-devel] [PULL v2 00/21] migration pull request, Peter Maydell, 2015/06/12