[PATCH] drivers/video: Use ARRAY_SIZE macro
[pandora-kernel.git] / drivers / video / pmagb-b-fb.c
index a483b13..73e2d7d 100644 (file)
@@ -27,7 +27,6 @@
 #include <linux/module.h>
 #include <linux/types.h>
 
-#include <asm/bug.h>
 #include <asm/io.h>
 #include <asm/system.h>
 
@@ -132,7 +131,6 @@ static struct fb_ops pmagbbfb_ops = {
        .fb_fillrect    = cfb_fillrect,
        .fb_copyarea    = cfb_copyarea,
        .fb_imageblit   = cfb_imageblit,
-       .fb_cursor      = soft_cursor,
 };
 
 
@@ -230,7 +228,7 @@ static void __init pmagbbfb_osc_setup(struct fb_info *info)
 
        freq1 = (par->osc0 * count1 + count0 / 2) / count0;
        par->osc1 = freq1;
-       for (i = 0; i < sizeof(pmagbbfb_freqs) / sizeof(*pmagbbfb_freqs); i++)
+       for (i = 0; i < ARRAY_SIZE(pmagbbfb_freqs); i++)
                if (freq1 >= pmagbbfb_freqs[i] -
                             (pmagbbfb_freqs[i] + 128) / 256 &&
                    freq1 <= pmagbbfb_freqs[i] +