From 2366fb16abcd8dea96820d3cb4f1de3a868d268c Mon Sep 17 00:00:00 2001 From: "Ahmed S. Darwish" Date: Mon, 5 Feb 2007 16:14:10 -0800 Subject: [POWERPC] PPC: Use ARRAY_SIZE macro when appropriate Use ARRAY_SIZE macro already defined in linux/kernel.h Signed-off-by: Ahmed S. Darwish Cc: Benjamin Herrenschmidt Acked-by: Kumar Gala Signed-off-by: Andrew Morton Signed-off-by: Paul Mackerras --- arch/ppc/lib/rheap.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'arch/ppc/lib') diff --git a/arch/ppc/lib/rheap.c b/arch/ppc/lib/rheap.c index 31e511856dc5..d40700795a9c 100644 --- a/arch/ppc/lib/rheap.c +++ b/arch/ppc/lib/rheap.c @@ -14,6 +14,7 @@ */ #include #include +#include #include #include @@ -654,7 +655,7 @@ void rh_dump(rh_info_t * info) int maxnr; int i, nr; - maxnr = sizeof(st) / sizeof(st[0]); + maxnr = ARRAY_SIZE(st); printk(KERN_INFO "info @0x%p (%d slots empty / %d max)\n", -- cgit v1.2.3