linux/drivers/mtd/chips
Andreas Persson 779a0f4347 mtd: cfi_cmdset_0002: fix crash when erasing/writing AMD cards
commit 2394e62873 upstream.

Erasing an AMD linear flash card (AM29F016D) crashes after the first
sector has been erased. Likewise, writing to it crashes after two bytes
have been written. The reason is a missing check for a null pointer -
the cmdset_priv field is not set for this type of card.

Fixes: 4844ef8030 ("mtd: cfi_cmdset_0002: Add support for polling status register")
Signed-off-by: Andreas Persson <andreasp56@outlook.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/linux-mtd/DB6P189MB05830B3530B8087476C5CFE4C1159@DB6P189MB0583.EURP189.PROD.OUTLOOK.COM
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2021-08-26 08:35:33 -04:00
..
cfi_cmdset_0001.c mtd: cfi_cmdset_0001: Support the absence of protection registers 2020-04-30 23:42:57 +05:30
cfi_cmdset_0002.c mtd: cfi_cmdset_0002: fix crash when erasing/writing AMD cards 2021-08-26 08:35:33 -04:00
cfi_cmdset_0020.c mtd: Convert fallthrough comments into statements 2020-03-30 10:14:54 +02:00
cfi_probe.c
cfi_util.c mtd: Convert fallthrough comments into statements 2020-03-30 10:14:54 +02:00
chipreg.c
fwh_lock.h
gen_probe.c
jedec_probe.c
Kconfig mtd: Replace HTTP links with HTTPS ones 2020-08-02 22:17:19 +02:00
Makefile
map_absent.c
map_ram.c
map_rom.c