[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 01/18] qapi/qom: Add ObjectOptions for iothread
From: |
Kevin Wolf |
Subject: |
Re: [PATCH 01/18] qapi/qom: Add ObjectOptions for iothread |
Date: |
Mon, 30 Nov 2020 16:54:08 +0100 |
Am 30.11.2020 um 16:00 hat Paolo Bonzini geschrieben:
> On 30/11/20 13:25, Kevin Wolf wrote:
> > +##
> > +# @IothreadProperties:
> > +#
> > +# Properties for iothread objects.
> > +#
> > +# @poll-max-ns: the maximum number of nanoseconds to busy wait for events.
> > +# 0 means polling is disabled (default: 32768 on POSIX hosts,
> > +# 0 otherwise)
> > +#
> > +# @poll-grow: the multiplier used to increase the polling time when the
> > +# algorithm detects it is missing events due to not polling
> > long
> > +# enough. 0 selects a default behaviour (default: 0)
> > +#
> > +# @poll-shrink: the divisor used to decrease the polling time when the
> > +# algorithm detects it is spending too long polling without
> > +# encountering events. 0 selects a default behaviour
> > (default: 0)
> > +#
> > +# Since: 6.0
> > +##
> > +{ 'struct': 'IothreadProperties',
> > + 'data': { '*poll-max-ns': 'int',
> > + '*poll-grow': 'int',
> > + '*poll-shrink': 'int' } }
> > +
>
> Documentation is the main advantage of the ObjectOptions concept. However,
> please use the version where each object and property was introduced for the
> "since" value. Otherwise the documentation will appear to show that none of
> these objects was available before 6.0.
>
> Yes, there is no documentation at all right now for QOM objects. However,
> wrong documentation sometimes is worse than non-existing documentation.
I think we generally use the version when the schema was introduced (so
blockdev-add has 2.9 for most things even if they existed before in
-drive and drive_add), but I agree that your suggestion is more useful.
And object-add isn't a new command, we're just giving it a schema now.
So let's first discuss the general direction, but if we agree on that,
using the version numbers where objects and properties were first
introduced makes sense.
Maybe if maintainers can include the right version numbers in the review
of the patch for "their" object, that would help me updating the
patches.
Kevin
- [PATCH 00/18] qapi/qom: QAPIfy object-add, Kevin Wolf, 2020/11/30
- [PATCH 01/18] qapi/qom: Add ObjectOptions for iothread, Kevin Wolf, 2020/11/30
- [PATCH 02/18] qapi/qom: Add ObjectOptions for authz-*, Kevin Wolf, 2020/11/30
- [PATCH 03/18] qapi/qom: Add ObjectOptions for cryptodev-*, Kevin Wolf, 2020/11/30
- [PATCH 06/18] qapi/qom: Add ObjectOptions for rng-*, deprecate 'opened', Kevin Wolf, 2020/11/30
- [PATCH 04/18] qapi/qom: Add ObjectOptions for dbus-vmstate, Kevin Wolf, 2020/11/30
- [PATCH 05/18] qapi/qom: Add ObjectOptions for memory-backend-*, Kevin Wolf, 2020/11/30
- [PATCH 08/18] qapi/qom: Add ObjectOptions for secret*, deprecate 'loaded', Kevin Wolf, 2020/11/30
- [PATCH 07/18] qapi/qom: Add ObjectOptions for throttle-group, Kevin Wolf, 2020/11/30
- [PATCH 09/18] qapi/qom: Add ObjectOptions for tls-*, deprecate 'loaded', Kevin Wolf, 2020/11/30
- [PATCH 10/18] qapi/qom: Add ObjectOptions for can-*, Kevin Wolf, 2020/11/30
- [PATCH 11/18] qapi/qom: Add ObjectOptions for colo-compare, Kevin Wolf, 2020/11/30