u-boot/drivers/mtd/ubi
Takahiro Kuwano 6d7a8bf8c0 mtd: ubi: Do not zero out EC and VID on ECC-ed NOR flashes
For NOR flashes EC and VID are zeroed out before an erase is issued to
make sure UBI does not mistakenly treat the PEB as used and associate it
with an LEB.

But on some flashes, like the Infineon Semper NOR flash family,
multi-pass page programming is not allowed on the default ECC scheme.
This means zeroing out these magic numbers will result in the flash
throwing a page programming error.

Do not zero out EC and VID for such flashes. A writesize > 1 is an
indication of an ECC-ed flash.

This patch replicates the following upstream linux commit:
f669e74be820 ("ubi: Do not zero out EC and VID on ECC-ed NOR flashes")

Acked-by: Tudor Ambarus <tudor.ambarus@linaro.org>
Acked-by: Pratyush Yadav <pratyush@kernel.org>
Signed-off-by: Takahiro Kuwano <Takahiro.Kuwano@infineon.com>
Reviewed-by: Tudor Ambarus <tudor.ambarus@microchip.com>
2024-10-15 08:57:49 -06:00
..
attach.c common: Drop linux/printk.h from common header 2023-09-24 09:54:57 -04:00
block.c drivers: introduce UBI block abstraction 2024-08-08 09:28:00 +02:00
build.c mtd: ubi: Do not zero out EC and VID on ECC-ed NOR flashes 2024-10-15 08:57:49 -06:00
crc32.c WS cleanup: remove SPACE(s) followed by TAB 2021-09-30 09:08:16 -04:00
crc32defs.h UBI: Add basic UBI support to U-Boot (Part 2/8) 2008-11-19 20:34:39 +01:00
crc32table.h mtd, ubi, ubifs: resync with Linux-3.14 2014-08-25 19:25:55 -04:00
debug.c common: Drop linux/printk.h from common header 2023-09-24 09:54:57 -04:00
debug.h common: Drop linux/printk.h from common header 2023-09-24 09:54:57 -04:00
eba.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
fastmap-wl.c ubi: fastmap: Implement produce_free_peb() 2018-05-22 11:39:05 +02:00
fastmap.c list: use list_count_nodes() to count list entries 2024-08-30 13:51:38 -06:00
io.c mtd: ubi: Do not zero out EC and VID on ECC-ed NOR flashes 2024-10-15 08:57:49 -06:00
kapi.c dm: core: Require users of devres to include the header 2020-02-05 19:33:46 -07:00
Kconfig Merge tag 'u-boot-nand-20240808' of https://source.denx.de/u-boot/custodians/u-boot-nand-flash 2024-08-08 16:15:06 -06:00
Makefile disk: support UBI partitions 2024-08-08 09:28:05 +02:00
misc.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
part.c disk: support UBI partitions 2024-08-08 09:28:05 +02:00
ubi-media.h ubi: provide a way to skip CRC checks 2019-10-16 05:42:27 +02:00
ubi.h common: Drop linux/printk.h from common header 2023-09-24 09:54:57 -04:00
upd.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
vmt.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
vtbl.c common: Drop linux/bug.h from common header 2020-05-18 21:19:23 -04:00
wl.c common: Drop log.h from common header 2020-05-18 21:19:18 -04:00
wl.h ubi,ubifs: sync with linux v4.2 2015-10-26 09:22:36 +01:00