Hay
Date
June 18, 2025, 6:43 a.m.

Environment
qemu-arm64
qemu-x86_64

[   24.459544] ==================================================================
[   24.459637] BUG: KASAN: slab-out-of-bounds in copy_to_kernel_nofault+0x8c/0x250
[   24.460178] Write of size 8 at addr fff00000c7791f78 by task kunit_try_catch/291
[   24.460272] 
[   24.460593] CPU: 0 UID: 0 PID: 291 Comm: kunit_try_catch Tainted: G    B   W        N  6.16.0-rc2-next-20250618 #1 PREEMPT 
[   24.460718] Tainted: [B]=BAD_PAGE, [W]=WARN, [N]=TEST
[   24.460758] Hardware name: linux,dummy-virt (DT)
[   24.461033] Call trace:
[   24.461081]  show_stack+0x20/0x38 (C)
[   24.461170]  dump_stack_lvl+0x8c/0xd0
[   24.461594]  print_report+0x118/0x608
[   24.461850]  kasan_report+0xdc/0x128
[   24.462080]  kasan_check_range+0x100/0x1a8
[   24.462305]  __kasan_check_write+0x20/0x30
[   24.462398]  copy_to_kernel_nofault+0x8c/0x250
[   24.462523]  copy_to_kernel_nofault_oob+0x1bc/0x418
[   24.462612]  kunit_try_run_case+0x170/0x3f0
[   24.463031]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   24.463224]  kthread+0x328/0x630
[   24.463287]  ret_from_fork+0x10/0x20
[   24.463413] 
[   24.463461] Allocated by task 291:
[   24.463502]  kasan_save_stack+0x3c/0x68
[   24.463584]  kasan_save_track+0x20/0x40
[   24.463797]  kasan_save_alloc_info+0x40/0x58
[   24.463896]  __kasan_kmalloc+0xd4/0xd8
[   24.463960]  __kmalloc_cache_noprof+0x16c/0x3c0
[   24.464321]  copy_to_kernel_nofault_oob+0xc8/0x418
[   24.464399]  kunit_try_run_case+0x170/0x3f0
[   24.464451]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   24.464503]  kthread+0x328/0x630
[   24.464686]  ret_from_fork+0x10/0x20
[   24.464749] 
[   24.464821] The buggy address belongs to the object at fff00000c7791f00
[   24.464821]  which belongs to the cache kmalloc-128 of size 128
[   24.464906] The buggy address is located 0 bytes to the right of
[   24.464906]  allocated 120-byte region [fff00000c7791f00, fff00000c7791f78)
[   24.464982] 
[   24.465010] The buggy address belongs to the physical page:
[   24.465066] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x107791
[   24.465135] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   24.465201] page_type: f5(slab)
[   24.465255] raw: 0bfffe0000000000 fff00000c0001a00 dead000000000122 0000000000000000
[   24.465324] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   24.465375] page dumped because: kasan: bad access detected
[   24.465427] 
[   24.465469] Memory state around the buggy address:
[   24.465516]  fff00000c7791e00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   24.465581]  fff00000c7791e80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   24.465639] >fff00000c7791f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   24.465685]                                                                 ^
[   24.465736]  fff00000c7791f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   24.465787]  fff00000c7792000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   24.465835] ==================================================================
[   24.445786] ==================================================================
[   24.445906] BUG: KASAN: slab-out-of-bounds in copy_to_kernel_nofault+0x204/0x250
[   24.445999] Read of size 8 at addr fff00000c7791f78 by task kunit_try_catch/291
[   24.446827] 
[   24.446930] CPU: 0 UID: 0 PID: 291 Comm: kunit_try_catch Tainted: G    B   W        N  6.16.0-rc2-next-20250618 #1 PREEMPT 
[   24.447059] Tainted: [B]=BAD_PAGE, [W]=WARN, [N]=TEST
[   24.447495] Hardware name: linux,dummy-virt (DT)
[   24.447761] Call trace:
[   24.448056]  show_stack+0x20/0x38 (C)
[   24.448143]  dump_stack_lvl+0x8c/0xd0
[   24.448211]  print_report+0x118/0x608
[   24.448602]  kasan_report+0xdc/0x128
[   24.448682]  __asan_report_load8_noabort+0x20/0x30
[   24.449057]  copy_to_kernel_nofault+0x204/0x250
[   24.449260]  copy_to_kernel_nofault_oob+0x158/0x418
[   24.449331]  kunit_try_run_case+0x170/0x3f0
[   24.449862]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   24.449984]  kthread+0x328/0x630
[   24.450213]  ret_from_fork+0x10/0x20
[   24.450430] 
[   24.450685] Allocated by task 291:
[   24.450735]  kasan_save_stack+0x3c/0x68
[   24.451040]  kasan_save_track+0x20/0x40
[   24.451102]  kasan_save_alloc_info+0x40/0x58
[   24.451151]  __kasan_kmalloc+0xd4/0xd8
[   24.451458]  __kmalloc_cache_noprof+0x16c/0x3c0
[   24.451790]  copy_to_kernel_nofault_oob+0xc8/0x418
[   24.451855]  kunit_try_run_case+0x170/0x3f0
[   24.452074]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   24.452234]  kthread+0x328/0x630
[   24.452664]  ret_from_fork+0x10/0x20
[   24.452894] 
[   24.452976] The buggy address belongs to the object at fff00000c7791f00
[   24.452976]  which belongs to the cache kmalloc-128 of size 128
[   24.453231] The buggy address is located 0 bytes to the right of
[   24.453231]  allocated 120-byte region [fff00000c7791f00, fff00000c7791f78)
[   24.453423] 
[   24.453459] The buggy address belongs to the physical page:
[   24.453885] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x107791
[   24.453982] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   24.454431] page_type: f5(slab)
[   24.454576] raw: 0bfffe0000000000 fff00000c0001a00 dead000000000122 0000000000000000
[   24.454646] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   24.454716] page dumped because: kasan: bad access detected
[   24.455126] 
[   24.455162] Memory state around the buggy address:
[   24.455214]  fff00000c7791e00: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   24.455508]  fff00000c7791e80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   24.455565] >fff00000c7791f00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   24.455612]                                                                 ^
[   24.455676]  fff00000c7791f80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   24.455726]  fff00000c7792000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
[   24.455772] ==================================================================

[   14.950619] ==================================================================
[   14.950895] BUG: KASAN: slab-out-of-bounds in copy_to_kernel_nofault+0x99/0x260
[   14.951233] Write of size 8 at addr ffff8881038fb878 by task kunit_try_catch/307
[   14.951652] 
[   14.951745] CPU: 1 UID: 0 PID: 307 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc2-next-20250618 #1 PREEMPT(voluntary) 
[   14.951791] Tainted: [B]=BAD_PAGE, [N]=TEST
[   14.951805] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   14.951826] Call Trace:
[   14.951839]  <TASK>
[   14.951855]  dump_stack_lvl+0x73/0xb0
[   14.951880]  print_report+0xd1/0x650
[   14.951902]  ? __virt_addr_valid+0x1db/0x2d0
[   14.951924]  ? copy_to_kernel_nofault+0x99/0x260
[   14.951946]  ? kasan_complete_mode_report_info+0x2a/0x200
[   14.951972]  ? copy_to_kernel_nofault+0x99/0x260
[   14.951995]  kasan_report+0x141/0x180
[   14.952017]  ? copy_to_kernel_nofault+0x99/0x260
[   14.952045]  kasan_check_range+0x10c/0x1c0
[   14.952068]  __kasan_check_write+0x18/0x20
[   14.952091]  copy_to_kernel_nofault+0x99/0x260
[   14.952115]  copy_to_kernel_nofault_oob+0x288/0x560
[   14.952138]  ? __pfx_copy_to_kernel_nofault_oob+0x10/0x10
[   14.952161]  ? finish_task_switch.isra.0+0x153/0x700
[   14.952184]  ? __schedule+0x10cc/0x2b60
[   14.952214]  ? trace_hardirqs_on+0x37/0xe0
[   14.952245]  ? __pfx_read_tsc+0x10/0x10
[   14.952265]  ? ktime_get_ts64+0x86/0x230
[   14.952290]  kunit_try_run_case+0x1a5/0x480
[   14.952313]  ? __pfx_kunit_try_run_case+0x10/0x10
[   14.952335]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   14.952356]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   14.952379]  ? __kthread_parkme+0x82/0x180
[   14.952398]  ? preempt_count_sub+0x50/0x80
[   14.952421]  ? __pfx_kunit_try_run_case+0x10/0x10
[   14.952444]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   14.952467]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   14.952490]  kthread+0x337/0x6f0
[   14.952510]  ? trace_preempt_on+0x20/0xc0
[   14.952531]  ? __pfx_kthread+0x10/0x10
[   14.952552]  ? _raw_spin_unlock_irq+0x47/0x80
[   14.952572]  ? calculate_sigpending+0x7b/0xa0
[   14.952595]  ? __pfx_kthread+0x10/0x10
[   14.952617]  ret_from_fork+0x116/0x1d0
[   14.952635]  ? __pfx_kthread+0x10/0x10
[   14.952660]  ret_from_fork_asm+0x1a/0x30
[   14.952689]  </TASK>
[   14.952700] 
[   14.959960] Allocated by task 307:
[   14.960080]  kasan_save_stack+0x45/0x70
[   14.960276]  kasan_save_track+0x18/0x40
[   14.960461]  kasan_save_alloc_info+0x3b/0x50
[   14.960775]  __kasan_kmalloc+0xb7/0xc0
[   14.960953]  __kmalloc_cache_noprof+0x189/0x420
[   14.961147]  copy_to_kernel_nofault_oob+0x12f/0x560
[   14.961335]  kunit_try_run_case+0x1a5/0x480
[   14.961482]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   14.961766]  kthread+0x337/0x6f0
[   14.962059]  ret_from_fork+0x116/0x1d0
[   14.962268]  ret_from_fork_asm+0x1a/0x30
[   14.962503] 
[   14.962656] The buggy address belongs to the object at ffff8881038fb800
[   14.962656]  which belongs to the cache kmalloc-128 of size 128
[   14.963156] The buggy address is located 0 bytes to the right of
[   14.963156]  allocated 120-byte region [ffff8881038fb800, ffff8881038fb878)
[   14.963768] 
[   14.963840] The buggy address belongs to the physical page:
[   14.964005] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1038fb
[   14.964341] flags: 0x200000000000000(node=0|zone=2)
[   14.964675] page_type: f5(slab)
[   14.965003] raw: 0200000000000000 ffff888100041a00 dead000000000122 0000000000000000
[   14.965276] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   14.965520] page dumped because: kasan: bad access detected
[   14.967572] 
[   14.967676] Memory state around the buggy address:
[   14.967852]  ffff8881038fb700: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   14.968066]  ffff8881038fb780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   14.968462] >ffff8881038fb800: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   14.968685]                                                                 ^
[   14.968894]  ffff8881038fb880: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   14.969156]  ffff8881038fb900: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   14.969407] ==================================================================
[   14.923668] ==================================================================
[   14.924907] BUG: KASAN: slab-out-of-bounds in copy_to_kernel_nofault+0x225/0x260
[   14.925625] Read of size 8 at addr ffff8881038fb878 by task kunit_try_catch/307
[   14.926250] 
[   14.926563] CPU: 1 UID: 0 PID: 307 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc2-next-20250618 #1 PREEMPT(voluntary) 
[   14.926627] Tainted: [B]=BAD_PAGE, [N]=TEST
[   14.926641] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   14.926665] Call Trace:
[   14.926678]  <TASK>
[   14.926694]  dump_stack_lvl+0x73/0xb0
[   14.926723]  print_report+0xd1/0x650
[   14.926747]  ? __virt_addr_valid+0x1db/0x2d0
[   14.926770]  ? copy_to_kernel_nofault+0x225/0x260
[   14.926793]  ? kasan_complete_mode_report_info+0x2a/0x200
[   14.926819]  ? copy_to_kernel_nofault+0x225/0x260
[   14.926842]  kasan_report+0x141/0x180
[   14.926864]  ? copy_to_kernel_nofault+0x225/0x260
[   14.926892]  __asan_report_load8_noabort+0x18/0x20
[   14.926916]  copy_to_kernel_nofault+0x225/0x260
[   14.926941]  copy_to_kernel_nofault_oob+0x1ed/0x560
[   14.926964]  ? __pfx_copy_to_kernel_nofault_oob+0x10/0x10
[   14.926987]  ? finish_task_switch.isra.0+0x153/0x700
[   14.927010]  ? __schedule+0x10cc/0x2b60
[   14.927031]  ? trace_hardirqs_on+0x37/0xe0
[   14.927062]  ? __pfx_read_tsc+0x10/0x10
[   14.927084]  ? ktime_get_ts64+0x86/0x230
[   14.927109]  kunit_try_run_case+0x1a5/0x480
[   14.927134]  ? __pfx_kunit_try_run_case+0x10/0x10
[   14.927157]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   14.927179]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   14.927201]  ? __kthread_parkme+0x82/0x180
[   14.927235]  ? preempt_count_sub+0x50/0x80
[   14.927257]  ? __pfx_kunit_try_run_case+0x10/0x10
[   14.927280]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   14.927303]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   14.927326]  kthread+0x337/0x6f0
[   14.927345]  ? trace_preempt_on+0x20/0xc0
[   14.927389]  ? __pfx_kthread+0x10/0x10
[   14.927410]  ? _raw_spin_unlock_irq+0x47/0x80
[   14.927431]  ? calculate_sigpending+0x7b/0xa0
[   14.927455]  ? __pfx_kthread+0x10/0x10
[   14.927477]  ret_from_fork+0x116/0x1d0
[   14.927495]  ? __pfx_kthread+0x10/0x10
[   14.927516]  ret_from_fork_asm+0x1a/0x30
[   14.927547]  </TASK>
[   14.927559] 
[   14.939953] Allocated by task 307:
[   14.940333]  kasan_save_stack+0x45/0x70
[   14.940726]  kasan_save_track+0x18/0x40
[   14.941136]  kasan_save_alloc_info+0x3b/0x50
[   14.941558]  __kasan_kmalloc+0xb7/0xc0
[   14.941893]  __kmalloc_cache_noprof+0x189/0x420
[   14.942334]  copy_to_kernel_nofault_oob+0x12f/0x560
[   14.942791]  kunit_try_run_case+0x1a5/0x480
[   14.943129]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   14.943444]  kthread+0x337/0x6f0
[   14.943754]  ret_from_fork+0x116/0x1d0
[   14.944171]  ret_from_fork_asm+0x1a/0x30
[   14.944473] 
[   14.944568] The buggy address belongs to the object at ffff8881038fb800
[   14.944568]  which belongs to the cache kmalloc-128 of size 128
[   14.944922] The buggy address is located 0 bytes to the right of
[   14.944922]  allocated 120-byte region [ffff8881038fb800, ffff8881038fb878)
[   14.945355] 
[   14.945427] The buggy address belongs to the physical page:
[   14.945871] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1038fb
[   14.946621] flags: 0x200000000000000(node=0|zone=2)
[   14.946875] page_type: f5(slab)
[   14.946993] raw: 0200000000000000 ffff888100041a00 dead000000000122 0000000000000000
[   14.947252] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   14.947474] page dumped because: kasan: bad access detected
[   14.947834] 
[   14.948003] Memory state around the buggy address:
[   14.948155]  ffff8881038fb700: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   14.948394]  ffff8881038fb780: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   14.948688] >ffff8881038fb800: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   14.949042]                                                                 ^
[   14.949384]  ffff8881038fb880: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   14.949647]  ffff8881038fb900: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   14.950001] ==================================================================