ARRAY_SIZE is another define commonly used in tools. Add it to the kernel includes. Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> --- scripts/include/linux/kernel.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/scripts/include/linux/kernel.h b/scripts/include/linux/kernel.h index 76df535..5d94e98 100644 --- a/scripts/include/linux/kernel.h +++ b/scripts/include/linux/kernel.h @@ -6,6 +6,8 @@ #include <stdlib.h> #include <assert.h> +#define ARRAY_SIZE(arr) (sizeof(arr) / sizeof((arr)[0])) + #define DIV_ROUND_UP(n,d) (((n) + (d) - 1) / (d)) #define PERF_ALIGN(x, a) __PERF_ALIGN_MASK(x, (typeof(x))(a)-1) -- 2.7.0.rc3 _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox