]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
Merge branch 'fix' of git://git.kernel.org/pub/scm/linux/kernel/git/ycmiao/pxa-linux-2.6
authorRussell King <rmk@dyn-67.arm.linux.org.uk>
Mon, 23 Mar 2009 16:42:30 +0000 (16:42 +0000)
committerRussell King <rmk+kernel@arm.linux.org.uk>
Mon, 23 Mar 2009 16:42:30 +0000 (16:42 +0000)
1  2 
drivers/video/pxafb.c

diff --combined drivers/video/pxafb.c
index 2552b9f325ee9b4c33eea202329e23e47b544c3e,40a5d9d66755a9c895e9e9dd2a63e81404b0647d..642c1d47178fbd5a3d6b58efc5e1738b2386f44a
@@@ -883,10 -883,21 +883,21 @@@ static void __devinit init_pxafb_overla
        init_completion(&ofb->branch_done);
  }
  
+ static inline int pxafb_overlay_supported(void)
+ {
+       if (cpu_is_pxa27x() || cpu_is_pxa3xx())
+               return 1;
+       return 0;
+ }
  static int __devinit pxafb_overlay_init(struct pxafb_info *fbi)
  {
        int i, ret;
  
+       if (!pxafb_overlay_supported())
+               return 0;
        for (i = 0; i < 2; i++) {
                init_pxafb_overlay(fbi, &fbi->overlay[i], i);
                ret = register_framebuffer(&fbi->overlay[i].fb);
@@@ -909,6 -920,9 +920,9 @@@ static void __devexit pxafb_overlay_exi
  {
        int i;
  
+       if (!pxafb_overlay_supported())
+               return;
        for (i = 0; i < 2; i++)
                unregister_framebuffer(&fbi->overlay[i].fb);
  }
@@@ -2230,7 -2244,7 +2244,7 @@@ static int __devexit pxafb_remove(struc
  
  static struct platform_driver pxafb_driver = {
        .probe          = pxafb_probe,
 -      .remove         = pxafb_remove,
 +      .remove         = __devexit_p(pxafb_remove),
        .suspend        = pxafb_suspend,
        .resume         = pxafb_resume,
        .driver         = {