diff options
author | Boris Brezillon <boris.brezillon@free-electrons.com> | 2018-08-16 17:29:59 +0200 |
---|---|---|
committer | Jagan Teki <jagan@amarulasolutions.com> | 2018-09-20 20:10:49 +0530 |
commit | 596cf083da34c2007f8ec760c8b077f6f28ee655 (patch) | |
tree | 708e52652249bde2ac7471cb8613eb2ff28e5d0a /drivers/mtd/onenand | |
parent | 9dc8d155d4e88563f572ee79aab758eb4272f3fd (diff) | |
download | u-boot-596cf083da34c2007f8ec760c8b077f6f28ee655.zip u-boot-596cf083da34c2007f8ec760c8b077f6f28ee655.tar.gz u-boot-596cf083da34c2007f8ec760c8b077f6f28ee655.tar.bz2 |
mtd: Fallback to ->_read/write_oob() when ->_read/write() is missing
Some MTD sublayers/drivers are implementing ->_read/write_oob() and
provide dummy wrappers for their ->_read/write() implementations.
Let the core handle this case instead of duplicating the logic.
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Acked-by: Robert Jarzmik <robert.jarzmik@free.fr>
Acked-by: Brian Norris <computersforpeace@gmail.com>
Reviewed-by: Miquel Raynal <miquel.raynal@free-electrons.com>
Tested-by: Ladislav Michl <ladis@linux-mips.org>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>
Diffstat (limited to 'drivers/mtd/onenand')
-rw-r--r-- | drivers/mtd/onenand/onenand_base.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/mtd/onenand/onenand_base.c b/drivers/mtd/onenand/onenand_base.c index 86b1640..371e2ec 100644 --- a/drivers/mtd/onenand/onenand_base.c +++ b/drivers/mtd/onenand/onenand_base.c @@ -2656,8 +2656,6 @@ int onenand_probe(struct mtd_info *mtd) mtd->flags = MTD_CAP_NANDFLASH; mtd->_erase = onenand_erase; - mtd->_read = onenand_read; - mtd->_write = onenand_write; mtd->_read_oob = onenand_read_oob; mtd->_write_oob = onenand_write_oob; mtd->_sync = onenand_sync; |