Hay
Date
June 24, 2025, 12:47 p.m.

Environment
qemu-arm64
qemu-x86_64

[   23.282117] ==================================================================
[   23.282248] BUG: KASAN: slab-out-of-bounds in kmalloc_big_oob_right+0x2a4/0x2f0
[   23.282405] Write of size 1 at addr fff00000c65adf00 by task kunit_try_catch/146
[   23.282535] 
[   23.282682] CPU: 0 UID: 0 PID: 146 Comm: kunit_try_catch Tainted: G    B            N  6.15.4-rc2 #1 PREEMPT 
[   23.282935] Tainted: [B]=BAD_PAGE, [N]=TEST
[   23.283015] Hardware name: linux,dummy-virt (DT)
[   23.283103] Call trace:
[   23.283162]  show_stack+0x20/0x38 (C)
[   23.283370]  dump_stack_lvl+0x8c/0xd0
[   23.283519]  print_report+0x118/0x608
[   23.283648]  kasan_report+0xdc/0x128
[   23.283909]  __asan_report_store1_noabort+0x20/0x30
[   23.284072]  kmalloc_big_oob_right+0x2a4/0x2f0
[   23.284245]  kunit_try_run_case+0x170/0x3f0
[   23.284453]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   23.284706]  kthread+0x328/0x630
[   23.284867]  ret_from_fork+0x10/0x20
[   23.285174] 
[   23.285221] Allocated by task 146:
[   23.285290]  kasan_save_stack+0x3c/0x68
[   23.285401]  kasan_save_track+0x20/0x40
[   23.285519]  kasan_save_alloc_info+0x40/0x58
[   23.285622]  __kasan_kmalloc+0xd4/0xd8
[   23.285748]  __kmalloc_cache_noprof+0x16c/0x3c0
[   23.285860]  kmalloc_big_oob_right+0xb8/0x2f0
[   23.286109]  kunit_try_run_case+0x170/0x3f0
[   23.286339]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   23.286482]  kthread+0x328/0x630
[   23.286636]  ret_from_fork+0x10/0x20
[   23.286748] 
[   23.286803] The buggy address belongs to the object at fff00000c65ac000
[   23.286803]  which belongs to the cache kmalloc-8k of size 8192
[   23.286967] The buggy address is located 0 bytes to the right of
[   23.286967]  allocated 7936-byte region [fff00000c65ac000, fff00000c65adf00)
[   23.287122] 
[   23.287171] The buggy address belongs to the physical page:
[   23.287247] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1065a8
[   23.287408] head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
[   23.287568] flags: 0xbfffe0000000040(head|node=0|zone=2|lastcpupid=0x1ffff)
[   23.287720] page_type: f5(slab)
[   23.287825] raw: 0bfffe0000000040 fff00000c0002280 dead000000000122 0000000000000000
[   23.287950] raw: 0000000000000000 0000000080020002 00000000f5000000 0000000000000000
[   23.288203] head: 0bfffe0000000040 fff00000c0002280 dead000000000122 0000000000000000
[   23.288355] head: 0000000000000000 0000000080020002 00000000f5000000 0000000000000000
[   23.288512] head: 0bfffe0000000003 ffffc1ffc3196a01 00000000ffffffff 00000000ffffffff
[   23.288633] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000008
[   23.288730] page dumped because: kasan: bad access detected
[   23.288803] 
[   23.289306] Memory state around the buggy address:
[   23.289685]  fff00000c65ade00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   23.289814]  fff00000c65ade80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   23.290501] >fff00000c65adf00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   23.290802]                    ^
[   23.291063]  fff00000c65adf80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   23.291182]  fff00000c65ae000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   23.291822] ==================================================================

[   11.037760] ==================================================================
[   11.038341] BUG: KASAN: slab-out-of-bounds in kmalloc_big_oob_right+0x316/0x370
[   11.039057] Write of size 1 at addr ffff888103a19f00 by task kunit_try_catch/164
[   11.040078] 
[   11.040773] CPU: 0 UID: 0 PID: 164 Comm: kunit_try_catch Tainted: G    B            N  6.15.4-rc2 #1 PREEMPT(voluntary) 
[   11.040900] Tainted: [B]=BAD_PAGE, [N]=TEST
[   11.040917] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   11.040944] Call Trace:
[   11.040963]  <TASK>
[   11.040991]  dump_stack_lvl+0x73/0xb0
[   11.041036]  print_report+0xd1/0x650
[   11.041061]  ? __virt_addr_valid+0x1db/0x2d0
[   11.041085]  ? kmalloc_big_oob_right+0x316/0x370
[   11.041107]  ? kasan_complete_mode_report_info+0x2a/0x200
[   11.041129]  ? kmalloc_big_oob_right+0x316/0x370
[   11.041151]  kasan_report+0x141/0x180
[   11.041173]  ? kmalloc_big_oob_right+0x316/0x370
[   11.041200]  __asan_report_store1_noabort+0x1b/0x30
[   11.041220]  kmalloc_big_oob_right+0x316/0x370
[   11.041242]  ? __pfx_kmalloc_big_oob_right+0x10/0x10
[   11.041265]  ? __schedule+0x10cc/0x2b60
[   11.041306]  ? __pfx_read_tsc+0x10/0x10
[   11.041337]  ? ktime_get_ts64+0x86/0x230
[   11.041379]  kunit_try_run_case+0x1a5/0x480
[   11.041410]  ? __pfx_kunit_try_run_case+0x10/0x10
[   11.041431]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   11.041456]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   11.041478]  ? __kthread_parkme+0x82/0x180
[   11.041501]  ? preempt_count_sub+0x50/0x80
[   11.041526]  ? __pfx_kunit_try_run_case+0x10/0x10
[   11.041562]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   11.041585]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   11.041607]  kthread+0x337/0x6f0
[   11.041640]  ? trace_preempt_on+0x20/0xc0
[   11.041668]  ? __pfx_kthread+0x10/0x10
[   11.041686]  ? _raw_spin_unlock_irq+0x47/0x80
[   11.041707]  ? calculate_sigpending+0x7b/0xa0
[   11.041729]  ? __pfx_kthread+0x10/0x10
[   11.041747]  ret_from_fork+0x41/0x80
[   11.041767]  ? __pfx_kthread+0x10/0x10
[   11.041784]  ret_from_fork_asm+0x1a/0x30
[   11.041818]  </TASK>
[   11.041831] 
[   11.053271] Allocated by task 164:
[   11.053636]  kasan_save_stack+0x45/0x70
[   11.054023]  kasan_save_track+0x18/0x40
[   11.054313]  kasan_save_alloc_info+0x3b/0x50
[   11.054843]  __kasan_kmalloc+0xb7/0xc0
[   11.055080]  __kmalloc_cache_noprof+0x189/0x420
[   11.055332]  kmalloc_big_oob_right+0xa9/0x370
[   11.055645]  kunit_try_run_case+0x1a5/0x480
[   11.056502]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   11.056857]  kthread+0x337/0x6f0
[   11.057125]  ret_from_fork+0x41/0x80
[   11.057330]  ret_from_fork_asm+0x1a/0x30
[   11.057498] 
[   11.057877] The buggy address belongs to the object at ffff888103a18000
[   11.057877]  which belongs to the cache kmalloc-8k of size 8192
[   11.058299] The buggy address is located 0 bytes to the right of
[   11.058299]  allocated 7936-byte region [ffff888103a18000, ffff888103a19f00)
[   11.059168] 
[   11.059447] The buggy address belongs to the physical page:
[   11.059901] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x103a18
[   11.061087] head: order:3 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0
[   11.061563] flags: 0x200000000000040(head|node=0|zone=2)
[   11.061954] page_type: f5(slab)
[   11.062171] raw: 0200000000000040 ffff888100042280 dead000000000122 0000000000000000
[   11.063315] raw: 0000000000000000 0000000080020002 00000000f5000000 0000000000000000
[   11.063547] head: 0200000000000040 ffff888100042280 dead000000000122 0000000000000000
[   11.064063] head: 0000000000000000 0000000080020002 00000000f5000000 0000000000000000
[   11.064433] head: 0200000000000003 ffffea00040e8601 00000000ffffffff 00000000ffffffff
[   11.065425] head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000008
[   11.065679] page dumped because: kasan: bad access detected
[   11.066341] 
[   11.066444] Memory state around the buggy address:
[   11.066977]  ffff888103a19e00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   11.067564]  ffff888103a19e80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   11.067999] >ffff888103a19f00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   11.068879]                    ^
[   11.069020]  ffff888103a19f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   11.069149]  ffff888103a1a000: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   11.069268] ==================================================================