From: Juan Quintela <quintela@redhat.com>
To: Eduardo Habkost <ehabkost@redhat.com>
Cc: qemu-devel@nongnu.org, qemu-arm@nongnu.org,
qemu-block@nongnu.org, qemu-s390x@nongnu.org,
qemu-ppc@nongnu.org, kvm@vger.kernel.org,
xen-devel@lists.xenproject.org, qemu-riscv@nongnu.org
Subject: Re: [PATCH v3 64/74] [automated] Move QOM typedefs and add missing includes
Date: Wed, 26 Aug 2020 10:05:28 +0200 [thread overview]
Message-ID: <87o8mxygqf.fsf@secure.mitica> (raw)
In-Reply-To: <20200825192110.3528606-65-ehabkost@redhat.com> (Eduardo Habkost's message of "Tue, 25 Aug 2020 15:21:00 -0400")
[dropped people from CC]
Eduardo Habkost <ehabkost@redhat.com> wrote:
> Some typedefs and macros are defined after the type check macros.
> This makes it difficult to automatically replace their
> definitions with OBJECT_DECLARE_TYPE.
>
> Patch generated using:
>
> $ ./scripts/codeconverter/converter.py -i \
> --pattern=QOMStructTypedefSplit $(git grep -l '' -- '*.[ch]')
>
> which will split "typdef struct { ... } TypedefName"
> declarations.
>
> Followed by:
>
> $ ./scripts/codeconverter/converter.py -i --pattern=MoveSymbols \
> $(git grep -l '' -- '*.[ch]')
>
> which will:
> - move the typedefs and #defines above the type check macros
> - add missing #include "qom/object.h" lines if necessary
>
> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> ---
> Changes v2 -> v3:
> * Removed hunks due to rebase conflicts: hw/arm/integratorcp.c
> hw/arm/versatilepb.c hw/arm/vexpress.c hw/sd/pl181.c
> include/hw/ppc/xive.h
> * Removed hunks due to conflicts with other patches in this
> series: include/hw/block/swim.h include/hw/display/macfb.h
> include/hw/rdma/rdma.h migration/migration.h
> target/rx/cpu-qom.h
> * Reviewed-by line from Daniel was kept, as no additional hunks
> are introduced in this version
>
> Changes v1 -> v2:
> * Re-ran script after moving a few macros and typedefs. Now the
> patch also changes:
> - SysbusAHCIState at hw/ide/ahci.h
> - VhostUserGPU at hw/virtio/virtio-gpu.h
> - I8257State at hw/dma/i8257.h
> - AllwinnerAHCIState at hw/ide/ahci.h
> - ISAKBDState at hw/input/i8042.h
> - PIIXState at hw/southbridge/piix.h
> - VFIOPCIDevice at hw/vfio/pci.h
> - missing include at hw/net/rocker/rocker.h
> - missing include at hw/scsi/mptsas.h
> - missing include at include/hw/arm/pxa.h
> - missing include at include/sysemu/kvm.h
>
> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
> diff --git a/migration/rdma.c b/migration/rdma.c
> index 15ad985d26..e3eac913bc 100644
> --- a/migration/rdma.c
> +++ b/migration/rdma.c
> @@ -35,6 +35,7 @@
> #include <arpa/inet.h>
> #include <rdma/rdma_cma.h>
> #include "trace.h"
> +#include "qom/object.h"
>
> /*
> * Print and error on both the Monitor and the Log file.
> @@ -397,10 +398,10 @@ typedef struct RDMAContext {
> } RDMAContext;
>
> #define TYPE_QIO_CHANNEL_RDMA "qio-channel-rdma"
> +typedef struct QIOChannelRDMA QIOChannelRDMA;
> #define QIO_CHANNEL_RDMA(obj) \
> OBJECT_CHECK(QIOChannelRDMA, (obj), TYPE_QIO_CHANNEL_RDMA)
>
> -typedef struct QIOChannelRDMA QIOChannelRDMA;
>
>
> struct QIOChannelRDMA {
Reviewed-by: Juan Quintela <quintela@redhat.com>
next prev parent reply other threads:[~2020-08-26 8:05 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20200825192110.3528606-1-ehabkost@redhat.com>
2020-08-25 19:20 ` [PATCH v3 41/74] kvm: Move QOM macros to kvm.h Eduardo Habkost
[not found] ` <20200825192110.3528606-63-ehabkost@redhat.com>
2020-08-26 8:02 ` [PATCH v3 62/74] [automated] Use TYPE_INFO macro Juan Quintela
[not found] ` <20200825192110.3528606-65-ehabkost@redhat.com>
2020-08-26 8:05 ` Juan Quintela [this message]
[not found] ` <20200825192110.3528606-67-ehabkost@redhat.com>
2020-08-26 8:08 ` [PATCH v3 66/74] [automated] Use DECLARE_*CHECKER* macros Juan Quintela
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87o8mxygqf.fsf@secure.mitica \
--to=quintela@redhat.com \
--cc=ehabkost@redhat.com \
--cc=kvm@vger.kernel.org \
--cc=qemu-arm@nongnu.org \
--cc=qemu-block@nongnu.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-ppc@nongnu.org \
--cc=qemu-riscv@nongnu.org \
--cc=qemu-s390x@nongnu.org \
--cc=xen-devel@lists.xenproject.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox