summaryrefslogtreecommitdiffstats
path: root/drivers/mtd
AgeCommit message (Collapse)AuthorFilesLines
2016-12-24Replace <asm/uaccess.h> with <linux/uaccess.h> globallyLinus Torvalds9-9/+9
This was entirely automated, using the script by Al: PATT='^[[:blank:]]*#[[:blank:]]*include[[:blank:]]*<asm/uaccess.h>' sed -i -e "s!$PATT!#include <linux/uaccess.h>!" \ $(git grep -l "$PATT"|grep -v ^include/linux/uaccess.h) to do the replacement at the end of the merge window. Requested-by: Al Viro <viro@zeniv.linux.org.uk> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2016-12-17Merge tag 'for-linus-20161216' of git://git.infradead.org/linux-mtdLinus Torvalds44-349/+1370
Pull MTD updates from Brian Norris: "Nothing enormous here, though notably we have some of the first work of a few new maintainers. I think for now I'll still be sending pull requests, but that's open to change in the future. Summary: Core: - dynamic BDI object allocation (resolves some problems when built as a module) - cleanups in the ooblayout handling NAND: - new tango NAND controller driver - new ox820 NAND controller driver - addition of a new full-ID entry in the nand_ids table - rework of the s3c240 driver to support DT - extension of the nand_sdr_timings to expose tCCS, tPROG and tR - addition of a new flag to ask the core to wait for tCCS when sending a RNDIN/RNDOUT command - addition of a new flag to ask the core to let the controller driver send the READ/PROGPAGE command Minor fixes/cleanup/cosmetic changes: - properly support 512 ECC step size in the sunxi driver - improve the error messages in the PXA probe path - fix module autoload in the omap2 driver - cleanup of several nand drivers to return nand_scan{_tail}() error code instead of returning -EIO - various cleanups in the denali driver - fix an error check in nandsim SPI NOR: - new flash IDs - wait for Spansion flash to be ready after quad-enable - error handling fixes for Candence QSPI - constify some structures in Freescale QSPI driver" * tag 'for-linus-20161216' of git://git.infradead.org/linux-mtd: (71 commits) mtd: Allocate bdi objects dynamically mtd: nand: tango: Add standard legalese header mtd: maps: add missing iounmap() in error path mtd: spi-nor: constify fsl_qspi_devtype_data mtd: spi-nor: Add support for mr25h40 mtd: spi-nor: Add support for N25Q016A mtd: spi-nor: Add at25df321 spi-nor flash support mtd: spi-nor: Fix some error codes in cqspi_setup_flash() mtd: spi-nor: Off by one in cqspi_setup_flash() mtd: spi-nor: add support for s25fl208k mtd: spi-nor: fix flags for s25fl128s mtd: spi-nor: fix spansion quad enable mtd: spi-nor: add Macronix mx25u25635f to list of known devices. mtd: mtdswap: fix spelling mistake "erassure" -> "erasure" mtd: bcm47xxpart: fix parsing first block after aligned TRX mtd: nand: tango: Use nand_to_mtd() instead of directly accessing chip->mtd mtd: remove unneeded initializer in mtd_ooblayout_count_bytes() mtd: use min_t() to refactor mtd_ooblayout_{get, set}_bytes() mtd: remove unneeded initializer in mtd_ooblayout_{get, set}_bytes() mtd: nand: nandsim: fix error check ...
2016-12-01mtd: Allocate bdi objects dynamicallySteve Longerbeam1-12/+18
The MTD backing dev info objects mtd_bdi was statically allocated. So when MTD is built as a loadable module, this object fall in the vmalloc address space. The problem with that, is that the BDI APIs use wake_up_bit(), which calls virt_to_page() to retrieve the memory zone of the page containing the wait_queue to wake up, and virt_to_page() is not valid for vmalloc or highmem addresses. Fix this by allocating the BDI objects dynamically with kmalloc. The objects now fall in the logical address space so that BDI APIs will work in all cases (mtd builtin or module). Signed-off-by: Steve Longerbeam <steve_longerbeam@mentor.com> Signed-off-by: Jim Baxter <jim_baxter@mentor.com> Signed-off-by: Sandeep Jain <Sandeep_Jain@mentor.com> Reviewed-by: Richard Weinberger <richard@nod.at> Reviewed-by: Marek Vasut <marek.vasut@gmail.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com>
2016-12-01mtd: nand: tango: Add standard legalese headerMarc Gonzalez1-0/+8
Provide proper copyright notice and license information. Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com>
2016-11-30mtd: maps: add missing iounmap() in error pathLuis Henriques1-1/+7
This patch was triggered by the following Coccinelle error: ./drivers/mtd/maps/sc520cdp.c:246:3-9: \ ERROR: missing iounmap; ioremap on line 242 \ and execution via conditional on line 244 Since do_map_probe() is also invoked in this loop, it is also necessary to map_destroy() any initialised struct mtd_info. Signed-off-by: Luis Henriques <henrix@camandro.org> Reviewed-by: Marek Vasut <marek.vasut@gmail.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com>
2016-11-29Merge tag 'spi-nor/for-4.10' of git://github.com/spi-nor/linuxBrian Norris3-7/+21
From Cyrille Pitchen: """ This pull request contains the following notable changes: - add support to new memory parts. - fix of spansion_quad_enable(). - fix of the Candence QSPI driver. - constify some structure instances of the Freescale QSPI driver. """
2016-11-29Merge tag 'nand/for-4.10' of github.com:linux-nand/linuxBrian Norris37-317/+1292
From Boris Brezillon: """ This pull request contains the following notable changes: - new tango NAND controller driver - new ox820 NAND controller driver - addition of a new full-ID entry in the nand_ids table - rework of the s3c240 driver to support DT - extension of the nand_sdr_timings to expose tCCS, tPROG and tR - addition of a new flag to ask the core to wait for tCCS when sending a RNDIN/RNDOUT command - addition of a new flag to ask the core to let the controller driver send the READ/PROGPAGE command This pull request also contains minor fixes/cleanup/cosmetic changes: - properly support 512 ECC step size in the sunxi driver - improve the error messages in the pxa probe path - fix module autoload in the omap2 driver - cleanup of several nand drivers to return nand_scan{_tail}() error code instead of returning -EIO - various cleanups in the denali driver - cleanups in the ooblayout handling (MTD core) - fix an error check in nandsim """
2016-11-26mtd: spi-nor: constify fsl_qspi_devtype_dataLABBE Corentin1-4/+4
All fsl_qspi_devtype_data structures are never modified. This patch constify them. Signed-off-by: LABBE Corentin <clabbe.montjoie@gmail.com> Acked-by: Han Xu <han.xu@nxp.com> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-26mtd: spi-nor: Add support for mr25h40IWAMOTO Masahiko1-0/+1
Add Everspin mr25h40 512KB MRAM to the list of supported chips. Signed-off-by: Masahiko Iwamoto <iwamoto@allied-telesis.co.jp> Reviewed-by: Jagan Teki <jagan@openedev.com> Acked-by: Marek Vasut <marex@denx.de> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-26mtd: spi-nor: Add support for N25Q016AMoritz Fischer1-0/+1
This commit adds support in the spi-nor driver for the N25Q016A, a 16Mbit SPI NOR flash from Micron. Cc: David Woodhouse <dwmw2@infradead.org> Cc: Brian Norris <computersforpeace@gmail.com> Cc: Jagan Teki <jteki@openedev.com> Signed-off-by: Moritz Fischer <moritz.fischer@ettus.com> Reviewed-by: Jagan Teki <jteki@openedev.com> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-26mtd: spi-nor: Add at25df321 spi-nor flash supportJagan Teki1-0/+1
Add Atmel at25df321 spi-nor flash to the list of spi_nor_ids. Cc: Brian Norris <computersforpeace@gmail.com> Cc: Wenyou Yang <wenyou.yang@atmel.com> Signed-off-by: Jagan Teki <jteki@openedev.com> Acked-by: Wenyou Yang <wenyou.yang@atmel.com> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-26mtd: spi-nor: Fix some error codes in cqspi_setup_flash()Dan Carpenter1-1/+3
We return success or possibly uninitialized values on these error paths instead of proper error codes. Fixes: 140623410536 ("mtd: spi-nor: Add driver for Cadence Quad SPI Flash Controller") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Marek Vasut <marex@denx.de> Reviewed-by: Moritz Fischer <moritz.fischer@ettus.com> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-26mtd: spi-nor: Off by one in cqspi_setup_flash()Dan Carpenter1-1/+1
There are CQSPI_MAX_CHIPSELECT elements in the ->f_pdata array so the > should be >=. Fixes: 140623410536 ('mtd: spi-nor: Add driver for Cadence Quad SPI Flash Controller') Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Marek Vasut <marex@denx.de> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-26mtd: spi-nor: add support for s25fl208kSean Nyekjaer1-0/+1
Signed-off-by: Sean Nyekjaer <sean.nyekjaer@prevas.dk> Reviewed-by: Jagan Teki <jagan@openedev.com> Acked-by: Marek Vasut <marex@denx.de> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-26mtd: spi-nor: fix flags for s25fl128sHeiner Kallweit1-1/+1
The Spansion S25FL128S also supports dual read mode. In addition remove flag SECT_4K. 4K erases are supported, but not uniformly. Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> Reviewed-by: Jagan Teki <jteki@openedev.com> Acked-by: Marek Vasut <marek.vasut@gmail.com> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-23mtd: spi-nor: fix spansion quad enableJoël Esponde1-0/+7
With the S25FL127S nor flash part, each writing to the configuration register takes hundreds of ms. During that time, no more accesses to the flash should be done (even reads). This commit adds a wait loop after the register writing until the flash finishes its work. This issue could make rootfs mounting fail when the latter was done too much closely to this quad enable bit setting step. And in this case, a driver as UBIFS may try to recover the filesystem and may broke it completely. Signed-off-by: Joël Esponde <joel.esponde@honeywell.com> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-23mtd: spi-nor: add Macronix mx25u25635f to list of known devices.Ash Benz1-0/+1
Signed-off-by: Ash Benz <ash.benz@bk.ru> Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
2016-11-22mtd: mtdswap: fix spelling mistake "erassure" -> "erasure"Colin Ian King1-1/+1
Trivial fix to spelling mistake in dev_err message Signed-off-by: Colin Ian King <colin.king@canonical.com> [Brian: add EOL newline] Signed-off-by: Brian Norris <computersforpeace@gmail.com>
2016-11-22mtd: bcm47xxpart: fix parsing first block after aligned TRXRafał Miłecki1-6/+4
After parsing TRX we should skip to the first block placed behind it. Our code was working only with TRX with length not aligned to the blocksize. In other cases (length aligned) it was missing the block places right after TRX. This fixes calculation and simplifies the comment. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> Signed-off-by: Brian Norris <computersforpeace@gmail.com>
2016-11-21mtd: nand: tango: Use nand_to_mtd() instead of directly accessing chip->mtdBoris Brezillon1-9/+16
The nand_to_mtd() helper is here to hide internal mtd_info <-> nand_chip association and ease future refactors. Make use of this helper instead of directly accessing chip->mtd. Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com> Acked-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com>
2016-11-19mtd: remove unneeded initializer in mtd_ooblayout_count_bytes()Masahiro Yamada1-1/+1
There is no need to initialize oobregion since it will be filled by the iterator. This function is called with mtd_ooblayout_free or mtd_ooblayout_ecc for the iterator; both of them calls memset() to clear the oobregion. 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>
2016-11-19mtd: use min_t() to refactor mtd_ooblayout_{get, set}_bytes()Masahiro Yamada1-2/+2
I hope this will make the code a little more readable. 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>
2016-11-19mtd: remove unneeded initializer in mtd_ooblayout_{get, set}_bytes()Masahiro Yamada1-4/+4
There is no need to initialize oobregion and section since they will be filled by mtd_ooblayout_find_region(). 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>
2016-11-19mtd: nand: nandsim: fix error checkSudip Mukherjee1-10/+5
debugfs_create_dir() and debugfs_create_file() returns NULL on error or a pointer on success. They do not return the error value with ERR_PTR. So we should not check the return with IS_ERR_OR_NULL, instead we should just check for NULL. Signed-off-by: Sudip Mukherjee <sudip.mukherjee@codethink.co.uk> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
2016-11-19mtd: nand: tango: Cleanup raw_write and raw_readMarc Gonzalez1-8/+6
Drop raw_write return value (no longer used). Drop raw_read return value (for symmetry). Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
2016-11-19mtd: nand: tango: Enable custom page accessorsMarc Gonzalez1-1/+6
Enable NAND_ECC_CUSTOM_PAGE_ACCESS in the tango NFC driver. Fixup the "raw" page accessors to send the proper NAND commands. Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
2016-11-19mtd: nand: Support controllers with custom pageMarc Gonzalez1-3/+31
If your controller already sends the required NAND commands when reading or writing a page, then the framework is not supposed to send READ0 and SEQIN/PAGEPROG respectively. Signed-off-by: Marc Gonzalez <marc_gonzalez@sigmadesigns.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
2016-11-19mtd: nand: denali: remove debug lines of __FILE__, __LINE__, __func__Masahiro Yamada1-12/+0
Such debug lines might be useful when debugging the driver first, but should be deleted from the upstream code. 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>
2016-11-19mtd: nand: denali: remove unneeded parenthesesMasahiro Yamada1-7/+7
Remove parentheses surrounding the whole right side of an assignment. 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>
2016-11-19mtd: nand: denali: return error code from nand_scan_ident/tail on errorMasahiro Yamada1-6/+4
The nand_scan_ident/tail() returns an appropriate error value when it fails. Use it instead of the fixed -ENXIO. 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>
2016-11-19mtd: nand: denali: return error code from devm_request_irq() on errorMasahiro Yamada1-7/+5
The devm_request_irq() returns an appropriate error value when it fails. Use it instead of the fixed -ENODEV. While we are here, reword the comment to make it fit in a single line, fixing the misspelling of "initialization". 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>
2016-11-19mtd: nand: denali: use managed devm_irq_request()Masahiro Yamada1-3/+2
Use the managed variant instead of request_irq() and free_irq(). 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>
2016-11-19mtd: nand: denali: remove unused struct member totalblks, blksperchipMasahiro Yamada2-10/+0
The denali->blksperchip is set, but not referenced any more. The denali->totalblks is used only for calculating denali->blksperchip. Both of them are unneeded. 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>
2016-11-19mtd: nand: denali: remove "Spectra:" prefix from printk stringsMasahiro Yamada1-6/+5
As far as I understood from the Kconfig menu deleted by commit be7f39c5ecf5 ("Staging: delete spectra driver"), the "Spectra" is specific to Intel Moorestown Platform. The Denali NAND controller IP is used for various SoCs such as Altera SOCFPGA, Socionext UniPhier, etc. The platform specific strings are not preferred in this driver. 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>
2016-11-19mtd: nand: denali: remove detect_partition_feature()Masahiro Yamada2-38/+0
The denali->fwblks is set by detect_partition_feature(), but it is not referenced from anywhere. That means the struct member fwblks and the whole of detect_partition_feature() are unneeded. The comment block implies this function is only for Intel platforms. I found drivers/staging/spectra used to exist, but it was deleted by commit be7f39c5ecf5 ("Staging: delete spectra driver") 5 years ago. So, I guess nobody would need this function any more. 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>
2016-11-19mtd: nand: denali: remove bogus comment about interrupt handler setupMasahiro Yamada1-1/+0
The interrupt handler is setup in denali_init(), not in denali_drv_init(). This comment is false. Such a comment adds no value, so just delete it instead of move. 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>
2016-11-19mtd: nand: denali: remove unused struct member denali_nand_info::idxMasahiro Yamada2-3/+0
The struct member "idx" was used as an index for debug_array long ago, but the DEBUG_DENALI feature was removed by commit 7cfffac06ca0 ("nand/denali: use dev_xx debug function to replace nand_dbg_print and some printk"). Since then, this has been only initialized, but never referenced. 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>
2016-11-19mtd: nand: denali: remove unneeded <linux/slab.h> includesMasahiro Yamada3-3/+0
The driver calls devm_kzalloc()/devm_kfree() to allocate/free memory. They are declared in <linux/device.h>, not in <linux/slab.h>. 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>
2016-11-07mtd: bcm47xxsflash: use uncached MMIO access for BCM53573Rafał Miłecki1-5/+19
BCM53573 is a new series of Broadcom's SoCs. It's based on ARM and uses this old ChipCommon-based flash access. Early tests resulted in flash corruptions that were tracked down to using cached MMIO for flash read access. Switch to ioremap_nocache conditionally to support BCM53573 and don't break performance on old MIPS devices. Signed-off-by: Rafał Miłecki <rafal@milecki.pl> Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com> Signed-off-by: Brian Norris <computersforpeace@gmail.com>
2016-11-07mtd: nand: socrates: use nand_scan() for nand_scan_ident/tail() comboMasahiro Yamada1-10/+2
For this driver, there is nothing between nand_scan_ident() and nand_scan_tail(). They can be merged into nand_scan(). Also, nand_scan() returns an appropriate error value when it fails. Use it instead of the fixed error code -ENXIO. 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>
2016-11-07mtd: nand: nandsim: remove unneeded checks for nand_scan_ident/tail()Masahiro Yamada1-4/+0
The nand_scan_ident/tail() never returns a positive value when it fails. 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>
2016-11-07mtd: nand: pxa3xx: return error code of nand_scan_ident() on errorMasahiro Yamada1-2/+3
The nand_scan_ident() returns an appropriate error value when it fails. Use it instead of the fixed error code -ENODEV. (This driver is already doing so for nand_scan_tail().) 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>
2016-11-07mtd: nand: hisi504: return error code of nand_scan_ident() on errorMasahiro Yamada1-3/+1
The nand_scan_ident() returns an appropriate error value when it fails. Use it instead of the fixed error code -ENODEV. (This driver is already doing so for nand_scan_tail().) 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>
2016-11-07mtd: nand: cafe: return error code of nand_scan_ident() on errorMasahiro Yamada1-3/+2
The nand_scan_ident() returns an appropriate error value when it fails. Use it instead of the fixed error code -ENXIO. (This driver is already doing so for nand_scan_tail().) 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>
2016-11-07mtd: nand: vf610: return error code of nand_scan_ident/tail() on errorMasahiro Yamada1-6/+4
The nand_scan_ident/tail() returns an appropriate error value when it fails. Use it instead of the fixed error code -ENXIO. 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>
2016-11-07mtd: nand: omap2: return error code of nand_scan_ident/tail() on errorMasahiro Yamada1-5/+4
The nand_scan_ident/tail() returns an appropriate error value when it fails. Use it instead of the fixed error code -ENXIO. 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>
2016-11-07mtd: nand: mxc: return error code of nand_scan_ident/tail() on errorMasahiro Yamada1-6/+4
The nand_scan_ident/tail() returns an appropriate error value when it fails. Use it instead of the fixed error code -ENXIO. 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>
2016-11-07mtd: nand: mediatek: return error code of nand_scan_ident/tail() on errorMasahiro Yamada1-2/+2
The nand_scan_ident/tail() 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>
2016-11-07mtd: nand: lpc32xx: return error code of nand_scan_ident/tail() on errorMasahiro Yamada2-12/+8
The nand_scan_ident/tail() returns an appropriate error value when it fails. Use it instead of the fixed error code -ENXIO. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Marek Vasut <marek.vasut@gmail.com> Acked-by: Vladimir Zapolskiy <vz@mleia.com> Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
2016-11-07mtd: nand: fsmc: return error code of nand_scan_ident/tail() on errorMasahiro Yamada1-5/+4
The nand_scan_ident/tail() returns an appropriate error value when it fails. Use it instead of the fixed error code -ENXIO. 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>