vserver 1.9.3
[linux-2.6.git] / drivers / video / cyber2000fb.c
index 0afebb7..4dca34f 100644 (file)
@@ -1166,7 +1166,7 @@ static struct fb_videomode __devinitdata cyber2000fb_default_mode = {
        .vmode          = FB_VMODE_NONINTERLACED
 };
 
-static char igs_regs[] __devinitdata = {
+static char igs_regs[] = {
        EXT_CRT_IRQ,            0,
        EXT_CRT_TEST,           0,
        EXT_SYNC_CTL,           0,
@@ -1281,7 +1281,7 @@ cyberpro_alloc_fb_info(unsigned int id, char *name)
        cfb->fb.var.accel_flags = FB_ACCELF_TEXT;
 
        cfb->fb.fbops           = &cyber2000fb_ops;
-       cfb->fb.flags           = FBINFO_FLAG_DEFAULT;
+       cfb->fb.flags           = FBINFO_DEFAULT | FBINFO_HWACCEL_YPAN;
        cfb->fb.pseudo_palette  = (void *)(cfb + 1);
 
        fb_alloc_cmap(&cfb->fb.cmap, NR_PALETTE, 0);
@@ -1289,7 +1289,7 @@ cyberpro_alloc_fb_info(unsigned int id, char *name)
        return cfb;
 }
 
-static void __devinit
+static void
 cyberpro_free_fb_info(struct cfb_info *cfb)
 {
        if (cfb) {
@@ -1712,11 +1712,21 @@ static struct pci_driver cyberpro_driver = {
  * I don't think we can use the "module_init" stuff here because
  * the fbcon stuff may not be initialised yet.  Hence the #ifdef
  * around module_init.
+ *
+ * Tony: "module_init" is now required
  */
 int __init cyber2000fb_init(void)
 {
        int ret = -1, err;
 
+#ifndef MODULE
+       char *option = NULL;
+
+       if (fb_get_options("cyber2000fb", NULL))
+               return -ENODEV;
+       cyber2000fb_setup(option);
+#endif
+
 #ifdef CONFIG_ARCH_SHARK
        err = cyberpro_vl_probe();
        if (!err) {
@@ -1738,9 +1748,7 @@ static void __exit cyberpro_exit(void)
        pci_unregister_driver(&cyberpro_driver);
 }
 
-#ifdef MODULE
 module_init(cyber2000fb_init);
-#endif
 module_exit(cyberpro_exit);
 
 MODULE_AUTHOR("Russell King");