linux-stable/drivers/mtd
Zichen Xie 9b458e8be0 mtd: diskonchip: Cast an operand to prevent potential overflow
There may be a potential integer overflow issue in inftl_partscan().
parts[0].size is defined as "uint64_t"  while mtd->erasesize and
ip->firstUnit are defined as 32-bit unsigned integer. The result of
the calculation will be limited to 32 bits without correct casting.

Fixes: 1da177e4c3 ("Linux-2.6.12-rc2")
Signed-off-by: Zichen Xie <zichenxie0106@gmail.com>
Cc: stable@vger.kernel.org
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
2024-12-05 11:09:12 +01:00
..
chips mtd: cfi_cmdset_0002: remove redundant assignment to variable ret 2024-10-21 11:57:43 +02:00
devices mtd: Switch back to struct platform_driver::remove() 2024-10-21 11:58:07 +02:00
hyperbus mtd: Switch back to struct platform_driver::remove() 2024-10-21 11:58:07 +02:00
lpddr mtd: Switch back to struct platform_driver::remove() 2024-10-21 11:58:07 +02:00
maps mtd: Switch back to struct platform_driver::remove() 2024-10-21 11:58:07 +02:00
nand mtd: diskonchip: Cast an operand to prevent potential overflow 2024-12-05 11:09:12 +01:00
parsers mtd: parsers: bcm47xxpart: make read-only array possible_nvram_sizes static const 2024-08-23 19:25:49 +02:00
spi-nor Driver core changes for 6.13-rc1 2024-11-29 11:43:29 -08:00
tests mtd: tests: Include <linux/prandom.h> instead of <linux/random.h> 2024-10-03 18:19:52 +02:00
ubi mtd: ubi: remove redundant check on bytes_left at end of function 2024-11-14 19:54:27 +01:00
ftl.c mtd: ftl: use container_of() rather than cast 2022-09-19 18:14:53 +02:00
inftlcore.c mtd: inftlcore: fix repeated words in comments 2022-11-07 17:14:21 +01:00
inftlmount.c mtd: inftl: remove unnecessary oom message 2021-06-11 20:44:21 +02:00
Kconfig mtdblock: Add comment about UBI block devices 2021-08-06 22:05:13 +02:00
Makefile mtd: Support kmsg dumper based on pstore/blk 2020-05-31 19:49:01 -07:00
mtd_blkdevs.c block: move the add_random flag to queue_limits 2024-06-19 07:58:28 -06:00
mtdblock_ro.c mtdblock: make warning messages ratelimited 2023-07-27 17:16:14 +02:00
mtdblock.c mtdblock: make warning messages ratelimited 2023-07-27 17:16:14 +02:00
mtdchar.c mtdchar: mark bits of ioctl handler noinline 2023-06-01 18:12:31 +02:00
mtdconcat.c mtd: concat: Use kmemdup_array instead of kmemdup for multiple allocation 2024-08-23 19:25:51 +02:00
mtdcore.c * MTD 2024-05-16 09:04:52 -07:00
mtdcore.h mtd: use refcount to prevent corruption 2023-07-12 13:30:08 +02:00
mtdoops.c mtd: mtdoops: Fix kmsgdump parameter renaming. 2024-07-22 17:56:22 +02:00
mtdpart.c mtd: mtdpart: check for subpartitions parsing result 2023-10-16 10:50:32 +02:00
mtdpstore.c mtd: Fix a typo in a comment 2022-09-19 18:14:53 +02:00
mtdsuper.c mtd: key superblock by device number 2023-08-31 12:47:15 +02:00
mtdswap.c mtd: always initialize 'stats' in struct mtd_oob_ops 2022-09-21 10:38:07 +02:00
nftlcore.c mtd: always initialize 'stats' in struct mtd_oob_ops 2022-09-21 10:38:07 +02:00
nftlmount.c mtd: nftl: remove unnecessary oom message 2021-06-11 20:43:26 +02:00
rfd_ftl.c mtd/rfd_ftl: don't cast away the type when calling add_mtd_blktrans_dev 2021-08-23 10:01:06 +02:00
sm_ftl.c mtd: sm_ftl: Fix typos in comments 2023-06-22 23:00:43 +02:00
sm_ftl.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
ssfdc.c mtd: ssfdc: Improve a size determination in ssfdcr_add_mtd() 2024-02-05 14:22:39 +01:00