mtd: rawnand: nandsim: Fix the two ns_alloc_device() error paths
authorMiquel Raynal <miquel.raynal@bootlin.com>
Mon, 25 May 2020 08:58:41 +0000 (10:58 +0200)
committerMiquel Raynal <miquel.raynal@bootlin.com>
Sun, 31 May 2020 08:53:38 +0000 (10:53 +0200)
commit058018eb0202d144ae266e0497082366bfd6afff
treee2b66a68119bbb58b07fa8a0f749b0bb89fcdcb9
parentcde495f83959119d0d2c78e74118a61301b8af32
mtd: rawnand: nandsim: Fix the two ns_alloc_device() error paths

The ns_alloc_device() helper has actually two distinct path. Handle
errors in both of them.

Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20200525085851.17682-8-miquel.raynal@bootlin.com
drivers/mtd/nand/raw/nandsim.c