All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Michael S. Tsirkin" <mst@redhat.com>
To: "Daniel P. Berrangé" <berrange@redhat.com>
Cc: zhenwei pi <pizhenwei@bytedance.com>,
	arei.gonglei@huawei.com, dgilbert@redhat.com, eblake@redhat.com,
	armbru@redhat.com, michael.roth@amd.com, pbonzini@redhat.com,
	qemu-devel@nongnu.org
Subject: Re: [for-8.0 v2 05/11] cryptodev: Introduce 'query-cryptodev' QMP command
Date: Wed, 18 Jan 2023 05:25:37 -0500	[thread overview]
Message-ID: <20230118052127-mutt-send-email-mst@kernel.org> (raw)
In-Reply-To: <Y8UyezxcEeE+TH2p@redhat.com>

On Mon, Jan 16, 2023 at 11:18:19AM +0000, Daniel P. Berrangé wrote:
> > +    for (uint32_t i = 0; i < QCRYPTODEV_BACKEND_SERVICE__MAX; i++) {
> 
> QEMU coding style doesn't declare types inside the for() control
> conditions. I'd suggest 'size_t i', and put it at top of this
> function.

It's actually kind of vague:

	Mixed declarations (interleaving statements and declarations within
	blocks) are generally not allowed; declarations should be at the beginning
	of blocks.

for loop starts a block, does it not?

It's in C99 but we use designated initializers widely so we already
depend on that.

-- 
MST



  reply	other threads:[~2023-01-18 10:26 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-22 14:07 [for-8.0 v2 00/11] Refactor cryptodev zhenwei pi
2022-11-22 14:07 ` [for-8.0 v2 01/11] cryptodev: Introduce cryptodev.json zhenwei pi
2023-01-16 10:58   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 02/11] cryptodev: Remove 'name' & 'model' fields zhenwei pi
2023-01-16 11:05   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 03/11] cryptodev: Introduce cryptodev alg type in QAPI zhenwei pi
2023-01-16 11:08   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 04/11] cryptodev: Introduce server " zhenwei pi
2023-01-16 11:09   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 05/11] cryptodev: Introduce 'query-cryptodev' QMP command zhenwei pi
2023-01-16 11:18   ` Daniel P. Berrangé
2023-01-18 10:25     ` Michael S. Tsirkin [this message]
2023-01-18 10:29       ` Daniel P. Berrangé
2023-01-18 10:58         ` Thomas Huth
2023-01-18 11:01           ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 06/11] cryptodev: Support statistics zhenwei pi
2022-12-20 15:35   ` Michael S. Tsirkin
2023-01-16 11:22   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 07/11] cryptodev-builtin: Detect akcipher capability zhenwei pi
2023-01-16 11:23   ` Daniel P. Berrangé
2022-11-22 14:07 ` [for-8.0 v2 08/11] hmp: add cryptodev info command zhenwei pi
2022-11-22 14:07 ` [for-8.0 v2 09/11] cryptodev: Use CryptoDevBackendOpInfo for operation zhenwei pi
2022-11-22 14:07 ` [for-8.0 v2 10/11] cryptodev: support QoS zhenwei pi
2022-11-22 14:07 ` [for-8.0 v2 11/11] MAINTAINERS: add myself as the maintainer for cryptodev zhenwei pi
2022-12-16  3:24 ` PING: [for-8.0 v2 00/11] Refactor cryptodev zhenwei pi
2022-12-20 15:36 ` Michael S. Tsirkin
2022-12-22  2:04   ` zhenwei pi
2023-01-03  6:14     ` PING: " zhenwei pi
2023-01-16  9:53   ` zhenwei pi
2023-01-16 11:27     ` Daniel P. Berrangé
2023-01-17  1:52       ` zhenwei pi

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=20230118052127-mutt-send-email-mst@kernel.org \
    --to=mst@redhat.com \
    --cc=arei.gonglei@huawei.com \
    --cc=armbru@redhat.com \
    --cc=berrange@redhat.com \
    --cc=dgilbert@redhat.com \
    --cc=eblake@redhat.com \
    --cc=michael.roth@amd.com \
    --cc=pbonzini@redhat.com \
    --cc=pizhenwei@bytedance.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 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.