android_kernel_xiaomi_sm8450/drivers/mtd
Alexander Sverdlin 62307558e7 mtd: spi-nor: Check for zero erase size in spi_nor_find_best_erase_type()
commit 2ebc336be08160debfe27f87660cf550d710f3e9 upstream.

Erase can be zeroed in spi_nor_parse_4bait() or
spi_nor_init_non_uniform_erase_map(). In practice it happened with
mt25qu256a, which supports 4K, 32K, 64K erases with 3b address commands,
but only 4K and 64K erase with 4b address commands.

Fixes: dc92843159 ("mtd: spi-nor: fix erase_type array to indicate current map conf")
Signed-off-by: Alexander Sverdlin <alexander.sverdlin@nokia.com>
Signed-off-by: Tudor Ambarus <tudor.ambarus@microchip.com>
Cc: stable@vger.kernel.org
Link: https://lore.kernel.org/r/20211119081412.29732-1-alexander.sverdlin@nokia.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2023-01-14 10:16:35 +01:00
..
chips mtd: cfi_cmdset_0002: Use chip_ready() for write on S29GL064N 2022-06-09 10:21:25 +02:00
devices mtd: devices: docg3: check the return value of devm_ioremap() in the probe 2022-10-26 13:25:34 +02:00
hyperbus mtd: hyperbus: rpc-if: fix bug in rpcif_hb_remove 2022-01-27 10:53:50 +01:00
lpddr mtd: lpddr2_nvm: Fix possible null-ptr-deref 2023-01-14 10:15:30 +01:00
maps mtd: maps: pxa2xx-flash: fix memory leak in probe 2023-01-14 10:15:32 +01:00
nand mtd: rawnand: gpmi: Set WAIT_FOR_READY timeout based on program/erase times 2022-11-10 18:14:25 +01:00
parsers mtd: parsers: bcm47xxpart: Fix halfblock reads 2022-11-10 18:14:21 +01:00
spi-nor mtd: spi-nor: Check for zero erase size in spi_nor_find_best_erase_type() 2023-01-14 10:16:35 +01:00
tests
ubi ubi: ubi_create_volume: Fix use-after-free when volume creation failed 2022-06-14 18:32:35 +02:00
ftl.c
inftlcore.c
inftlmount.c
Kconfig
Makefile
mtd_blkdevs.c
mtdblock_ro.c
mtdblock.c
mtdchar.c mtd: require write permissions for locking and badblock ioctls 2021-05-14 09:50:13 +02:00
mtdconcat.c mtd: mtdconcat: Check _read, _write callbacks existence before assignment 2021-09-22 12:28:03 +02:00
mtdcore.c mtd: Fix device name leak when register device failed in add_mtd_device() 2023-01-14 10:15:28 +01:00
mtdcore.h
mtdoops.c mtd: mtdoops: Don't write panic data twice 2020-09-07 14:22:12 +02:00
mtdpart.c mtd: Fixed breaking list in __mtd_del_partition. 2022-01-27 10:53:41 +01:00
mtdpstore.c
mtdsuper.c
mtdswap.c
nftlcore.c
nftlmount.c
rfd_ftl.c
sm_ftl.c mtd: sm_ftl: Fix deadlock caused by cancel_work_sync in sm_release 2022-08-21 15:15:53 +02:00
sm_ftl.h
ssfdc.c