aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/pm2fb.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/video/pm2fb.c')
-rw-r--r--drivers/video/pm2fb.c24
1 files changed, 14 insertions, 10 deletions
diff --git a/drivers/video/pm2fb.c b/drivers/video/pm2fb.c
index 30181b593829..3f1ca2adda3d 100644
--- a/drivers/video/pm2fb.c
+++ b/drivers/video/pm2fb.c
@@ -56,7 +56,7 @@
56#undef PM2FB_MASTER_DEBUG 56#undef PM2FB_MASTER_DEBUG
57#ifdef PM2FB_MASTER_DEBUG 57#ifdef PM2FB_MASTER_DEBUG
58#define DPRINTK(a, b...) \ 58#define DPRINTK(a, b...) \
59 printk(KERN_DEBUG "pm2fb: %s: " a, __FUNCTION__ , ## b) 59 printk(KERN_DEBUG "pm2fb: %s: " a, __func__ , ## b)
60#else 60#else
61#define DPRINTK(a, b...) 61#define DPRINTK(a, b...)
62#endif 62#endif
@@ -67,7 +67,7 @@
67 * Driver data 67 * Driver data
68 */ 68 */
69static int hwcursor = 1; 69static int hwcursor = 1;
70static char *mode __devinitdata; 70static char *mode_option __devinitdata;
71 71
72/* 72/*
73 * The XFree GLINT driver will (I think to implement hardware cursor 73 * The XFree GLINT driver will (I think to implement hardware cursor
@@ -1680,17 +1680,19 @@ static int __devinit pm2fb_probe(struct pci_dev *pdev,
1680 info->pixmap.scan_align = 1; 1680 info->pixmap.scan_align = 1;
1681 } 1681 }
1682 1682
1683 if (!mode) 1683 if (!mode_option)
1684 mode = "640x480@60"; 1684 mode_option = "640x480@60";
1685 1685
1686 err = fb_find_mode(&info->var, info, mode, NULL, 0, NULL, 8); 1686 err = fb_find_mode(&info->var, info, mode_option, NULL, 0, NULL, 8);
1687 if (!err || err == 4) 1687 if (!err || err == 4)
1688 info->var = pm2fb_var; 1688 info->var = pm2fb_var;
1689 1689
1690 if (fb_alloc_cmap(&info->cmap, 256, 0) < 0) 1690 retval = fb_alloc_cmap(&info->cmap, 256, 0);
1691 if (retval < 0)
1691 goto err_exit_both; 1692 goto err_exit_both;
1692 1693
1693 if (register_framebuffer(info) < 0) 1694 retval = register_framebuffer(info);
1695 if (retval < 0)
1694 goto err_exit_all; 1696 goto err_exit_all;
1695 1697
1696 printk(KERN_INFO "fb%d: %s frame buffer device, memory = %dK.\n", 1698 printk(KERN_INFO "fb%d: %s frame buffer device, memory = %dK.\n",
@@ -1797,7 +1799,7 @@ static int __init pm2fb_setup(char *options)
1797 else if (!strncmp(this_opt, "noaccel", 7)) 1799 else if (!strncmp(this_opt, "noaccel", 7))
1798 noaccel = 1; 1800 noaccel = 1;
1799 else 1801 else
1800 mode = this_opt; 1802 mode_option = this_opt;
1801 } 1803 }
1802 return 0; 1804 return 0;
1803} 1805}
@@ -1833,8 +1835,10 @@ static void __exit pm2fb_exit(void)
1833#ifdef MODULE 1835#ifdef MODULE
1834module_exit(pm2fb_exit); 1836module_exit(pm2fb_exit);
1835 1837
1836module_param(mode, charp, 0); 1838module_param(mode_option, charp, 0);
1837MODULE_PARM_DESC(mode, "Preferred video mode e.g. '648x480-8@60'"); 1839MODULE_PARM_DESC(mode_option, "Initial video mode e.g. '648x480-8@60'");
1840module_param_named(mode, mode_option, charp, 0);
1841MODULE_PARM_DESC(mode, "Initial video mode e.g. '648x480-8@60' (deprecated)");
1838module_param(lowhsync, bool, 0); 1842module_param(lowhsync, bool, 0);
1839MODULE_PARM_DESC(lowhsync, "Force horizontal sync low regardless of mode"); 1843MODULE_PARM_DESC(lowhsync, "Force horizontal sync low regardless of mode");
1840module_param(lowvsync, bool, 0); 1844module_param(lowvsync, bool, 0);