mtd: nand: tmio: return error code of nand_scan() on error
authorMasahiro Yamada <yamada.masahiro@socionext.com>
Fri, 4 Nov 2016 10:42:54 +0000 (19:42 +0900)
committerBoris Brezillon <boris.brezillon@free-electrons.com>
Mon, 7 Nov 2016 13:48:44 +0000 (14:48 +0100)
commit43358c173d02446b9f8da25fb0de8cfc22eb1ae6
treeeabe8f7986bca473b6f47d5230216bcd7958c1aa
parentbbd4d03c56083069cf0808681bd301cf31701fbd
mtd: nand: tmio: 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 -ENODEV.

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/tmio_nand.c