From: Paolo Bonzini <pbonzini@redhat.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: qemu-devel@nongnu.org, Mark Kanda <mark.kanda@oracle.com>
Subject: Re: [PATCH 5/8] qmp: add filtering of statistics by provider
Date: Tue, 24 May 2022 18:42:16 +0200 [thread overview]
Message-ID: <b1809a3c-cb27-ab90-b339-92548f36ca87@redhat.com> (raw)
In-Reply-To: <877d6bxg9a.fsf@pond.sub.org>
On 5/24/22 14:32, Markus Armbruster wrote:
>> + * @provider: stats provider
> Argument documentation that merely paraphrases the type is redundant.
> May I have a proper contract?
>
"stats provider matched against QMP command arguments"?
>>
>> +static bool stats_provider_requested(StatsProvider provider,
>> + StatsFilter *filter)
>> +{
>> + StatsRequestList *request;
>> +
>> + if (!filter->has_providers) {
>> + return true;
>> + }
>> + for (request = filter->providers; request; request = request->next) {
>> + if (request->value->provider == provider) {
>> + return true;
>> + }
>> + }
>> + return false;
>> +}
>> +
>
> This is just like apply_str_list_filter(). Good! Could we make the two
> names similar, too?
It looks similar but there is a difference in patch 7, in that it also
returns the "names" filter. I can rename it to
find_stats_provider_filter() if you prefer.
All other suggestions applied, thanks.
Paolo
next prev parent reply other threads:[~2022-05-24 16:44 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-23 15:05 [PATCH v4 0/8] qmp, hmp: statistics subsystem and KVM suport Paolo Bonzini
2022-05-23 15:07 ` [PATCH 1/8] qmp: Support for querying stats Paolo Bonzini
2022-05-23 15:07 ` [PATCH 2/8] kvm: Support for querying fd-based stats Paolo Bonzini
2022-05-23 15:07 ` [PATCH 3/8] qmp: add filtering of statistics by target vCPU Paolo Bonzini
2022-05-24 11:20 ` Markus Armbruster
2022-05-23 15:07 ` [PATCH 4/8] hmp: add basic "info stats" implementation Paolo Bonzini
2022-05-24 17:22 ` Mark Kanda
2022-05-23 15:07 ` [PATCH 5/8] qmp: add filtering of statistics by provider Paolo Bonzini
2022-05-24 12:32 ` Markus Armbruster
2022-05-24 16:42 ` Paolo Bonzini [this message]
2022-05-23 15:07 ` [PATCH 6/8] hmp: " Paolo Bonzini
2022-05-23 15:07 ` [PATCH 7/8] qmp: add filtering of statistics by name Paolo Bonzini
2022-05-24 13:08 ` Markus Armbruster
2022-05-24 16:49 ` Paolo Bonzini
2022-05-25 7:49 ` Markus Armbruster
2022-05-23 15:07 ` [PATCH 8/8] hmp: " Paolo Bonzini
2022-05-24 10:41 ` [PATCH 1/8] qmp: Support for querying stats Markus Armbruster
2022-05-24 16:47 ` Paolo Bonzini
2022-05-24 12:20 ` Markus Armbruster
-- strict thread matches above, loose matches on Subject: below --
2022-04-26 14:16 [PATCH 0/8] qmp, hmp: statistics subsystem and KVM suport Paolo Bonzini
2022-04-26 14:16 ` [PATCH 5/8] qmp: add filtering of statistics by provider Paolo Bonzini
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=b1809a3c-cb27-ab90-b339-92548f36ca87@redhat.com \
--to=pbonzini@redhat.com \
--cc=armbru@redhat.com \
--cc=mark.kanda@oracle.com \
--cc=qemu-devel@nongnu.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;
as well as URLs for NNTP newsgroup(s).