diff options
author | Martin Kaiser <martin@kaiser.cx> | 2018-06-27 23:47:44 +0300 |
---|---|---|
committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2018-07-18 10:24:13 +0300 |
commit | 24f0ae995deb728076e3ea93fea1949a9775debf (patch) | |
tree | 28a03d5afa3a8a684c07f82e8841b24976abcfd1 /drivers/mtd/nand/raw/mxc_nand.c | |
parent | 3dfa025f890c4568adc9ba06ecc0da35718f4799 (diff) | |
download | linux-24f0ae995deb728076e3ea93fea1949a9775debf.tar.xz |
mtd: rawnand: mxc: remove __init qualifier from mxcnd_probe_dt
Using the sysfs unbind, bind nodes, mxcnd_probe and mxcnd_probe_dt can
potentially be called at any time. After the __init functions are cleaned,
mxcnd_probe_dt is no longer available. Calling it anyway causes a crash.
mxcnd_probe used to be marked as __init, this was removed years ago.
Remove the __init qualifier from from mxcnd_probe_dt as well.
Fixes: 06f255106923 ("mtd: remove use of __devinit")
Signed-off-by: Martin Kaiser <martin@kaiser.cx>
Reviewed-by: Boris Brezillon <boris.brezillon@bootlin.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Diffstat (limited to 'drivers/mtd/nand/raw/mxc_nand.c')
-rw-r--r-- | drivers/mtd/nand/raw/mxc_nand.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mtd/nand/raw/mxc_nand.c b/drivers/mtd/nand/raw/mxc_nand.c index 26cef218bb43..90cfb5e730aa 100644 --- a/drivers/mtd/nand/raw/mxc_nand.c +++ b/drivers/mtd/nand/raw/mxc_nand.c @@ -1686,7 +1686,7 @@ static const struct of_device_id mxcnd_dt_ids[] = { }; MODULE_DEVICE_TABLE(of, mxcnd_dt_ids); -static int __init mxcnd_probe_dt(struct mxc_nand_host *host) +static int mxcnd_probe_dt(struct mxc_nand_host *host) { struct device_node *np = host->dev->of_node; const struct of_device_id *of_id = @@ -1700,7 +1700,7 @@ static int __init mxcnd_probe_dt(struct mxc_nand_host *host) return 0; } #else -static int __init mxcnd_probe_dt(struct mxc_nand_host *host) +static int mxcnd_probe_dt(struct mxc_nand_host *host) { return 1; } |