]> Git Repo - qemu.git/commitdiff
vmstate: add VMSTATE_STRUCT_VARRAY_INT32
authorJuan Quintela <[email protected]>
Thu, 10 Mar 2011 11:33:51 +0000 (12:33 +0100)
committerAnthony Liguori <[email protected]>
Thu, 10 Mar 2011 22:12:26 +0000 (16:12 -0600)
Signed-off-by: Juan Quintela <[email protected]>
Signed-off-by: Anthony Liguori <[email protected]>
hw/hw.h

diff --git a/hw/hw.h b/hw/hw.h
index 6e78fa92c2d4fbbaa39f33d42a6c7af222cfb030..0ed63c52b9053362ef3613a4dc94d9c9c544dcd1 100644 (file)
--- a/hw/hw.h
+++ b/hw/hw.h
@@ -529,6 +529,16 @@ extern const VMStateInfo vmstate_info_unused_buffer;
     .offset     = vmstate_offset_pointer(_state, _field, _type),     \
 }
 
+#define VMSTATE_STRUCT_VARRAY_INT32(_field, _state, _field_num, _version, _vmsd, _type) { \
+    .name       = (stringify(_field)),                               \
+    .num_offset = vmstate_offset_value(_state, _field_num, int32_t), \
+    .version_id = (_version),                                        \
+    .vmsd       = &(_vmsd),                                          \
+    .size       = sizeof(_type),                                     \
+    .flags      = VMS_STRUCT|VMS_VARRAY_INT32,                       \
+    .offset     = offsetof(_state, _field),                          \
+}
+
 #define VMSTATE_STATIC_BUFFER(_field, _state, _version, _test, _start, _size) { \
     .name         = (stringify(_field)),                             \
     .version_id   = (_version),                                      \
This page took 0.028362 seconds and 4 git commands to generate.