linux-uconsole/drivers/mtd
huijin.park 37b5fff3d6 mtd: spi-nor: cast to u64 to avoid uint overflows
commit 84a1c2109d upstream.

The "params->size" is defined as "u64".
And "info->sector_size" and "info->n_sectors" are defined as
unsigned int and u16.
Thus, u64 data might have strange data(loss data) if the result
overflows an unsigned int.
This patch casts "info->sector_size" to an u64.

Signed-off-by: huijin.park <huijin.park@samsung.com>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2019-12-05 09:21:33 +01:00
..
chips mtd: cfi_cmdset_0002: Use chip_good() to retry in do_write_oneword() 2019-10-01 08:26:02 +02:00
devices mtd: devices: m25p80: Make sure WRITE_EN is issued before each write 2019-11-24 08:20:41 +01:00
lpddr mtd: lpddr: use mtd_device_register() 2018-07-24 07:50:22 +02:00
maps mtd: physmap_of: Release resources on error 2019-11-24 08:20:17 +01:00
nand mtd: rawnand: atmel: fix possible object reference leak 2019-12-05 09:21:33 +01:00
parsers
spi-nor mtd: spi-nor: cast to u64 to avoid uint overflows 2019-12-05 09:21:33 +01:00
tests
ubi ubi: Do not drop UBI device reference before using 2019-12-05 09:20:11 +01:00
afs.c
ar7part.c
bcm47xxpart.c
bcm63xxpart.c
cmdlinepart.c
ftl.c
inftlcore.c
inftlmount.c
Kconfig mtd: Make Kconfig formatting consistent 2018-07-19 23:12:06 +02:00
Makefile
mtd_blkdevs.c
mtdblock.c
mtdblock_ro.c
mtdchar.c mtdchar: fix overflows in adjustment of count 2018-07-18 16:46:38 +02:00
mtdconcat.c
mtdcore.c mtd: Fallback to ->_read/write() when ->_read/write_oob() is missing 2018-07-18 16:44:03 +02:00
mtdcore.h mtd: Check add_mtd_device() ret code 2019-12-05 09:21:05 +01:00
mtdoops.c
mtdpart.c mtd: Remove a debug trace in mtdpart.c 2019-12-05 09:21:24 +01:00
mtdsuper.c
mtdswap.c
nftlcore.c
nftlmount.c
ofpart.c
redboot.c
rfd_ftl.c
sm_ftl.c
sm_ftl.h
ssfdc.c