mtd: nand: gpio: return error code of nand_scan() on error
authorMasahiro Yamada <yamada.masahiro@socionext.com>
Fri, 4 Nov 2016 10:42:52 +0000 (19:42 +0900)
committerBoris Brezillon <boris.brezillon@free-electrons.com>
Mon, 7 Nov 2016 13:48:43 +0000 (14:48 +0100)
commit408bf51e92752d084d82d21e2c1f838d0ecc5eea
treeb7fef362bcf53109b1b1e7e327494ab0bd1a0cf3
parent29453ba40bb5e91dcaa9b571208da1c1e75e63f1
mtd: nand: gpio: return error code of nand_scan() on error

The nand_scan() returns an appropriate error value when it fails.
Use it instead of the fixed error code -ENXIO.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
drivers/mtd/nand/gpio.c