[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 12/12] migration: migration.h was not needed
From: |
Juan Quintela |
Subject: |
Re: [Qemu-devel] [PATCH 12/12] migration: migration.h was not needed |
Date: |
Mon, 15 May 2017 13:10:59 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux) |
"Dr. David Alan Gilbert" <address@hidden> wrote:
> * Juan Quintela (address@hidden) wrote:
>> This files don't use any function from migration.h, so drop it.
>>
>> Signed-off-by: Juan Quintela <address@hidden>
>> ---
>> block/qed.c | 1 -
>> hw/i386/pc_q35.c | 1 -
>> hw/virtio/vhost-user.c | 1 -
>> hw/virtio/vhost-vsock.c | 1 -
>> hw/virtio/virtio.c | 1 -
>> monitor.c | 1 -
>> 6 files changed, 6 deletions(-)
>>
>> diff --git a/block/qed.c b/block/qed.c
>> index fd76817..8d899fd 100644
>> --- a/block/qed.c
>> +++ b/block/qed.c
>> @@ -19,7 +19,6 @@
>> #include "trace.h"
>> #include "qed.h"
>> #include "qapi/qmp/qerror.h"
>> -#include "migration/migration.h"
>> #include "sysemu/block-backend.h"
>>
>> static const AIOCBInfo qed_aiocb_info = {
>> diff --git a/hw/i386/pc_q35.c b/hw/i386/pc_q35.c
>> index dd792a8..76b08f8 100644
>> --- a/hw/i386/pc_q35.c
>> +++ b/hw/i386/pc_q35.c
>> @@ -46,7 +46,6 @@
>> #include "hw/ide/ahci.h"
>> #include "hw/usb.h"
>> #include "qemu/error-report.h"
>> -#include "migration/migration.h"
>>
>> /* ICH9 AHCI has 6 ports */
>> #define MAX_SATA_PORTS 6
>> diff --git a/hw/virtio/vhost-user.c b/hw/virtio/vhost-user.c
>> index 9334a8a..ebc8ccf 100644
>> --- a/hw/virtio/vhost-user.c
>> +++ b/hw/virtio/vhost-user.c
>> @@ -17,7 +17,6 @@
>> #include "sysemu/kvm.h"
>> #include "qemu/error-report.h"
>> #include "qemu/sockets.h"
>> -#include "migration/migration.h"
>>
>> #include <sys/ioctl.h>
>> #include <sys/socket.h>
>> diff --git a/hw/virtio/vhost-vsock.c b/hw/virtio/vhost-vsock.c
>> index b481562..49e0022 100644
>> --- a/hw/virtio/vhost-vsock.c
>> +++ b/hw/virtio/vhost-vsock.c
>> @@ -17,7 +17,6 @@
>> #include "qapi/error.h"
>> #include "hw/virtio/virtio-bus.h"
>> #include "hw/virtio/virtio-access.h"
>> -#include "migration/migration.h"
>> #include "qemu/error-report.h"
>> #include "hw/virtio/vhost-vsock.h"
>> #include "qemu/iov.h"
>
> Aren't these including it to get vmstate macros?
> but have they picked up that instead somewhere?
hw/hw.h
hw/virtio/vhost-vsock.h -> hw/virtio/virtio.h -> hw/hw.h
Dropping vmstate.h from that file would have mean have to add one
hundred new includes or so. And I didn't see any good reason for that.
My understanding is that all devices end including hw/hw.h one way or
another, so the only reason to add migration include files right now is:
- you use old registartion functions
- you use blockers
- you use migration notifiers
Otherwise, if you just use vmstate macros, they are there by hw/hw.h.
Later, Juan.
- [Qemu-devel] [PATCH 07/12] migration: Move page_cache.c to migration/, (continued)
- [Qemu-devel] [PATCH 07/12] migration: Move page_cache.c to migration/, Juan Quintela, 2017/05/12
- [Qemu-devel] [PATCH 08/12] migration: Move qjson.h to migration/, Juan Quintela, 2017/05/12
- [Qemu-devel] [PATCH 10/12] migration: Remove qemu-file.h from vmstate.h, Juan Quintela, 2017/05/12
- [Qemu-devel] [PATCH 09/12] migration: Split vmstate-types.c from vmstate.c, Juan Quintela, 2017/05/12
- [Qemu-devel] [PATCH 11/12] migration: Remove vmstate.h from migration.h, Juan Quintela, 2017/05/12
- [Qemu-devel] [PATCH 12/12] migration: migration.h was not needed, Juan Quintela, 2017/05/12