Date
Nov. 28, 2024, 2:36 a.m.
Environment | |
---|---|
qemu-arm64 | |
qemu-x86_64 |
[ 29.552343] ================================================================== [ 29.553786] BUG: KASAN: slab-out-of-bounds in kmalloc_big_oob_right+0x2a4/0x2f0 [ 29.555310] Write of size 1 at addr fff00000c6519f00 by task kunit_try_catch/132 [ 29.556701] [ 29.557222] CPU: 0 UID: 0 PID: 132 Comm: kunit_try_catch Tainted: G B N 6.12.0-next-20241128 #1 [ 29.558716] Tainted: [B]=BAD_PAGE, [N]=TEST [ 29.559199] Hardware name: linux,dummy-virt (DT) [ 29.559874] Call trace: [ 29.560331] show_stack+0x20/0x38 (C) [ 29.560956] dump_stack_lvl+0x8c/0xd0 [ 29.562426] print_report+0x118/0x5e0 [ 29.562945] kasan_report+0xc8/0x118 [ 29.563448] __asan_report_store1_noabort+0x20/0x30 [ 29.564069] kmalloc_big_oob_right+0x2a4/0x2f0 [ 29.564667] kunit_try_run_case+0x14c/0x3d0 [ 29.565696] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 29.566425] kthread+0x24c/0x2d0 [ 29.566889] ret_from_fork+0x10/0x20 [ 29.567398] [ 29.567717] Allocated by task 132: [ 29.568207] kasan_save_stack+0x3c/0x68 [ 29.568735] kasan_save_track+0x20/0x40 [ 29.569232] kasan_save_alloc_info+0x40/0x58 [ 29.570491] __kasan_kmalloc+0xd4/0xd8 [ 29.571561] __kmalloc_cache_noprof+0x15c/0x3c0 [ 29.572350] kmalloc_big_oob_right+0xb8/0x2f0 [ 29.573160] kunit_try_run_case+0x14c/0x3d0 [ 29.574144] kunit_generic_run_threadfn_adapter+0x88/0x100 [ 29.574733] kthread+0x24c/0x2d0 [ 29.575276] ret_from_fork+0x10/0x20 [ 29.575757] [ 29.576097] The buggy address belongs to the object at fff00000c6518000 [ 29.576097] which belongs to the cache kmalloc-8k of size 8192 [ 29.577403] The buggy address is located 0 bytes to the right of [ 29.577403] allocated 7936-byte region [fff00000c6518000, fff00000c6519f00) [ 29.579002] [ 29.579435] The buggy address belongs to the physical page: [ 29.580243] page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x106518 [ 29.581066] head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 [ 29.581874] flags: 0xbfffe0000000040(head|node=0|zone=2|lastcpupid=0x1ffff) [ 29.583389] page_type: f5(slab) [ 29.584017] raw: 0bfffe0000000040 fff00000c0002280 dead000000000122 0000000000000000 [ 29.585036] raw: 0000000000000000 0000000080020002 00000001f5000000 0000000000000000 [ 29.585832] head: 0bfffe0000000040 fff00000c0002280 dead000000000122 0000000000000000 [ 29.586632] head: 0000000000000000 0000000080020002 00000001f5000000 0000000000000000 [ 29.588200] head: 0bfffe0000000003 ffffc1ffc3194601 ffffffffffffffff 0000000000000000 [ 29.589363] head: 0000000000000008 0000000000000000 00000000ffffffff 0000000000000000 [ 29.590153] page dumped because: kasan: bad access detected [ 29.590750] [ 29.591082] Memory state around the buggy address: [ 29.591581] fff00000c6519e00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 29.592431] fff00000c6519e80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 29.593321] >fff00000c6519f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 29.593991] ^ [ 29.594433] fff00000c6519f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 29.596038] fff00000c651a000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 29.596645] ==================================================================
[ 20.291004] ================================================================== [ 20.292152] BUG: KASAN: slab-out-of-bounds in kmalloc_big_oob_right+0x318/0x370 [ 20.293401] Write of size 1 at addr ffff888102cc1f00 by task kunit_try_catch/152 [ 20.294824] [ 20.295115] CPU: 0 UID: 0 PID: 152 Comm: kunit_try_catch Tainted: G B N 6.12.0-next-20241128 #1 [ 20.296436] Tainted: [B]=BAD_PAGE, [N]=TEST [ 20.296737] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 20.297589] Call Trace: [ 20.297899] <TASK> [ 20.298198] dump_stack_lvl+0x73/0xb0 [ 20.298825] print_report+0xd1/0x640 [ 20.299214] ? __virt_addr_valid+0x1db/0x2d0 [ 20.299726] ? kasan_complete_mode_report_info+0x2a/0x200 [ 20.300215] kasan_report+0x102/0x140 [ 20.300586] ? kmalloc_big_oob_right+0x318/0x370 [ 20.300994] ? kmalloc_big_oob_right+0x318/0x370 [ 20.301648] __asan_report_store1_noabort+0x1b/0x30 [ 20.302886] kmalloc_big_oob_right+0x318/0x370 [ 20.303623] ? __pfx_kmalloc_big_oob_right+0x10/0x10 [ 20.304029] ? __schedule+0xc3e/0x2790 [ 20.305311] ? __pfx_read_tsc+0x10/0x10 [ 20.305696] ? ktime_get_ts64+0x84/0x230 [ 20.306304] kunit_try_run_case+0x1b3/0x490 [ 20.307068] ? __pfx_kunit_try_run_case+0x10/0x10 [ 20.307774] ? _raw_spin_lock_irqsave+0xa2/0x110 [ 20.308539] ? _raw_spin_unlock_irqrestore+0x5f/0x90 [ 20.309184] ? __kthread_parkme+0x82/0x160 [ 20.309685] ? preempt_count_sub+0x50/0x80 [ 20.310078] ? __pfx_kunit_try_run_case+0x10/0x10 [ 20.310674] ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10 [ 20.311519] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 20.311885] kthread+0x257/0x310 [ 20.312573] ? __pfx_kthread+0x10/0x10 [ 20.312878] ret_from_fork+0x41/0x80 [ 20.313308] ? __pfx_kthread+0x10/0x10 [ 20.313882] ret_from_fork_asm+0x1a/0x30 [ 20.314218] </TASK> [ 20.314613] [ 20.314860] Allocated by task 152: [ 20.315166] kasan_save_stack+0x3d/0x60 [ 20.315487] kasan_save_track+0x18/0x40 [ 20.316112] kasan_save_alloc_info+0x3b/0x50 [ 20.316893] __kasan_kmalloc+0xb7/0xc0 [ 20.317608] __kmalloc_cache_noprof+0x184/0x410 [ 20.317934] kmalloc_big_oob_right+0xaa/0x370 [ 20.318228] kunit_try_run_case+0x1b3/0x490 [ 20.319528] kunit_generic_run_threadfn_adapter+0x85/0xf0 [ 20.320276] kthread+0x257/0x310 [ 20.320910] ret_from_fork+0x41/0x80 [ 20.321313] ret_from_fork_asm+0x1a/0x30 [ 20.321863] [ 20.322114] The buggy address belongs to the object at ffff888102cc0000 [ 20.322114] which belongs to the cache kmalloc-8k of size 8192 [ 20.323318] The buggy address is located 0 bytes to the right of [ 20.323318] allocated 7936-byte region [ffff888102cc0000, ffff888102cc1f00) [ 20.325618] [ 20.325940] The buggy address belongs to the physical page: [ 20.326573] page: refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x102cc0 [ 20.327594] head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 [ 20.328284] flags: 0x200000000000040(head|node=0|zone=2) [ 20.328887] page_type: f5(slab) [ 20.329527] raw: 0200000000000040 ffff888100042280 dead000000000122 0000000000000000 [ 20.330636] raw: 0000000000000000 0000000080020002 00000001f5000000 0000000000000000 [ 20.331760] head: 0200000000000040 ffff888100042280 dead000000000122 0000000000000000 [ 20.332480] head: 0000000000000000 0000000080020002 00000001f5000000 0000000000000000 [ 20.333517] head: 0200000000000003 ffffea00040b3001 ffffffffffffffff 0000000000000000 [ 20.334729] head: 0000000000000008 0000000000000000 00000000ffffffff 0000000000000000 [ 20.335853] page dumped because: kasan: bad access detected [ 20.336609] [ 20.336898] Memory state around the buggy address: [ 20.337563] ffff888102cc1e00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 20.338298] ffff888102cc1e80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 [ 20.338973] >ffff888102cc1f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 20.339650] ^ [ 20.339965] ffff888102cc1f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 20.341299] ffff888102cc2000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc [ 20.341986] ==================================================================