OSDN Git Service

mtd: nand: fsmc: reduce number of arguments of fsmc_nand_setup()
authorThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Sat, 29 Apr 2017 08:52:34 +0000 (10:52 +0200)
committerBoris Brezillon <boris.brezillon@free-electrons.com>
Mon, 15 May 2017 11:11:48 +0000 (13:11 +0200)
commit6335b509b2b6fbe4cbeaef739434b40b8018df82
treebe46840dd72f51a45e6809c8087d25326e39353d
parent19d8ccc42b148d75284a3809f1eb1eba13a81677
mtd: nand: fsmc: reduce number of arguments of fsmc_nand_setup()

In preparation for the introduction of support for using SDR timings
exposed by the NAND flash instead of hard-coded timings, this commit
reworks the fsmc_nand_setup() function to take a "struct fsmc_nand_data"
as argument, which already contains the I/O registers base address, bank
and bus width information.

The timings is also currently contained in the "struct fsmc_nand_data",
but we still pass it as a separate argument because the support for
using SDR timings will pass a different value.

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
drivers/mtd/nand/fsmc_nand.c