diff options
author | Marc-André Lureau <marcandre.lureau@redhat.com> | 2018-11-14 17:29:30 +0400 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2018-11-27 15:35:15 +0100 |
commit | 03fee66fde3f9e179e3973e8c50f6fa0a0a14613 (patch) | |
tree | 0e9eb8138fe8f5a653b752e54f0cc035d48a2aab /hw/pci/shpc.c | |
parent | 5aaac46793828d01c893b9d99d905c657f59541e (diff) | |
download | qemu-03fee66fde3f9e179e3973e8c50f6fa0a0a14613.zip qemu-03fee66fde3f9e179e3973e8c50f6fa0a0a14613.tar.gz qemu-03fee66fde3f9e179e3973e8c50f6fa0a0a14613.tar.bz2 |
vmstate: constify VMStateField
Because they are supposed to remain const.
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20181114132931.22624-1-marcandre.lureau@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'hw/pci/shpc.c')
-rw-r--r-- | hw/pci/shpc.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/hw/pci/shpc.c b/hw/pci/shpc.c index a8462d4..96a43d2 100644 --- a/hw/pci/shpc.c +++ b/hw/pci/shpc.c @@ -688,8 +688,8 @@ void shpc_cap_write_config(PCIDevice *d, uint32_t addr, uint32_t val, int l) shpc_cap_update_dword(d); } -static int shpc_save(QEMUFile *f, void *pv, size_t size, VMStateField *field, - QJSON *vmdesc) +static int shpc_save(QEMUFile *f, void *pv, size_t size, + const VMStateField *field, QJSON *vmdesc) { PCIDevice *d = container_of(pv, PCIDevice, shpc); qemu_put_buffer(f, d->shpc->config, SHPC_SIZEOF(d)); @@ -697,7 +697,8 @@ static int shpc_save(QEMUFile *f, void *pv, size_t size, VMStateField *field, return 0; } -static int shpc_load(QEMUFile *f, void *pv, size_t size, VMStateField *field) +static int shpc_load(QEMUFile *f, void *pv, size_t size, + const VMStateField *field) { PCIDevice *d = container_of(pv, PCIDevice, shpc); int ret = qemu_get_buffer(f, d->shpc->config, SHPC_SIZEOF(d)); |