[PATCH] V850: user ARRAY_SIZE macro when appropriate
[sfrench/cifs-2.6.git] / arch / v850 / kernel / rte_cb.c
index 0c794b9e0f9b8c1187eed1d2b9e43a3f8f4e2066..43018e1edebd13b6bf84558ef32628c13056c0af 100644 (file)
  * Written by Miles Bader <miles@gnu.org>
  */
 
-#include <linux/config.h>
 #include <linux/init.h>
 #include <linux/irq.h>
 #include <linux/fs.h>
 #include <linux/module.h>
+#include <linux/kernel.h>
 
 #include <asm/machdep.h>
 #include <asm/v850e_uart.h>
@@ -177,8 +177,7 @@ static struct gbus_int_irq_init gbus_irq_inits[] = {
 #endif
        { 0 }
 };
-#define NUM_GBUS_IRQ_INITS  \
-   ((sizeof gbus_irq_inits / sizeof gbus_irq_inits[0]) - 1)
+#define NUM_GBUS_IRQ_INITS (ARRAY_SIZE(gbus_irq_inits) - 1)
 
 static struct hw_interrupt_type gbus_hw_itypes[NUM_GBUS_IRQ_INITS];