From: Eric Blake <eblake@redhat.com>
To: Wenchao Xia <wenchaoqemu@gmail.com>,
Igor Mammedov <imammedo@redhat.com>,
qemu-devel@nongnu.org
Cc: mst@redhat.com
Subject: Re: [Qemu-devel] [PATCH v3] qmp: add ACPI_DEVICE_OST event handling
Date: Mon, 23 Jun 2014 09:56:00 -0600 [thread overview]
Message-ID: <53A84E10.90201@redhat.com> (raw)
In-Reply-To: <53A4C815.4040003@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 1834 bytes --]
On 06/20/2014 05:47 PM, Wenchao Xia wrote:
>> Not your fault, as the problem already exists, but it's a bit awkward
>> that qapi-event.json is not self-contained, and your patch is only
>> making it worse. qapi-event.json only makes sense when included by
>> qapi-schema.json, when ideally it would be nice if it made sense if
>> compiled in isolation. I already pointed this fact out on Wenchao's
>> series that made events part of QAPI, but fixing it first requires
>> teaching the code generators to flag places where a type is used without
>> a pre-definition, so that we know which types have to be moved into a
>> common include. So don't let this comment hold up your patch.
>>
> I think two issues should be addressed:
> 1 don't let generator guess the type if define is not found.
But we WANT to allow use of a type so long as it gets defined later in
the same file. So the trick is distinguishing between:
base.json - use of 'TypeFoo'
total.json: include base.json, define 'TypeFoo'
(broken, base.json was not self-contained)
vs.
base.json - define 'TypeFoo'
total.json - use of 'TypeFoo', then include base.json
(supported - even though 'TypeFoo' was used prior to being defined, the
include later in the file meant that total.json was self-contained)
> 2 Support duplicated include, that is:
>
> qapi/types.json
> |
> ---------------------------
> | |
> qapi/qapi-event.json qapi/block.json
> | |
> qapi-schema-json
>
> Making sure above include doesn't generate two copy of types from
> qapi/types.json.
We already support that.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 604 bytes --]
next prev parent reply other threads:[~2014-06-23 15:56 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-20 8:33 [Qemu-devel] [PATCH v3] qmp: add ACPI_DEVICE_OST event handling Igor Mammedov
2014-06-20 15:46 ` Eric Blake
2014-06-20 23:47 ` Wenchao Xia
2014-06-23 9:52 ` Markus Armbruster
2014-06-23 15:56 ` Eric Blake [this message]
2014-06-22 5:58 ` Michael S. Tsirkin
2014-06-23 15:59 ` Eric Blake
2014-06-23 17:17 ` Eric Blake
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=53A84E10.90201@redhat.com \
--to=eblake@redhat.com \
--cc=imammedo@redhat.com \
--cc=mst@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=wenchaoqemu@gmail.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.