]> bbs.cooldavid.org Git - net-next-2.6.git/commitdiff
mtd: sh_flctl: register sh_flctl using platform_driver_probe()
authorDavid Woodhouse <David.Woodhouse@intel.com>
Sat, 19 Sep 2009 23:07:34 +0000 (16:07 -0700)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Sat, 19 Sep 2009 23:07:34 +0000 (16:07 -0700)
As with orion_nand in commit f33dabbe79fdf7a8568c65faa1db7794c87ac4d3
("register orion_nand using platform_driver_probe()"), avoid .init.text
problems by using platform_device_probe(). This isn't going to be
hotplugged anyway.

Reported-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/mtd/nand/sh_flctl.c

index c5df28596a4aa6c2b3c567e0d5649be87520ea59..02bef21f2e4b987099a8f1f8d856c7364cbf9a58 100644 (file)
@@ -857,7 +857,6 @@ static int __exit flctl_remove(struct platform_device *pdev)
 }
 
 static struct platform_driver flctl_driver = {
-       .probe          = flctl_probe,
        .remove         = flctl_remove,
        .driver = {
                .name   = "sh_flctl",
@@ -867,7 +866,7 @@ static struct platform_driver flctl_driver = {
 
 static int __init flctl_nand_init(void)
 {
-       return platform_driver_register(&flctl_driver);
+       return platform_driver_probe(&flctl_driver, flctl_probe);
 }
 
 static void __exit flctl_nand_cleanup(void)