brcm47xx: add initial support for kernel 3.8
[openwrt/svn-archive/archive.git] / target / linux / brcm47xx / patches-3.8 / 042-mtd-bcm47xxnflash-register-this-as-normal-driver.patch
1 --- a/drivers/mtd/nand/bcm47xxnflash/main.c
2 +++ b/drivers/mtd/nand/bcm47xxnflash/main.c
3 @@ -77,6 +77,7 @@ static int bcm47xxnflash_remove(struct p
4 }
5
6 static struct platform_driver bcm47xxnflash_driver = {
7 + .probe = bcm47xxnflash_probe,
8 .remove = bcm47xxnflash_remove,
9 .driver = {
10 .name = "bcma_nflash",
11 @@ -88,11 +89,7 @@ static int __init bcm47xxnflash_init(voi
12 {
13 int err;
14
15 - /*
16 - * Platform device "bcma_nflash" exists on SoCs and is registered very
17 - * early, it won't be added during runtime (use platform_driver_probe).
18 - */
19 - err = platform_driver_probe(&bcm47xxnflash_driver, bcm47xxnflash_probe);
20 + err = platform_driver_register(&bcm47xxnflash_driver);
21 if (err)
22 pr_err("Failed to register bcm47xx nand flash driver: %d\n",
23 err);