linux/drivers/mtd
Michael Walle 45bb1faa29 mtd: core: handle flashes without OTP gracefully
There are flash drivers which registers the OTP callbacks although the
flash doesn't support OTP regions and return -ENODATA for these
callbacks if there is no OTP. If this happens, the probe of the whole
flash will fail. Fix it by handling the ENODATA return code and skip
the OTP region nvmem setup.

Fixes: 4b361cfa86 ("mtd: core: add OTP nvmem provider support")
Reported-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Michael Walle <michael@walle.cc>
Tested-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/20210707135359.32398-1-michael@walle.cc
2021-07-16 00:49:20 +02:00
..
chips mtd: Convert list_for_each to entry variant 2021-06-11 21:05:06 +02:00
devices mtd: mchp48l640: silence some uninitialized variable warnings 2021-07-16 00:49:19 +02:00
hyperbus mtd: hyperbus: Fix build failure when only RPCIF_HYPERBUS is enabled 2020-10-12 21:12:08 +02:00
lpddr mtd: lpddr: fix excessive stack usage with clang 2020-08-27 14:36:07 +02:00
maps mtd: amd76xrom: remove unnecessary oom message 2021-06-11 20:44:18 +02:00
nand mtd: rawnand: Add a check in of_get_nand_secure_regions() 2021-07-16 00:49:15 +02:00
parsers MTD core changes: 2021-07-05 11:21:51 -07:00
spi-nor mtd: spi-nor: remove redundant continue statement 2021-06-21 11:17:10 +05:30
tests mtd: tests: Remove redundant assignment to err 2021-05-10 12:48:35 +02:00
ubi This pull request contains the following changes for UBIFS: 2021-07-09 10:10:47 -07:00
ftl.c mtd: ftl: Use module_mtd_blktrans to register driver 2021-03-11 09:37:48 +01:00
inftlcore.c mtd: inftlcore: Use module_mtd_blktrans to register driver 2021-03-11 09:37:48 +01:00
inftlmount.c mtd: inftl: remove unnecessary oom message 2021-06-11 20:44:21 +02:00
Kconfig mtd: nand: ecc-hamming: Move Hamming code to the generic NAND layer 2020-12-10 22:37:29 +01:00
Makefile mtd: Support kmsg dumper based on pstore/blk 2020-05-31 19:49:01 -07:00
mtd_blkdevs.c mtd: break circular locks in register_mtd_blktrans 2021-07-16 00:49:17 +02:00
mtdblock.c mtd: mtdblock: Use module_mtd_blktrans to register driver 2021-03-11 09:37:48 +01:00
mtdblock_ro.c mtd: mtdblock_ro: Use module_mtd_blktrans to register driver 2021-03-11 09:37:48 +01:00
mtdchar.c mtd: add OTP (one-time-programmable) erase ioctl 2021-03-28 19:24:54 +02:00
mtdconcat.c mtd: mtdconcat: map: remove redundant assignment to variable 'size' 2020-09-11 18:49:34 +02:00
mtdcore.c mtd: core: handle flashes without OTP gracefully 2021-07-16 00:49:20 +02:00
mtdcore.h mtd: Provide fs_context-aware mount_mtd() replacement 2019-09-05 14:34:23 -04:00
mtdoops.c mtd: mtdoops: remove unnecessary oom message 2021-06-11 20:43:46 +02:00
mtdpart.c mtd: mtdpart: use DEVICE_ATTR_RO() helper macro 2021-06-11 20:42:45 +02:00
mtdpstore.c pstore/blk: Include zone in pstore_device_info 2021-06-16 21:09:31 -07:00
mtdsuper.c block: remove i_bdev 2020-12-01 14:53:39 -07:00
mtdswap.c mtd: mtdswap: Use module_mtd_blktrans to register driver 2021-03-11 09:37:48 +01:00
nftlcore.c mtd: nftlcore: remove set but rewrite variables 2021-05-10 12:11:46 +02:00
nftlmount.c mtd: nftl: remove unnecessary oom message 2021-06-11 20:43:26 +02:00
rfd_ftl.c mtd: rfd_ftl: remove unnecessary oom message 2021-06-11 20:43:20 +02:00
sm_ftl.c drivers: mtd: sm_ftl: Fix alignment of block comment 2021-05-10 12:49:00 +02:00
sm_ftl.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
ssfdc.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00