]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/video/sstfb.c
Pull esi-support into release branch
[linux-2.6-omap-h63xx.git] / drivers / video / sstfb.c
index 8c1a8b5135c67105ea575eb4930c91f981722d42..dad54e73147b4d68420fb5c189889c94213f34bd 100644 (file)
@@ -82,7 +82,6 @@
  * Includes
  */
 
-#include <linux/config.h>
 #include <linux/string.h>
 #include <linux/kernel.h>
 #include <linux/module.h>
@@ -1194,10 +1193,11 @@ static struct dac_switch dacs[] __devinitdata = {
 static int __devinit sst_detect_dactype(struct fb_info *info, struct sstfb_par *par)
 {
        int i, ret = 0;
-       
-       for (i=0; i<sizeof(dacs)/sizeof(dacs[0]); i++) {
+
+       for (i = 0; i < ARRAY_SIZE(dacs); i++) {
                ret = dacs[i].detect(info);
-               if (ret) break;
+               if (ret)
+                       break;
        }
        if (!ret)
                return 0;
@@ -1604,8 +1604,8 @@ static int sstfb_dump_regs(struct fb_info *info)
                {FBZMODE,"fbzmode"},
        };
 
-       const int pci_s = sizeof(pci_regs)/sizeof(pci_regs[0]);
-       const int sst_s = sizeof(sst_regs)/sizeof(sst_regs[0]);
+       const int pci_s = ARRAY_SIZE(pci_regs);
+       const int sst_s = ARRAY_SIZE(sst_regs);
        struct sstfb_par *par = info->par;
        struct pci_dev *dev = par->dev;
        u32 pci_res[pci_s];