tools/libxc: Introduce ARRAY_SIZE() and replace handrolled examples
authorAndrew Cooper <andrew.cooper3@citrix.com>
Tue, 10 Jun 2014 14:07:59 +0000 (15:07 +0100)
committerIan Campbell <ian.campbell@citrix.com>
Tue, 10 Jun 2014 15:04:03 +0000 (16:04 +0100)
commit7528dcd02de1fa72acbc841a3608046549a163a2
tree5d92890af52205b2c705fbda1b7187267ca9d02f
parent33233c27583458e9205bd1d156cff976d06a83db
tools/libxc: Introduce ARRAY_SIZE() and replace handrolled examples

xen-hptool and xen-mfndump include xc_private.h.  This is bad, but not trivial
to fix, so they gain a protective #undef and a stern comment.

MiniOS leaks ARRAY_SIZE into the libxc namespace as part of a stubdom build.
Therefore, xc_private.h gains an #ifndef until MiniOS is fixed.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
CC: Ian Campbell <Ian.Campbell@citrix.com>
CC: Ian Jackson <Ian.Jackson@eu.citrix.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
tools/libxc/xc_dom_arm.c
tools/libxc/xc_dom_x86.c
tools/libxc/xc_minios.c
tools/libxc/xc_private.h
tools/misc/xen-hptool.c
tools/misc/xen-mfndump.c