Hay
Date
May 13, 2025, 12:07 p.m.

Environment
qemu-arm64
qemu-x86_64

[   19.754274] ==================================================================
[   19.754477] BUG: KASAN: slab-out-of-bounds in kmem_cache_oob+0x344/0x430
[   19.754618] Read of size 1 at addr fff00000c66140c8 by task kunit_try_catch/207
[   19.754682] 
[   19.754831] CPU: 1 UID: 0 PID: 207 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-rc6-next-20250513 #1 PREEMPT 
[   19.755003] Tainted: [B]=BAD_PAGE, [N]=TEST
[   19.755072] Hardware name: linux,dummy-virt (DT)
[   19.755116] Call trace:
[   19.755146]  show_stack+0x20/0x38 (C)
[   19.755214]  dump_stack_lvl+0x8c/0xd0
[   19.755268]  print_report+0x118/0x608
[   19.755455]  kasan_report+0xdc/0x128
[   19.755608]  __asan_report_load1_noabort+0x20/0x30
[   19.755836]  kmem_cache_oob+0x344/0x430
[   19.755928]  kunit_try_run_case+0x170/0x3f0
[   19.756004]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   19.756181]  kthread+0x328/0x630
[   19.756288]  ret_from_fork+0x10/0x20
[   19.756354] 
[   19.756376] Allocated by task 207:
[   19.756410]  kasan_save_stack+0x3c/0x68
[   19.756462]  kasan_save_track+0x20/0x40
[   19.756647]  kasan_save_alloc_info+0x40/0x58
[   19.756697]  __kasan_slab_alloc+0xa8/0xb0
[   19.756740]  kmem_cache_alloc_noprof+0x10c/0x3a0
[   19.756789]  kmem_cache_oob+0x12c/0x430
[   19.756830]  kunit_try_run_case+0x170/0x3f0
[   19.756872]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   19.756921]  kthread+0x328/0x630
[   19.757211]  ret_from_fork+0x10/0x20
[   19.757400] 
[   19.757509] The buggy address belongs to the object at fff00000c6614000
[   19.757509]  which belongs to the cache test_cache of size 200
[   19.757609] The buggy address is located 0 bytes to the right of
[   19.757609]  allocated 200-byte region [fff00000c6614000, fff00000c66140c8)
[   19.757689] 
[   19.757845] The buggy address belongs to the physical page:
[   19.757983] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x106614
[   19.758052] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   19.758158] page_type: f5(slab)
[   19.758216] raw: 0bfffe0000000000 fff00000c1806b40 dead000000000122 0000000000000000
[   19.758426] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000
[   19.758649] page dumped because: kasan: bad access detected
[   19.758703] 
[   19.758726] Memory state around the buggy address:
[   19.758782]  fff00000c6613f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   19.758838]  fff00000c6614000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   19.759294] >fff00000c6614080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc
[   19.759688]                                               ^
[   19.759801]  fff00000c6614100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   19.759938]  fff00000c6614180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   19.760084] ==================================================================

[   11.757013] ==================================================================
[   11.757398] BUG: KASAN: slab-out-of-bounds in kmem_cache_oob+0x402/0x530
[   11.757683] Read of size 1 at addr ffff8881039da0c8 by task kunit_try_catch/224
[   11.758165] 
[   11.758315] CPU: 1 UID: 0 PID: 224 Comm: kunit_try_catch Tainted: G    B            N  6.15.0-rc6-next-20250513 #1 PREEMPT(voluntary) 
[   11.758366] Tainted: [B]=BAD_PAGE, [N]=TEST
[   11.758379] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   11.758400] Call Trace:
[   11.758413]  <TASK>
[   11.758431]  dump_stack_lvl+0x73/0xb0
[   11.758461]  print_report+0xd1/0x650
[   11.758492]  ? __virt_addr_valid+0x1db/0x2d0
[   11.758516]  ? kmem_cache_oob+0x402/0x530
[   11.758586]  ? kasan_complete_mode_report_info+0x2a/0x200
[   11.758610]  ? kmem_cache_oob+0x402/0x530
[   11.758662]  kasan_report+0x141/0x180
[   11.758686]  ? kmem_cache_oob+0x402/0x530
[   11.758711]  __asan_report_load1_noabort+0x18/0x20
[   11.758732]  kmem_cache_oob+0x402/0x530
[   11.758749]  ? trace_hardirqs_on+0x37/0xe0
[   11.758774]  ? __pfx_kmem_cache_oob+0x10/0x10
[   11.758793]  ? finish_task_switch.isra.0+0x153/0x700
[   11.758815]  ? __switch_to+0x47/0xf50
[   11.758845]  ? __pfx_read_tsc+0x10/0x10
[   11.758865]  ? ktime_get_ts64+0x86/0x230
[   11.758891]  kunit_try_run_case+0x1a5/0x480
[   11.758933]  ? __pfx_kunit_try_run_case+0x10/0x10
[   11.758955]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   11.758993]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   11.759015]  ? __kthread_parkme+0x82/0x180
[   11.759036]  ? preempt_count_sub+0x50/0x80
[   11.759059]  ? __pfx_kunit_try_run_case+0x10/0x10
[   11.759082]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   11.759105]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   11.759128]  kthread+0x337/0x6f0
[   11.759147]  ? trace_preempt_on+0x20/0xc0
[   11.759169]  ? __pfx_kthread+0x10/0x10
[   11.759202]  ? _raw_spin_unlock_irq+0x47/0x80
[   11.759222]  ? calculate_sigpending+0x7b/0xa0
[   11.759246]  ? __pfx_kthread+0x10/0x10
[   11.759268]  ret_from_fork+0x116/0x1d0
[   11.759286]  ? __pfx_kthread+0x10/0x10
[   11.759307]  ret_from_fork_asm+0x1a/0x30
[   11.759339]  </TASK>
[   11.759350] 
[   11.770346] Allocated by task 224:
[   11.770725]  kasan_save_stack+0x45/0x70
[   11.770914]  kasan_save_track+0x18/0x40
[   11.771085]  kasan_save_alloc_info+0x3b/0x50
[   11.771641]  __kasan_slab_alloc+0x91/0xa0
[   11.772022]  kmem_cache_alloc_noprof+0x123/0x3f0
[   11.772366]  kmem_cache_oob+0x157/0x530
[   11.772924]  kunit_try_run_case+0x1a5/0x480
[   11.773122]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   11.773825]  kthread+0x337/0x6f0
[   11.774079]  ret_from_fork+0x116/0x1d0
[   11.774520]  ret_from_fork_asm+0x1a/0x30
[   11.774798] 
[   11.775015] The buggy address belongs to the object at ffff8881039da000
[   11.775015]  which belongs to the cache test_cache of size 200
[   11.775897] The buggy address is located 0 bytes to the right of
[   11.775897]  allocated 200-byte region [ffff8881039da000, ffff8881039da0c8)
[   11.776910] 
[   11.777014] The buggy address belongs to the physical page:
[   11.777818] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1039da
[   11.778159] flags: 0x200000000000000(node=0|zone=2)
[   11.778749] page_type: f5(slab)
[   11.778917] raw: 0200000000000000 ffff888100faf3c0 dead000000000122 0000000000000000
[   11.779300] raw: 0000000000000000 00000000800f000f 00000000f5000000 0000000000000000
[   11.779955] page dumped because: kasan: bad access detected
[   11.780368] 
[   11.780461] Memory state around the buggy address:
[   11.781024]  ffff8881039d9f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   11.781754]  ffff8881039da000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   11.782202] >ffff8881039da080: 00 00 00 00 00 00 00 00 00 fc fc fc fc fc fc fc
[   11.782834]                                               ^
[   11.783083]  ffff8881039da100: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   11.783951]  ffff8881039da180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   11.784355] ==================================================================