|
From: | Michael Tokarev |
Subject: | Re: [Qemu-devel] [PATCH] util: vfio-helpers: use ARRAY_SIZE in qemu_vfio_init_pci() |
Date: | Fri, 30 Nov 2018 22:38:34 +0300 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.3.0 |
30.11.2018 15:58, Laurent Vivier wrote:
- for (i = 0; i < 6; i++) { + for (i = 0; i < ARRAY_SIZE(s->bar_region_info); i++) {
I'm wondering if adding a #define to define the size of the array and then using it with the for() loop wouldn't be better?
On the other side, it doesn't really matter, one way or another.. It's so.. trivial.. ;) /mjt
[Prev in Thread] | Current Thread | [Next in Thread] |