* [PATCH 1/3 RESEND] fbcon: fix fbcon's setup routine
@ 2004-09-13 15:18 Antonino A. Daplas
0 siblings, 0 replies; only message in thread
From: Antonino A. Daplas @ 2004-09-13 15:18 UTC (permalink / raw)
To: Andrew Morton; +Cc: Linux Fbdev development list, linux-kernel
Fix fbcon's setup routine so usage is consistent with previous kernels.
Ie: video=ofonly and video=xxxfb:off should work.
This is done by fb_get_options() returning a nonzero value if:
- 'off' option is present
- 'ofonly' is present but driver name is not 'offb'
All drivers will not proceed with their initialization if return value is
nonzero.
Signed-off-by: Antonino Daplas <adaplas@pol.net>
---
drivers/video/68328fb.c | 6 +++-
drivers/video/acornfb.c | 6 +++-
drivers/video/amba-clcd.c | 2 +
drivers/video/amifb.c | 6 +++-
drivers/video/asiliantfb.c | 3 ++
drivers/video/aty/aty128fb.c | 11 +++++++-
drivers/video/aty/atyfb_base.c | 22 ++++++++++-------
drivers/video/aty/radeon_base.c | 6 +++-
drivers/video/bw2.c | 3 ++
drivers/video/cg14.c | 3 ++
drivers/video/cg3.c | 3 ++
drivers/video/cg6.c | 3 ++
drivers/video/chipsfb.c | 3 ++
drivers/video/cirrusfb.c | 6 +++-
drivers/video/clps711xfb.c | 3 ++
drivers/video/controlfb.c | 5 +++
drivers/video/cyber2000fb.c | 6 +++-
drivers/video/dnfb.c | 3 ++
drivers/video/epson1355fb.c | 3 ++
drivers/video/fbmem.c | 44 ++++++++++++++++++++--------------
drivers/video/ffb.c | 3 ++
drivers/video/fm2fb.c | 6 +++-
drivers/video/g364fb.c | 3 ++
drivers/video/gbefb.c | 6 +++-
drivers/video/hgafb.c | 3 ++
drivers/video/hitfb.c | 3 ++
drivers/video/hpfb.c | 3 ++
drivers/video/i810/i810_main.c | 6 +++-
drivers/video/igafb.c | 3 ++
drivers/video/imsttfb.c | 7 ++++-
drivers/video/kyro/fbdev.c | 6 +++-
drivers/video/leo.c | 3 ++
drivers/video/macfb.c | 5 +++
drivers/video/matrox/matroxfb_base.c | 6 +++-
drivers/video/matrox/matroxfb_crtc2.c | 3 ++
drivers/video/maxinefb.c | 3 ++
drivers/video/neofb.c | 6 +++-
drivers/video/offb.c | 5 +++
drivers/video/p9100.c | 3 ++
drivers/video/platinumfb.c | 6 +++-
drivers/video/pm2fb.c | 6 +++-
drivers/video/pmag-ba-fb.c | 3 ++
drivers/video/pmagb-b-fb.c | 3 ++
drivers/video/pvr2fb.c | 6 +++-
drivers/video/pxafb.c | 6 +++-
drivers/video/q40fb.c | 3 ++
drivers/video/radeonfb.c | 6 +++-
drivers/video/riva/fbdev.c | 6 +++-
drivers/video/sa1100fb.c | 3 ++
drivers/video/sgivwfb.c | 6 +++-
drivers/video/sis/sis_main.c | 6 +++-
drivers/video/skeletonfb.c | 6 +++-
drivers/video/sstfb.c | 6 +++-
drivers/video/stifb.c | 6 +++-
drivers/video/tcx.c | 3 ++
drivers/video/tdfxfb.c | 7 ++++-
drivers/video/tgafb.c | 6 +++-
drivers/video/tridentfb.c | 6 +++-
drivers/video/tx3912fb.c | 5 +++
drivers/video/valkyriefb.c | 5 +++
drivers/video/vesafb.c | 5 +++
drivers/video/vfb.c | 6 +++-
drivers/video/vga16fb.c | 8 ++++--
include/linux/fb.h | 2 -
64 files changed, 298 insertions(+), 63 deletions(-)
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/68328fb.c linux-2.6.9-rc1-mm5/drivers/video/68328fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/68328fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/68328fb.c 2004-09-13 22:52:52.397298432 +0800
@@ -440,7 +440,11 @@ int __init mc68x328fb_setup(char *option
int __init mc68x328fb_init(void)
{
#ifndef MODULE
- mc68x328fb_setup(fb_get_options("68328fb"));
+ char *option = NULL;
+
+ if (fb_get_options("68328fb", &option))
+ return -ENODEV;
+ mc68x328fb_setup(option);
#endif
/*
* initialize the default mode from the LCD controller registers
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/acornfb.c linux-2.6.9-rc1-mm5/drivers/video/acornfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/acornfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/acornfb.c 2004-09-13 22:52:52.399298128 +0800
@@ -1291,8 +1291,12 @@ acornfb_init(void)
unsigned long size;
u_int h_sync, v_sync;
int rc, i;
+ char *option = NULL;
+
+ if (fb_get_options("acornfb", &option))
+ return -ENODEV;
+ acornfb_setup(option);
- acornfb_setup(fb_get_options("acornfb"));
acornfb_init_fbinfo();
current_par.dev = &acornfb_device;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/amba-clcd.c linux-2.6.9-rc1-mm5/drivers/video/amba-clcd.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/amba-clcd.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/amba-clcd.c 2004-09-13 22:52:52.400297976 +0800
@@ -496,6 +496,8 @@ static struct amba_driver clcd_driver =
int __init amba_clcdfb_init(void)
{
+ if (fb_get_options("ambafb", NULL))
+ return -ENODEV;
return amba_driver_register(&clcd_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/amifb.c linux-2.6.9-rc1-mm5/drivers/video/amifb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/amifb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/amifb.c 2004-09-13 22:52:52.403297520 +0800
@@ -2258,7 +2258,11 @@ int __init amifb_init(void)
u_int defmode;
#ifndef MODULE
- amifb_setup(fb_get_options("amifb"));
+ char *option = NULL;
+
+ if (fb_get_options("amifb", &option))
+ return -ENODEV;
+ amifb_setup(option);
#endif
if (!MACH_IS_AMIGA || !AMIGAHW_PRESENT(AMI_VIDEO))
return -ENXIO;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/asiliantfb.c linux-2.6.9-rc1-mm5/drivers/video/asiliantfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/asiliantfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/asiliantfb.c 2004-09-13 22:52:52.405297216 +0800
@@ -609,6 +609,9 @@ static struct pci_driver asiliantfb_driv
int __init asiliantfb_init(void)
{
+ if (fb_get_options("asiliantfb", NULL))
+ return -ENODEV;
+
return pci_module_init(&asiliantfb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/aty/aty128fb.c linux-2.6.9-rc1-mm5/drivers/video/aty/aty128fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/aty/aty128fb.c 2004-09-08 12:44:12.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/aty/aty128fb.c 2004-09-13 22:52:52.407296912 +0800
@@ -2439,6 +2439,14 @@ static int aty128_pci_resume(struct pci_
int __init aty128fb_init(void)
{
+#ifndef MODULE
+ char *option = NULL;
+
+ if (fb_get_options("aty128fb", &option))
+ return -ENODEV;
+ aty128fb_setup(option);
+#endif
+
return pci_module_init(&aty128fb_driver);
}
@@ -2447,8 +2455,9 @@ static void __exit aty128fb_exit(void)
pci_unregister_driver(&aty128fb_driver);
}
-#ifdef MODULE
module_init(aty128fb_init);
+
+#ifdef MODULE
module_exit(aty128fb_exit);
MODULE_AUTHOR("(c)1999-2003 Brad Douglas <brad@neruo.com>");
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/aty/atyfb_base.c linux-2.6.9-rc1-mm5/drivers/video/aty/atyfb_base.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/aty/atyfb_base.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/aty/atyfb_base.c 2004-09-13 22:53:54.234897688 +0800
@@ -1902,7 +1902,7 @@ static int __init aty_init(struct fb_inf
return 1;
}
-int __init atyfb_init(void)
+int __init atyfb_do_init(void)
{
#if defined(CONFIG_PCI)
unsigned long addr, res_start, res_size;
@@ -1920,13 +1920,6 @@ int __init atyfb_init(void)
#else
u16 tmp;
#endif
-#endif
-
-#ifndef MODULE
- atyfb_setup(fb_get_options("atyfb"));
-#endif
-
-#if defined(CONFIG_PCI)
#ifdef __sparc__
/* Do not attach when we have a serial console. */
@@ -2386,6 +2379,19 @@ int __init atyfb_init(void)
return 0;
}
+int __init atyfb_init(void)
+{
+#ifndef MODULE
+ char *option = NULL;
+
+ if (fb_get_options("atyfb", &option))
+ return -ENODEV;
+ atyfb_setup(option);
+#endif
+ return atyfb_do_init();
+}
+
+
#ifndef MODULE
int __init atyfb_setup(char *options)
{
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/aty/radeon_base.c linux-2.6.9-rc1-mm5/drivers/video/aty/radeon_base.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/aty/radeon_base.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/aty/radeon_base.c 2004-09-13 22:52:52.415295696 +0800
@@ -2373,7 +2373,11 @@ int __init radeonfb_setup (char *options
int __init radeonfb_init (void)
{
#ifndef MODULE
- radeonfb_setup(fb_get_options("radeonfb"));
+ char *option = NULL;
+
+ if (fb_get_options("radeonfb", &option))
+ return -ENODEV;
+ radeonfb_setup(option);
#endif
return pci_module_init (&radeonfb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/bw2.c linux-2.6.9-rc1-mm5/drivers/video/bw2.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/bw2.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/bw2.c 2004-09-13 22:52:52.417295392 +0800
@@ -386,6 +386,9 @@ int __init bw2_init(void)
struct sbus_bus *sbus;
struct sbus_dev *sdev;
+ if (fb_get_options("bw2fb", &option))
+ return -ENODEV;
+
#ifdef CONFIG_SUN4
bw2_init_one(NULL);
#endif
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/cg14.c linux-2.6.9-rc1-mm5/drivers/video/cg14.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/cg14.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/cg14.c 2004-09-13 22:52:52.419295088 +0800
@@ -584,6 +584,9 @@ int __init cg14_init(void)
struct sbus_bus *sbus;
struct sbus_dev *sdev;
+ if (fb_get_options("cg14fb", NULL))
+ return -ENODEV;
+
#ifdef CONFIG_SPARC32
{
int root, node;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/cg3.c linux-2.6.9-rc1-mm5/drivers/video/cg3.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/cg3.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/cg3.c 2004-09-13 22:52:52.419295088 +0800
@@ -444,6 +444,9 @@ int __init cg3_init(void)
struct sbus_bus *sbus;
struct sbus_dev *sdev;
+ if (fb_get_options("cg3fb", NULL))
+ return -ENODEV;
+
for_all_sbusdev(sdev, sbus) {
if (!strcmp(sdev->prom_name, "cgthree") ||
!strcmp(sdev->prom_name, "cgRDI"))
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/cg6.c linux-2.6.9-rc1-mm5/drivers/video/cg6.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/cg6.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/cg6.c 2004-09-13 22:52:52.420294936 +0800
@@ -760,6 +760,9 @@ int __init cg6_init(void)
struct sbus_bus *sbus;
struct sbus_dev *sdev;
+ if (fb_get_options("cg6fb", NULL))
+ return -ENODEV;
+
for_all_sbusdev(sdev, sbus) {
if (!strcmp(sdev->prom_name, "cgsix") ||
!strcmp(sdev->prom_name, "cgthree+"))
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/chipsfb.c linux-2.6.9-rc1-mm5/drivers/video/chipsfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/chipsfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/chipsfb.c 2004-09-13 22:52:52.421294784 +0800
@@ -462,6 +462,9 @@ static struct pci_driver chipsfb_driver
int __init chips_init(void)
{
+ if (fb_get_options("chipsfb", NULL))
+ return -ENODEV;
+
return pci_module_init(&chipsfb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/cirrusfb.c linux-2.6.9-rc1-mm5/drivers/video/cirrusfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/cirrusfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/cirrusfb.c 2004-09-13 22:52:52.424294328 +0800
@@ -2607,7 +2607,11 @@ int __init cirrusfb_init(void)
int error = 0;
#ifndef MODULE
- cirrusfb_setup(fb_get_options("cirrusfb"));
+ char *option = NULL;
+
+ if (fb_get_options("cirrusfb", &option))
+ return -ENODEV;
+ cirrusfb_setup(option);
#endif
#ifdef CONFIG_ZORRO
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/clps711xfb.c linux-2.6.9-rc1-mm5/drivers/video/clps711xfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/clps711xfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/clps711xfb.c 2004-09-13 22:52:52.426294024 +0800
@@ -364,6 +364,9 @@ int __init clps711xfb_init(void)
{
int err = -ENOMEM;
+ if (fb_get_options("clps711xfb", NULL))
+ return -ENODEV;
+
cfb = kmalloc(sizeof(*cfb), GFP_KERNEL);
if (!cfb)
goto out;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/controlfb.c linux-2.6.9-rc1-mm5/drivers/video/controlfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/controlfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/controlfb.c 2004-09-13 22:52:52.428293720 +0800
@@ -556,8 +556,11 @@ static void control_set_hardware(struct
int __init control_init(void)
{
struct device_node *dp;
+ char *option = NULL;
- control_setup(fb_get_options("controlfb"));
+ if (fb_get_options("controlfb", &option))
+ return -ENODEV;
+ control_setup(option);
dp = find_devices("control");
if (dp != 0 && !control_of_init(dp))
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/cyber2000fb.c linux-2.6.9-rc1-mm5/drivers/video/cyber2000fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/cyber2000fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/cyber2000fb.c 2004-09-13 22:52:52.430293416 +0800
@@ -1722,7 +1722,11 @@ int __init cyber2000fb_init(void)
int ret = -1, err;
#ifndef MODULE
- cyber2000fb_setup(fb_get_options("cyber200fb"));
+ char *option = NULL;
+
+ if (fb_get_options("cyber2000fb", NULL))
+ return -ENODEV;
+ cyber2000fb_setup(option);
#endif
#ifdef CONFIG_ARCH_SHARK
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/dnfb.c linux-2.6.9-rc1-mm5/drivers/video/dnfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/dnfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/dnfb.c 2004-09-13 22:52:52.431293264 +0800
@@ -284,6 +284,9 @@ int __init dnfb_init(void)
{
int ret;
+ if (fb_get_options("dnfb", NULL))
+ return -ENODEV;
+
ret = driver_register(&dnfb_driver);
if (!ret) {
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/epson1355fb.c linux-2.6.9-rc1-mm5/drivers/video/epson1355fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/epson1355fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/epson1355fb.c 2004-09-13 22:52:52.432293112 +0800
@@ -740,6 +740,9 @@ int __init epson1355fb_init(void)
{
int ret = 0;
+ if (fb_get_options("epson1355fb", NULL))
+ return -ENODEV;
+
ret = driver_register(&epson1355fb_driver);
if (!ret) {
ret = platform_device_register(&epson1355fb_device);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/fbmem.c linux-2.6.9-rc1-mm5/drivers/video/fbmem.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/fbmem.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/fbmem.c 2004-09-13 22:52:52.434292808 +0800
@@ -1298,6 +1298,7 @@ module_init(fbmem_init);
#define NR_FB_DRIVERS 64
static char *video_options[NR_FB_DRIVERS];
+static int ofonly;
/**
* fb_get_options - get kernel boot parameters
@@ -1307,30 +1308,35 @@ static char *video_options[NR_FB_DRIVERS
*
* NOTE: Needed to maintain backwards compatibility
*/
-char* fb_get_options(char *name)
+int fb_get_options(char *name, char **option)
{
- char *option = NULL;
- char *opt;
- int opt_len;
+ char *opt, *options = NULL;
+ int opt_len, retval = 0;
int name_len = strlen(name), i;
- if (!name_len)
- return option;
+ if (name_len && ofonly && strncmp(name, "offb", 4))
+ retval = 1;
- for (i = 0; i < NR_FB_DRIVERS; i++) {
- if (video_options[i] == NULL)
- continue;
- opt_len = strlen(video_options[i]);
- if (!opt_len)
- continue;
- opt = video_options[i];
- if (!strncmp(name, opt, name_len) &&
- opt[name_len] == ':') {
- option = opt + name_len + 1;
- break;
+ if (name_len && !retval) {
+ for (i = 0; i < NR_FB_DRIVERS; i++) {
+ if (video_options[i] == NULL)
+ continue;
+ opt_len = strlen(video_options[i]);
+ if (!opt_len)
+ continue;
+ opt = video_options[i];
+ if (!strncmp(name, opt, name_len) &&
+ opt[name_len] == ':')
+ options = opt + name_len + 1;
}
}
- return option;
+ if (options && !strncmp(options, "off", 3))
+ retval = 1;
+
+ if (option)
+ *option = options;
+
+ return retval;
}
/**
@@ -1355,6 +1361,8 @@ int __init video_setup(char *options)
return 0;
for (i = 0; i < NR_FB_DRIVERS; i++) {
+ if (!strncmp(options, "ofonly", 6))
+ ofonly = 1;
if (video_options[i] == NULL) {
video_options[i] = options;
break;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/ffb.c linux-2.6.9-rc1-mm5/drivers/video/ffb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/ffb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/ffb.c 2004-09-13 22:52:52.436292504 +0800
@@ -1049,6 +1049,9 @@ int __init ffb_init(void)
{
int root;
+ if (fb_get_options("ffb", NULL))
+ return -ENODEV;
+
ffb_scan_siblings(prom_root_node);
root = prom_getchild(prom_root_node);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/fm2fb.c linux-2.6.9-rc1-mm5/drivers/video/fm2fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/fm2fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/fm2fb.c 2004-09-13 22:52:52.437292352 +0800
@@ -296,7 +296,11 @@ int __init fm2fb_setup(char *options);
int __init fm2fb_init(void)
{
- fm2fb_setup(fb_get_options("fb2fb"));
+ char *option = NULL;
+
+ if (fb_get_options("fm2fb", &option))
+ return -ENODEV;
+ fm2fb_setup(option);
return zorro_register_driver(&fm2fb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/g364fb.c linux-2.6.9-rc1-mm5/drivers/video/g364fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/g364fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/g364fb.c 2004-09-13 22:52:52.438292200 +0800
@@ -202,6 +202,9 @@ int __init g364fb_init(void)
(volatile unsigned int *) CURS_PAL_REG;
int mem, i, j;
+ if (fb_get_options("g364fb", NULL))
+ return -ENODEV;
+
/* TBD: G364 detection */
/* get the resolution set by ARC console */
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/gbefb.c linux-2.6.9-rc1-mm5/drivers/video/gbefb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/gbefb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/gbefb.c 2004-09-13 22:52:52.439292048 +0800
@@ -1084,7 +1084,11 @@ int __init gbefb_init(void)
int i, ret = 0;
#ifndef MODULE
- gbefb_setup(fb_get_options("gbefb"));
+ char *option = NULL;
+
+ if (fb_get_options("gbefb", &option))
+ return -ENODEV;
+ gbefb_setup(options);
#endif
if (!request_mem_region(GBE_BASE, sizeof(struct sgi_gbe), "GBE")) {
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/hgafb.c linux-2.6.9-rc1-mm5/drivers/video/hgafb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/hgafb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/hgafb.c 2004-09-13 22:52:52.440291896 +0800
@@ -547,6 +547,9 @@ static struct fb_ops hgafb_ops = {
int __init hgafb_init(void)
{
+ if (fb_get_options("hgafb", NULL))
+ return -ENODEV;
+
if (! hga_card_detect()) {
printk(KERN_INFO "hgafb: HGA card not detected.\n");
return -EINVAL;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/hitfb.c linux-2.6.9-rc1-mm5/drivers/video/hitfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/hitfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/hitfb.c 2004-09-13 22:52:52.441291744 +0800
@@ -270,6 +270,9 @@ int __init hitfb_init(void)
unsigned short lcdclor, ldr3, ldvndr;
int size;
+ if (fb_get_options("hitfb", NULL))
+ return -ENODEV;
+
hitfb_fix.smem_start = CONFIG_HD64461_IOBASE + 0x02000000;
hitfb_fix.smem_len = (MACH_HP690) ? 1024 * 1024 : 512 * 1024;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/hpfb.c linux-2.6.9-rc1-mm5/drivers/video/hpfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/hpfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/hpfb.c 2004-09-13 22:52:52.442291592 +0800
@@ -115,6 +115,9 @@ int __init hpfb_init_one(unsigned long b
{
unsigned long fboff;
+ if (fb_get_options("hpfb", NULL))
+ return -ENODEV;
+
fboff = (in_8(base + TOPCAT_FBOMSB) << 8) | in_8(base + TOPCAT_FBOLSB);
hpfb_fix.smem_start = 0xf0000000 | (in_8(base + fboff) << 16);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/i810/i810_main.c linux-2.6.9-rc1-mm5/drivers/video/i810/i810_main.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/i810/i810_main.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/i810/i810_main.c 2004-09-13 22:52:52.444291288 +0800
@@ -1980,7 +1980,11 @@ static void __exit i810fb_remove_pci(str
#ifndef MODULE
int __init i810fb_init(void)
{
- i810fb_setup(fb_get_options("i810fb"));
+ char *option = NULL;
+
+ if (fb_get_options("i810fb", &option))
+ return -ENODEV;
+ i810fb_setup(option);
if (pci_register_driver(&i810fb_driver) > 0)
return 0;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/igafb.c linux-2.6.9-rc1-mm5/drivers/video/igafb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/igafb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/igafb.c 2004-09-13 22:52:52.446290984 +0800
@@ -381,6 +381,9 @@ int __init igafb_init(void)
unsigned long addr;
int size, iga2000 = 0;
+ if (fb_get_options("igafb", NULL))
+ return -ENODEV;
+
/* Do not attach when we have a serial console. */
if (!con_is_present())
return -ENXIO;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/imsttfb.c linux-2.6.9-rc1-mm5/drivers/video/imsttfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/imsttfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/imsttfb.c 2004-09-13 22:52:52.447290832 +0800
@@ -1604,7 +1604,12 @@ imsttfb_setup(char *options)
int __init imsttfb_init(void)
{
#ifndef MODULE
- imsttfb_setup(fb_get_options("imsttfb"));
+ char *option = NULL;
+
+ if (fb_get_options("imsttfb", &option))
+ return -ENODEV;
+
+ imsttfb_setup(option);
#endif
return pci_module_init(&imsttfb_pci_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/kyro/fbdev.c linux-2.6.9-rc1-mm5/drivers/video/kyro/fbdev.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/kyro/fbdev.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/kyro/fbdev.c 2004-09-13 22:52:52.449290528 +0800
@@ -789,7 +789,11 @@ static void __devexit kyrofb_remove(stru
int __init kyrofb_init(void)
{
#ifndef MODULE
- kyrofb_setup(fb_get_options("kyrofb"));
+ char *option = NULL;
+
+ if (fb_get_options("kyrofb", &option))
+ return -ENODEV;
+ kyrofb_setup(option);
#endif
return pci_module_init(&kyrofb_pci_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/leo.c linux-2.6.9-rc1-mm5/drivers/video/leo.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/leo.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/leo.c 2004-09-13 22:52:52.450290376 +0800
@@ -626,6 +626,9 @@ int __init leo_init(void)
struct sbus_bus *sbus;
struct sbus_dev *sdev;
+ if (fb_get_options("leofb", NULL))
+ return -ENODEV;
+
for_all_sbusdev(sdev, sbus) {
if (!strcmp(sdev->prom_name, "leo"))
leo_init_one(sdev);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/macfb.c linux-2.6.9-rc1-mm5/drivers/video/macfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/macfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/macfb.c 2004-09-13 22:52:52.451290224 +0800
@@ -614,8 +614,11 @@ void __init macfb_init(void)
{
int video_cmap_len, video_is_nubus = 0;
struct nubus_dev* ndev = NULL;
+ char *option = NULL;
- macfb_setup(fb_get_options("macfb"));
+ if (fb_get_options("macfb", &option))
+ return -ENODEV;
+ macfb_setup(option);
if (!MACH_IS_MAC)
return;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/matrox/matroxfb_base.c linux-2.6.9-rc1-mm5/drivers/video/matrox/matroxfb_base.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/matrox/matroxfb_base.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/matrox/matroxfb_base.c 2004-09-13 22:52:52.454289768 +0800
@@ -2416,9 +2416,13 @@ static int __initdata initialized = 0;
int __init matroxfb_init(void)
{
+ char *option = NULL;
+
DBG(__FUNCTION__)
- matroxfb_setup(fb_get_options("matroxfb"));
+ if (fb_get_options("matroxfb", &option))
+ return -ENODEV;
+ matroxfb_setup(option);
if (disabled)
return -ENXIO;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/matrox/matroxfb_crtc2.c linux-2.6.9-rc1-mm5/drivers/video/matrox/matroxfb_crtc2.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/matrox/matroxfb_crtc2.c 2004-09-08 12:44:12.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/matrox/matroxfb_crtc2.c 2004-09-13 22:52:52.455289616 +0800
@@ -721,6 +721,9 @@ static struct matroxfb_driver crtc2 = {
.remove = matroxfb_crtc2_remove };
static int matroxfb_crtc2_init(void) {
+ if (fb_get_options("matrox_crtc2fb", NULL))
+ return -ENODEV;
+
matroxfb_register_driver(&crtc2);
return 0;
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/maxinefb.c linux-2.6.9-rc1-mm5/drivers/video/maxinefb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/maxinefb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/maxinefb.c 2004-09-13 22:52:52.456289464 +0800
@@ -126,6 +126,9 @@ int __init maxinefb_init(void)
unsigned long fb_start;
int i;
+ if (fb_get_options("maxinefb", NULL))
+ return -ENODEV;
+
/* Validate we're on the proper machine type */
if (mips_machtype != MACH_DS5000_XX) {
return -EINVAL;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/neofb.c linux-2.6.9-rc1-mm5/drivers/video/neofb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/neofb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/neofb.c 2004-09-13 22:52:52.459289008 +0800
@@ -2268,7 +2268,11 @@ int __init neofb_setup(char *options)
int __init neofb_init(void)
{
#ifndef MODULE
- neofb_setup(fb_get_options("neofb"));
+ char *option = NULL;
+
+ if (fb_get_options("neofb", &option))
+ return -ENODEV;
+ neofb_setup(option);
#endif
return pci_register_driver(&neofb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/offb.c linux-2.6.9-rc1-mm5/drivers/video/offb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/offb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/offb.c 2004-09-13 22:52:52.460288856 +0800
@@ -247,10 +247,15 @@ int __init offb_init(void)
{
struct device_node *dp;
unsigned int dpy;
+ char *option = NULL;
#if defined(CONFIG_BOOTX_TEXT) && defined(CONFIG_PPC32)
struct device_node *displays = find_type_devices("display");
struct device_node *macos_display = NULL;
+#endif
+ if (fb_get_options("offb", NULL))
+ return -ENODEV;
+#if defined(CONFIG_BOOTX_TEXT) && defined(CONFIG_PPC32)
/* If we're booted from BootX... */
if (prom_num_displays == 0 && boot_infos != 0) {
unsigned long addr =
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/p9100.c linux-2.6.9-rc1-mm5/drivers/video/p9100.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/p9100.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/p9100.c 2004-09-13 22:52:52.461288704 +0800
@@ -340,6 +340,9 @@ int __init p9100_init(void)
struct sbus_bus *sbus;
struct sbus_dev *sdev;
+ if (fb_get_options("p9100fb", NULL))
+ return -ENODEV;
+
for_all_sbusdev(sdev, sbus) {
if (!strcmp(sdev->prom_name, "p9100"))
p9100_init_one(sdev);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/platinumfb.c linux-2.6.9-rc1-mm5/drivers/video/platinumfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/platinumfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/platinumfb.c 2004-09-13 22:52:52.462288552 +0800
@@ -668,7 +668,11 @@ static struct of_platform_driver platinu
int __init platinumfb_init(void)
{
#ifndef MODULE
- platinumfb_setup(fb_get_options("platinumfb"));
+ char *option = NULL;
+
+ if (fb_get_options("platinumfb", &option))
+ return -ENODEV;
+ platinumfb_setup(option);
#endif
of_register_driver(&platinum_driver);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/pm2fb.c linux-2.6.9-rc1-mm5/drivers/video/pm2fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/pm2fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/pm2fb.c 2004-09-13 22:52:52.464288248 +0800
@@ -1220,7 +1220,11 @@ int __init pm2fb_setup(char *options);
int __init pm2fb_init(void)
{
#ifndef MODULE
- pm2fb_setup(fb_get_options("pm2fb"));
+ char *option = NULL;
+
+ if (fb_get_options("pm2fb", &option))
+ return -ENODEV;
+ pm2fb_setup(option);
#endif
return pci_module_init(&pm2fb_driver);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/pmag-ba-fb.c linux-2.6.9-rc1-mm5/drivers/video/pmag-ba-fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/pmag-ba-fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/pmag-ba-fb.c 2004-09-13 22:52:52.465288096 +0800
@@ -160,6 +160,9 @@ int __init pmagbafb_init(void)
int sid;
int found = 0;
+ if (fb_get_options("pmagbafb", NULL))
+ return -ENODEV;
+
if (TURBOCHANNEL) {
while ((sid = search_tc_card("PMAG-BA")) >= 0) {
found = 1;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/pmagb-b-fb.c linux-2.6.9-rc1-mm5/drivers/video/pmagb-b-fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/pmagb-b-fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/pmagb-b-fb.c 2004-09-13 22:52:52.465288096 +0800
@@ -163,6 +163,9 @@ int __init pmagbbfb_init(void)
int sid;
int found = 0;
+ if (fb_get_options("pmagbbfb", NULL))
+ return -ENODEV;
+
if (TURBOCHANNEL) {
while ((sid = search_tc_card("PMAGB-BA")) >= 0) {
found = 1;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/pvr2fb.c linux-2.6.9-rc1-mm5/drivers/video/pvr2fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/pvr2fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/pvr2fb.c 2004-09-13 22:52:52.467287792 +0800
@@ -1059,7 +1059,11 @@ int __init pvr2fb_init(void)
int size;
#ifndef MODULE
- pvr2fb_setup(fb_get_options("pvr2fb"));
+ char *option = NULL;
+
+ if (fb_get_options("pvr2fb", &option))
+ return -ENODEV;
+ pvr2fb_setup(option);
#endif
size = sizeof(struct fb_info) + sizeof(struct pvr2fb_par) + 16 * sizeof(u32);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/pxafb.c linux-2.6.9-rc1-mm5/drivers/video/pxafb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/pxafb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/pxafb.c 2004-09-13 22:52:52.469287488 +0800
@@ -1377,7 +1377,11 @@ MODULE_PARM_DESC(options, "LCD parameter
int __devinit pxafb_init(void)
{
#ifndef MODULE
- pxafb_setup(fb_get_options("pxafb"));
+ char *option = NULL;
+
+ if (fb_get_options("pxafb", &option))
+ return -ENODEV;
+ pxafb_setup(option);
#endif
return driver_register(&pxafb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/q40fb.c linux-2.6.9-rc1-mm5/drivers/video/q40fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/q40fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/q40fb.c 2004-09-13 22:52:52.470287336 +0800
@@ -143,6 +143,9 @@ int __init q40fb_init(void)
{
int ret = 0;
+ if (fb_get_options("q40fb", NULL))
+ return -ENODEV;
+
ret = driver_register(&q40fb_driver);
if (!ret) {
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/radeonfb.c linux-2.6.9-rc1-mm5/drivers/video/radeonfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/radeonfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/radeonfb.c 2004-09-13 22:52:52.473286880 +0800
@@ -3137,7 +3137,11 @@ int __init radeonfb_old_setup (char *opt
int __init radeonfb_old_init (void)
{
#ifndef MODULE
- radeonfb_old_setup(fb_get_options("radeonfb_old"));
+ char *option = NULL;
+
+ if (fb_get_options("radeonfb_old", &option))
+ return -ENODEV;
+ radeonfb_old_setup(option);
#endif
return pci_module_init (&radeonfb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/riva/fbdev.c linux-2.6.9-rc1-mm5/drivers/video/riva/fbdev.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/riva/fbdev.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/riva/fbdev.c 2004-09-13 22:52:52.475286576 +0800
@@ -2133,7 +2133,11 @@ static struct pci_driver rivafb_driver =
int __devinit rivafb_init(void)
{
#ifndef MODULE
- rivafb_setup(fb_get_options("rivafb"));
+ char *option = NULL;
+
+ if (fb_get_options("rivafb", &option))
+ return -ENODEV;
+ rivafb_setup(option);
#endif
if (pci_register_driver(&rivafb_driver) > 0)
return 0;
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/sa1100fb.c linux-2.6.9-rc1-mm5/drivers/video/sa1100fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/sa1100fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/sa1100fb.c 2004-09-13 22:52:52.478286120 +0800
@@ -1804,6 +1804,9 @@ static struct device_driver sa1100fb_dri
int __init sa1100fb_init(void)
{
+ if (fb_get_options("sa1100fb", NULL))
+ return -ENODEV;
+
return driver_register(&sa1100fb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/sgivwfb.c linux-2.6.9-rc1-mm5/drivers/video/sgivwfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/sgivwfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/sgivwfb.c 2004-09-13 22:52:52.479285968 +0800
@@ -870,7 +870,11 @@ int __init sgivwfb_init(void)
int ret;
#ifndef MODULE
- sgivwfb_setup(fb_get_options("sgivwfb"));
+ char *option = NULL;
+
+ if (fb_get_options("sgivwfb", &option))
+ return -ENODEV;
+ sgivwfb_setup(option);
#endif
ret = driver_register(&sgivwfb_driver);
if (!ret) {
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/sis/sis_main.c linux-2.6.9-rc1-mm5/drivers/video/sis/sis_main.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/sis/sis_main.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/sis/sis_main.c 2004-09-13 22:52:52.487284752 +0800
@@ -5720,7 +5720,11 @@ int __init sisfb_init(void)
{
#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,8)
#ifndef MODULE
- sisfb_setup(fb_get_options("sisfb"));
+ char *option = NULL;
+
+ if (fb_get_options("sisfb", &option))
+ return -ENODEV;
+ sisfb_setup(option);
#endif
#endif
return(pci_module_init(&sisfb_driver));
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/skeletonfb.c linux-2.6.9-rc1-mm5/drivers/video/skeletonfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/skeletonfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/skeletonfb.c 2004-09-13 22:52:52.488284600 +0800
@@ -586,7 +586,11 @@ static void __exit xxxfb_cleanup(void)
* For kernel boot options (in 'video=xxxfb:<options>' format)
*/
#ifndef MODULE
- xxxfb_setup(fb_get_options("xxxfb"));
+ char *option = NULL;
+
+ if (fb_get_options("xxxfb", &option))
+ return -ENODEV;
+ xxxfb_setup(option);
#endif
/*
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/sstfb.c linux-2.6.9-rc1-mm5/drivers/video/sstfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/sstfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/sstfb.c 2004-09-13 22:52:52.490284296 +0800
@@ -1573,7 +1573,11 @@ static struct pci_driver sstfb_driver =
int __devinit sstfb_init(void)
{
#ifndef MODULE
- sstfb_setup(fb_get_options("sstfb"));
+ char *option = NULL;
+
+ if (fb_get_options("sstfb", &option))
+ return -ENODEV;
+ sstfb_setup(option);
#endif
return pci_module_init(&sstfb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/stifb.c linux-2.6.9-rc1-mm5/drivers/video/stifb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/stifb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/stifb.c 2004-09-13 22:52:52.492283992 +0800
@@ -1386,7 +1386,11 @@ stifb_init(void)
int i;
#ifndef MODULE
- stifb_setup(fb_get_options("stifb"));
+ char *option = NULL;
+
+ if (fb_get_options("stifb", &option))
+ return -ENODEV;
+ stifb_setup(option);
#endif
if (stifb_disabled) {
printk(KERN_INFO "stifb: disabled by \"stifb=off\" kernel parameter\n");
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/tcx.c linux-2.6.9-rc1-mm5/drivers/video/tcx.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/tcx.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/tcx.c 2004-09-13 22:52:52.494283688 +0800
@@ -468,6 +468,9 @@ int __init tcx_init(void)
struct sbus_bus *sbus;
struct sbus_dev *sdev;
+ if (fb_get_options("tcxfb", NULL))
+ return -ENODEV;
+
for_all_sbusdev(sdev, sbus) {
if (!strcmp(sdev->prom_name, "tcx"))
tcx_init_one(sdev);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/tdfxfb.c linux-2.6.9-rc1-mm5/drivers/video/tdfxfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/tdfxfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/tdfxfb.c 2004-09-13 22:52:52.495283536 +0800
@@ -1359,7 +1359,12 @@ static void __devexit tdfxfb_remove(stru
int __init tdfxfb_init(void)
{
#ifndef MODULE
- tdfxfb_setup(fb_get_options("tdfxfb"));
+ char *option = NULL;
+
+ if (fb_get_options("tdfxfb", &option))
+ return -ENODEV;
+
+ tdfxfb_setup(option);
#endif
return pci_module_init(&tdfxfb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/tgafb.c linux-2.6.9-rc1-mm5/drivers/video/tgafb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/tgafb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/tgafb.c 2004-09-13 22:52:52.497283232 +0800
@@ -1528,7 +1528,11 @@ int __init
tgafb_init(void)
{
#ifndef MODULE
- tgafb_setup(fb_get_options("tgafb"));
+ char *option = NULL;
+
+ if (fb_get_options("tgafb", &option))
+ return -ENODEV;
+ tgafb_setup(option);
#endif
return pci_module_init(&tgafb_driver);
}
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/tridentfb.c linux-2.6.9-rc1-mm5/drivers/video/tridentfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/tridentfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/tridentfb.c 2004-09-13 22:52:52.499282928 +0800
@@ -1224,7 +1224,11 @@ int tridentfb_setup(char *options);
int __init tridentfb_init(void)
{
#ifndef MODULE
- tridentfb_setup(fb_get_options("tridentfb"));
+ char *option = NULL;
+
+ if (fb_get_options("tridentfb", &option))
+ return -ENODEV;
+ tridentfb_setup(option);
#endif
output("Trident framebuffer %s initializing\n", VERSION);
return pci_module_init(&tridentfb_pci_driver);
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/tx3912fb.c linux-2.6.9-rc1-mm5/drivers/video/tx3912fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/tx3912fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/tx3912fb.c 2004-09-13 22:52:52.500282776 +0800
@@ -217,8 +217,11 @@ int __init tx3912fb_init(void)
{
u_long tx3912fb_paddr = 0;
int size = (info->var.bits_per_pixel == 8) ? 256 : 16;
+ char *option = NULL;
- tx3912fb_setup(fb_get_options("tx3912fb"));
+ if (fb_get_options("tx3912fb", &option))
+ return -ENODEV;
+ tx3912fb_setup(option);
/* Disable the video logic */
outl(inl(TX3912_VIDEO_CTRL1) &
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/valkyriefb.c linux-2.6.9-rc1-mm5/drivers/video/valkyriefb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/valkyriefb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/valkyriefb.c 2004-09-13 22:52:52.501282624 +0800
@@ -322,8 +322,11 @@ int __init valkyriefb_init(void)
struct fb_info_valkyrie *p;
unsigned long frame_buffer_phys, cmap_regs_phys, flags;
int err;
+ char *option = NULL;
- valkyriefb_setup(fb_get_options("valkyriefb"));
+ if (fb_get_options("valkyriefb", &option))
+ return -ENODEV;
+ valkyriefb_setup(option);
#ifdef CONFIG_MAC
if (!MACH_IS_MAC)
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/vesafb.c linux-2.6.9-rc1-mm5/drivers/video/vesafb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/vesafb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/vesafb.c 2004-09-13 22:52:52.502282472 +0800
@@ -410,8 +410,11 @@ static struct platform_device vesafb_dev
int __init vesafb_init(void)
{
int ret;
+ char *option = NULL;
- vesafb_setup(fb_get_options("vesafb"));
+ /* ignore error return of fb_get_options */
+ fb_get_options("vesafb", &option);
+ vesafb_setup(option);
ret = driver_register(&vesafb_driver);
if (!ret) {
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/vfb.c linux-2.6.9-rc1-mm5/drivers/video/vfb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/vfb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/vfb.c 2004-09-13 22:52:52.503282320 +0800
@@ -497,7 +497,11 @@ int __init vfb_init(void)
int ret = 0;
#ifndef MODULE
- vfb_setup(fb_get_options("vfb"));
+ char *option = NULL;
+
+ if (fb_get_options("vfb", &option))
+ return -ENODEV;
+ vfb_setup(option);
#endif
if (!vfb_enable)
diff -uprN linux-2.6.9-rc1-mm5-orig/drivers/video/vga16fb.c linux-2.6.9-rc1-mm5/drivers/video/vga16fb.c
--- linux-2.6.9-rc1-mm5-orig/drivers/video/vga16fb.c 2004-09-13 19:50:17.000000000 +0800
+++ linux-2.6.9-rc1-mm5/drivers/video/vga16fb.c 2004-09-13 22:52:52.505282016 +0800
@@ -1342,9 +1342,13 @@ int __init vga16fb_init(void)
{
int i;
int ret;
-
#ifndef MODULE
- vga16fb_setup(fb_get_options("vga16fb"));
+ char *option = NULL;
+
+ if (fb_get_options("vga16fb", &option))
+ return -ENODEV;
+
+ vga16fb_setup(option);
#endif
printk(KERN_DEBUG "vga16fb: initializing\n");
diff -uprN linux-2.6.9-rc1-mm5-orig/include/linux/fb.h linux-2.6.9-rc1-mm5/include/linux/fb.h
--- linux-2.6.9-rc1-mm5-orig/include/linux/fb.h 2004-09-13 19:50:23.000000000 +0800
+++ linux-2.6.9-rc1-mm5/include/linux/fb.h 2004-09-13 22:52:52.507281712 +0800
@@ -790,7 +790,7 @@ extern void fb_sysmove_buf_aligned(struc
extern void fb_load_cursor_image(struct fb_info *);
extern void fb_set_suspend(struct fb_info *info, int state);
extern int fb_get_color_depth(struct fb_info *info);
-extern char* fb_get_options(char *name);
+extern int fb_get_options(char *name, char **option);
extern struct fb_info *registered_fb[FB_MAX];
extern int num_registered_fb;
-------------------------------------------------------
This SF.Net email is sponsored by: YOU BE THE JUDGE. Be one of 170
Project Admins to receive an Apple iPod Mini FREE for your judgement on
who ports your project to Linux PPC the best. Sponsored by IBM.
Deadline: Sept. 13. Go here: http://sf.net/ppc_contest.php
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2004-09-13 15:18 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-09-13 15:18 [PATCH 1/3 RESEND] fbcon: fix fbcon's setup routine Antonino A. Daplas
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).