mtd: spi-nor: Stop passing flash_info around
authorBoris Brezillon <boris.brezillon@bootlin.com>
Thu, 6 Dec 2018 10:41:18 +0000 (11:41 +0100)
committerBoris Brezillon <boris.brezillon@bootlin.com>
Mon, 10 Dec 2018 20:59:08 +0000 (21:59 +0100)
commitb296379fef7ce9f96129798825ab04683414313b
treef1c13a374d7df7b7890b8f210442e44f1addc162
parentf10aa369d5c2ccfc734e158c0a802009953e8c68
mtd: spi-nor: Stop passing flash_info around

Some functions called from spi_nor_scan() need a flash_info object.
Let's assign nor->info early on to avoid passing info as an extra
argument to each of these sub-functions.

We also stop passing a flash_info object to set_4byte() and use
nor->info directly.

Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Reviewed-by: Tudor Ambarus <tudor.ambarus@microchip.com>
drivers/mtd/spi-nor/spi-nor.c