openwrt-mirror/target/linux/generic/files/drivers
Mieczyslaw Nalewaj 4d18c41a6c kernel: mtk_bmt: counteracting calloc-transposed-args compiler warning
For kernel 6.12 there is a warning causing an error:
drivers/mtd/nand/mtk_bmt_v2.c: In function 'mtk_bmt_get_mapping_mask':
drivers/mtd/nand/mtk_bmt_v2.c:307:31: error: 'kmalloc_array_noprof' sizes specified with 'sizeof' in the earlier argument and not in the later argument [-Werror=calloc-transposed-args]
  307 |         used = kcalloc(sizeof(unsigned long), BIT_WORD(bmtd.bmt_blk_idx) + 1, GFP_KERNEL);
      |                               ^~~~~~~~

Swapping the arguments solves the problem.

Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/18701
Signed-off-by: Robert Marko <robimarko@gmail.com>
2025-05-13 22:07:11 +02:00
..
bcma kernel: fallback-sprom: create separate header files 2024-12-08 13:32:46 +01:00
mtd kernel: mtk_bmt: counteracting calloc-transposed-args compiler warning 2025-05-13 22:07:11 +02:00
net/phy generic: fix kernel warning no previous prototype for ... 2025-04-11 20:34:24 +02:00
platform/mikrotik generic: platform/mikrotik: add wlan lz77 decompress 2024-10-08 10:45:58 +02:00
ssb kernel: fallback-sprom: create separate header files 2024-12-08 13:32:46 +01:00