diff options
author | Boris Brezillon <boris.brezillon@bootlin.com> | 2018-09-06 14:05:28 +0200 |
---|---|---|
committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2018-10-03 11:12:25 +0200 |
commit | 5295cf2e047cf60ac1e14d4789cdf698af45cf2f (patch) | |
tree | 0deb317768774cf760ab693b500e8d8f185bfb66 /drivers/mtd/nand/raw/au1550nd.c | |
parent | 50a487e7719caa07e951dfcfd983b2c5517e2f76 (diff) | |
download | linux-stable-5295cf2e047cf60ac1e14d4789cdf698af45cf2f.tar.gz linux-stable-5295cf2e047cf60ac1e14d4789cdf698af45cf2f.tar.bz2 linux-stable-5295cf2e047cf60ac1e14d4789cdf698af45cf2f.zip |
mtd: rawnand: Pass a nand_chip object to chip->cmdfunc()
Let's make the raw NAND API consistent by patching all helpers and
hooks to take a nand_chip object instead of an mtd_info one or
remove the mtd_info object when both are passed.
Let's tackle the chip->cmdfunc() hook.
Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Diffstat (limited to 'drivers/mtd/nand/raw/au1550nd.c')
-rw-r--r-- | drivers/mtd/nand/raw/au1550nd.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/mtd/nand/raw/au1550nd.c b/drivers/mtd/nand/raw/au1550nd.c index 1f0fba8d87c6..d0ec8606e769 100644 --- a/drivers/mtd/nand/raw/au1550nd.c +++ b/drivers/mtd/nand/raw/au1550nd.c @@ -236,14 +236,15 @@ static void au1550_select_chip(struct nand_chip *this, int chip) /** * au1550_command - Send command to NAND device - * @mtd: MTD device structure + * @this: NAND chip object * @command: the command to be sent * @column: the column address for this command, -1 if none * @page_addr: the page address for this command, -1 if none */ -static void au1550_command(struct mtd_info *mtd, unsigned command, int column, int page_addr) +static void au1550_command(struct nand_chip *this, unsigned command, + int column, int page_addr) { - struct nand_chip *this = mtd_to_nand(mtd); + struct mtd_info *mtd = nand_to_mtd(this); struct au1550nd_ctx *ctx = container_of(this, struct au1550nd_ctx, chip); int ce_override = 0, i; |