@@ -563,7 +563,7 @@ static const VMStateDescription vmstate_exynos4210_uart_fifo = {
.fields = (VMStateField[]) {
VMSTATE_UINT32(sp, Exynos4210UartFIFO),
VMSTATE_UINT32(rp, Exynos4210UartFIFO),
- VMSTATE_VBUFFER_UINT32(data, Exynos4210UartFIFO, 1, NULL, 0, size),
+ VMSTATE_VBUFFER_UINT32(data, Exynos4210UartFIFO, size),
VMSTATE_END_OF_LIST()
}
};
@@ -461,7 +461,7 @@ static const VMStateDescription vmstate_g364fb = {
.minimum_version_id = 1,
.post_load = g364fb_post_load,
.fields = (VMStateField[]) {
- VMSTATE_VBUFFER_UINT32(vram, G364State, 1, NULL, 0, vram_size),
+ VMSTATE_VBUFFER_UINT32(vram, G364State, vram_size),
VMSTATE_BUFFER_UNSAFE(color_palette, G364State, 256 * 3),
VMSTATE_BUFFER_UNSAFE(cursor_palette, G364State, 9),
VMSTATE_UINT16_ARRAY(cursor, G364State, 512),
@@ -170,8 +170,8 @@ static const VMStateDescription vmstate_pl330_fifo = {
.version_id = 1,
.minimum_version_id = 1,
.fields = (VMStateField[]) {
- VMSTATE_VBUFFER_UINT32(buf, PL330Fifo, 1, NULL, 0, buf_size),
- VMSTATE_VBUFFER_UINT32(tag, PL330Fifo, 1, NULL, 0, buf_size),
+ VMSTATE_VBUFFER_UINT32(buf, PL330Fifo, buf_size),
+ VMSTATE_VBUFFER_UINT32(tag, PL330Fifo, buf_size),
VMSTATE_UINT32(head, PL330Fifo),
VMSTATE_UINT32(num, PL330Fifo),
VMSTATE_UINT32(buf_size, PL330Fifo),
@@ -279,8 +279,8 @@ static const VMStateDescription vmstate_pl330 = {
VMSTATE_STRUCT(manager, PL330State, 0, vmstate_pl330_chan, PL330Chan),
VMSTATE_STRUCT_VARRAY_UINT32(chan, PL330State, num_chnls, 0,
vmstate_pl330_chan, PL330Chan),
- VMSTATE_VBUFFER_UINT32(lo_seqn, PL330State, 1, NULL, 0, num_chnls),
- VMSTATE_VBUFFER_UINT32(hi_seqn, PL330State, 1, NULL, 0, num_chnls),
+ VMSTATE_VBUFFER_UINT32(lo_seqn, PL330State, num_chnls),
+ VMSTATE_VBUFFER_UINT32(hi_seqn, PL330State, num_chnls),
VMSTATE_STRUCT(fifo, PL330State, 0, vmstate_pl330_fifo, PL330Fifo),
VMSTATE_STRUCT(read_queue, PL330State, 0, vmstate_pl330_queue,
PL330Queue),
@@ -395,7 +395,7 @@ static const VMStateDescription vmstate_exynos4210_irq_gate = {
.version_id = 2,
.minimum_version_id = 2,
.fields = (VMStateField[]) {
- VMSTATE_VBUFFER_UINT32(level, Exynos4210IRQGateState, 1, NULL, 0, n_in),
+ VMSTATE_VBUFFER_UINT32(level, Exynos4210IRQGateState, n_in),
VMSTATE_END_OF_LIST()
}
};
@@ -2176,8 +2176,7 @@ static const VMStateDescription vmxstate_vmxnet3_mcast_list = {
.minimum_version_id = 1,
.pre_load = vmxnet3_mcast_list_pre_load,
.fields = (VMStateField[]) {
- VMSTATE_VBUFFER_UINT32(mcast_list, VMXNET3State, 0, NULL, 0,
- mcast_list_buff_size),
+ VMSTATE_VBUFFER_UINT32(mcast_list, VMXNET3State, mcast_list_buff_size),
VMSTATE_END_OF_LIST()
}
};
@@ -97,7 +97,7 @@ static const VMStateDescription vmstate_macio_nvram = {
.version_id = 1,
.minimum_version_id = 1,
.fields = (VMStateField[]) {
- VMSTATE_VBUFFER_UINT32(data, MacIONVRAMState, 0, NULL, 0, size),
+ VMSTATE_VBUFFER_UINT32(data, MacIONVRAMState, size),
VMSTATE_END_OF_LIST()
}
};
@@ -1223,7 +1223,7 @@ const VMStateDescription sdhci_vmstate = {
VMSTATE_UINT16(data_count, SDHCIState),
VMSTATE_UINT64(admasysaddr, SDHCIState),
VMSTATE_UINT8(stopped_state, SDHCIState),
- VMSTATE_VBUFFER_UINT32(fifo_buffer, SDHCIState, 1, NULL, 0, buf_maxsz),
+ VMSTATE_VBUFFER_UINT32(fifo_buffer, SDHCIState, buf_maxsz),
VMSTATE_TIMER(insert_timer, SDHCIState),
VMSTATE_TIMER(transfer_timer, SDHCIState),
VMSTATE_END_OF_LIST()
@@ -598,7 +598,7 @@ static const VMStateDescription vmstate_m48t59 = {
.fields = (VMStateField[]) {
VMSTATE_UINT8(lock, M48t59State),
VMSTATE_UINT16(addr, M48t59State),
- VMSTATE_VBUFFER_UINT32(buffer, M48t59State, 0, NULL, 0, size),
+ VMSTATE_VBUFFER_UINT32(buffer, M48t59State, size),
VMSTATE_END_OF_LIST()
}
};
@@ -415,15 +415,12 @@ extern const VMStateInfo vmstate_info_bitmap;
.start = (_start), \
}
-#define VMSTATE_VBUFFER_UINT32(_field, _state, _version, _test, _start, _field_size) { \
+#define VMSTATE_VBUFFER_UINT32(_field, _state, _field_size) { \
.name = (stringify(_field)), \
- .version_id = (_version), \
- .field_exists = (_test), \
.size_offset = vmstate_offset_value(_state, _field_size, uint32_t),\
.info = &vmstate_info_buffer, \
.flags = VMS_VBUFFER|VMS_POINTER, \
.offset = offsetof(_state, _field), \
- .start = (_start), \
}
#define VMSTATE_BUFFER_UNSAFE_TEST(_field, _state, _test, _info, _size) { \
@@ -620,7 +617,7 @@ extern const VMStateInfo vmstate_info_bitmap;
VMSTATE_VBUFFER(_f, _s, NULL, 0, _size)
#define VMSTATE_PARTIAL_VBUFFER_UINT32(_f, _s, _size) \
- VMSTATE_VBUFFER_UINT32(_f, _s, 0, NULL, 0, _size)
+ VMSTATE_VBUFFER_UINT32(_f, _s, _size)
#define VMSTATE_SUB_VBUFFER(_f, _s, _start, _size) \
VMSTATE_VBUFFER(_f, _s, NULL, _start, _size)
@@ -117,7 +117,7 @@ const VMStateDescription vmstate_fifo8 = {
.version_id = 1,
.minimum_version_id = 1,
.fields = (VMStateField[]) {
- VMSTATE_VBUFFER_UINT32(data, Fifo8, 1, NULL, 0, capacity),
+ VMSTATE_VBUFFER_UINT32(data, Fifo8, capacity),
VMSTATE_UINT32(head, Fifo8),
VMSTATE_UINT32(num, Fifo8),
VMSTATE_END_OF_LIST()
None of its users use them. Signed-off-by: Juan Quintela <quintela@redhat.com> --- hw/char/exynos4210_uart.c | 2 +- hw/display/g364fb.c | 2 +- hw/dma/pl330.c | 8 ++++---- hw/intc/exynos4210_gic.c | 2 +- hw/net/vmxnet3.c | 3 +-- hw/nvram/mac_nvram.c | 2 +- hw/sd/sdhci.c | 2 +- hw/timer/m48t59.c | 2 +- include/migration/vmstate.h | 7 ++----- util/fifo8.c | 2 +- 10 files changed, 14 insertions(+), 18 deletions(-)