Эх сурвалжийг харах

drivers/video/s1d13xxxfb.c: fix build as module with dbg

Attached patch fixes two compilation problems of s1d13xxxfb.c:

- Fixes outdated dbg() message to fix compilation error with debugging enabled.

- Do not read kernel command line options when compiled as module.

Signed-off-by: Stanislav Brabec <utx@penguin.cz>
Cc: "Antonino A. Daplas" <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Stanislav Brabec 17 жил өмнө
parent
commit
28822f22e1

+ 4 - 1
drivers/video/s1d13xxxfb.c

@@ -540,7 +540,7 @@ s1d13xxxfb_probe(struct platform_device *pdev)
 	int ret = 0;
 	int ret = 0;
 	u8 revision;
 	u8 revision;
 
 
-	dbg("probe called: device is %p\n", dev);
+	dbg("probe called: device is %p\n", pdev);
 
 
 	printk(KERN_INFO "Epson S1D13XXX FB Driver\n");
 	printk(KERN_INFO "Epson S1D13XXX FB Driver\n");
 
 
@@ -753,8 +753,11 @@ static struct platform_driver s1d13xxxfb_driver = {
 static int __init
 static int __init
 s1d13xxxfb_init(void)
 s1d13xxxfb_init(void)
 {
 {
+
+#ifndef MODULE
 	if (fb_get_options("s1d13xxxfb", NULL))
 	if (fb_get_options("s1d13xxxfb", NULL))
 		return -ENODEV;
 		return -ENODEV;
+#endif
 
 
 	return platform_driver_register(&s1d13xxxfb_driver);
 	return platform_driver_register(&s1d13xxxfb_driver);
 }
 }