i440fx-test: remove ARRAY_SIZE redefinition
PATCH 1/1 i440fx-test: remove ARRAY_SIZE redefinition
It's defined in osdep.h and shouldn't be redefined here.
--- tests/i440fx-test.c | 2 -- 1 file changed, 2 deletions(-)
tests/i440fx-test.c +0 -2
@@ -27,8 +27,6 @@#define BROKEN 1 -#define ARRAY_SIZE (array) (sizeof(array) / sizeof((array)[0])) - typedef struct TestData { int num_cpus;
Signature · 1 line
1.9.1
Quoted 3 lines · Emilio G. Cota
It's defined in
osdep.hand shouldn't be redefined here.Signed-off-by Emilio G. Cota <[email protected]>
It looks like there may be another one too:
hw/audio/fmopl.c:#define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0]))
Regards,
Peter
Quoted 21 lines
--- tests/i440fx-test.c | 2 -- 1 file changed, 2 deletions(-)tests/i440fx-test.c +0
-3@@ -27,8 +27,6 @@#define BROKEN 1 -#define ARRAY_SIZE (array) (sizeof(array) / sizeof((array)[0])) - typedef struct TestData { int num_cpus; --1.9.1
Quoted 7 lines · Peter Crosthwaite
Quoted 3 lines · Emilio G. Cota
It's defined in
osdep.hand shouldn't be redefined here.Signed-off-by Emilio G. Cota <[email protected]>Reviewed-by Peter Crosthwaite <[email protected]>
Thanks for having a look!
Quoted 3 lines
It looks like there may be another one too:
hw/audio/fmopl.c:#define
ARRAY_SIZE(x)(sizeof(x) / sizeof((x)[0]))
That one is protected by #ifndef ARRAY_SIZE and AFAICT the file does not include any qemu headers, so we can safely leave it as is.
Emilio
Quoted 13 lines · Emilio G. Cota
It's defined in
osdep.hand shouldn't be redefined here.Signed-off-by Emilio G. Cota <[email protected]>--- tests/i440fx-test.c | 2 -- 1 file changed, 2 deletions(-)tests/i440fx-test.c +0
-0
tests/i440fx-test.c line 32
Quoted 8 lines
tests/i440fx-test.c +0
-2@@ -27,8 +27,6 @@#define BROKEN 1 -#define ARRAY_SIZE (array) (sizeof(array) / sizeof((array)[0])) - typedef struct TestData { int num_cpus;
Looks good; I am CCing [email protected] so that Michael will notice this patch.
Paolo
Michael Tokarev
AppliedApplied to -trivial, thanks!
So much for removing one line :)
/mjt