On Wed, Jan 18, 2023 at 05:25:37AM -0500, Michael S. Tsirkin wrote:
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?
I wasn't refering to the specific docs per-se, but rather that no
code does this at all in QEMU. It is effectively our style, even
if not documented as such