Hay
Date
July 9, 2025, 1:08 p.m.

Environment
qemu-arm64
qemu-x86_64

[   32.498653] ==================================================================
[   32.498975] BUG: KASAN: slab-out-of-bounds in copy_to_kernel_nofault+0x8c/0x250
[   32.499146] Write of size 8 at addr fff00000c9c2a278 by task kunit_try_catch/313
[   32.499242] 
[   32.499297] CPU: 1 UID: 0 PID: 313 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc5-next-20250709 #1 PREEMPT 
[   32.499479] Tainted: [B]=BAD_PAGE, [N]=TEST
[   32.499510] Hardware name: linux,dummy-virt (DT)
[   32.499561] Call trace:
[   32.499893]  show_stack+0x20/0x38 (C)
[   32.499979]  dump_stack_lvl+0x8c/0xd0
[   32.500206]  print_report+0x118/0x5d0
[   32.500472]  kasan_report+0xdc/0x128
[   32.500538]  kasan_check_range+0x100/0x1a8
[   32.500587]  __kasan_check_write+0x20/0x30
[   32.501174]  copy_to_kernel_nofault+0x8c/0x250
[   32.501440]  copy_to_kernel_nofault_oob+0x1bc/0x418
[   32.501652]  kunit_try_run_case+0x170/0x3f0
[   32.501966]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   32.502184]  kthread+0x328/0x630
[   32.502235]  ret_from_fork+0x10/0x20
[   32.502464] 
[   32.502491] Allocated by task 313:
[   32.502837]  kasan_save_stack+0x3c/0x68
[   32.503009]  kasan_save_track+0x20/0x40
[   32.503161]  kasan_save_alloc_info+0x40/0x58
[   32.503276]  __kasan_kmalloc+0xd4/0xd8
[   32.503389]  __kmalloc_cache_noprof+0x16c/0x3c0
[   32.503464]  copy_to_kernel_nofault_oob+0xc8/0x418
[   32.503520]  kunit_try_run_case+0x170/0x3f0
[   32.503572]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   32.503756]  kthread+0x328/0x630
[   32.503912]  ret_from_fork+0x10/0x20
[   32.503997] 
[   32.504155] The buggy address belongs to the object at fff00000c9c2a200
[   32.504155]  which belongs to the cache kmalloc-128 of size 128
[   32.504340] The buggy address is located 0 bytes to the right of
[   32.504340]  allocated 120-byte region [fff00000c9c2a200, fff00000c9c2a278)
[   32.504622] 
[   32.504723] The buggy address belongs to the physical page:
[   32.504858] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x109c2a
[   32.504916] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   32.505122] page_type: f5(slab)
[   32.505336] raw: 0bfffe0000000000 fff00000c0001a00 dead000000000122 0000000000000000
[   32.505414] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   32.505594] page dumped because: kasan: bad access detected
[   32.506013] 
[   32.506163] Memory state around the buggy address:
[   32.506403]  fff00000c9c2a100: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   32.506500]  fff00000c9c2a180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   32.506878] >fff00000c9c2a200: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   32.507247]                                                                 ^
[   32.507353]  fff00000c9c2a280: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   32.507402]  fff00000c9c2a300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   32.507455] ==================================================================
[   32.490330] ==================================================================
[   32.490467] BUG: KASAN: slab-out-of-bounds in copy_to_kernel_nofault+0x204/0x250
[   32.490537] Read of size 8 at addr fff00000c9c2a278 by task kunit_try_catch/313
[   32.490590] 
[   32.490740] CPU: 1 UID: 0 PID: 313 Comm: kunit_try_catch Tainted: G    B            N  6.16.0-rc5-next-20250709 #1 PREEMPT 
[   32.490839] Tainted: [B]=BAD_PAGE, [N]=TEST
[   32.491167] Hardware name: linux,dummy-virt (DT)
[   32.491224] Call trace:
[   32.491263]  show_stack+0x20/0x38 (C)
[   32.491374]  dump_stack_lvl+0x8c/0xd0
[   32.491434]  print_report+0x118/0x5d0
[   32.491511]  kasan_report+0xdc/0x128
[   32.491636]  __asan_report_load8_noabort+0x20/0x30
[   32.491712]  copy_to_kernel_nofault+0x204/0x250
[   32.491880]  copy_to_kernel_nofault_oob+0x158/0x418
[   32.491934]  kunit_try_run_case+0x170/0x3f0
[   32.491987]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   32.492290]  kthread+0x328/0x630
[   32.492469]  ret_from_fork+0x10/0x20
[   32.492715] 
[   32.492740] Allocated by task 313:
[   32.492817]  kasan_save_stack+0x3c/0x68
[   32.493070]  kasan_save_track+0x20/0x40
[   32.493354]  kasan_save_alloc_info+0x40/0x58
[   32.493463]  __kasan_kmalloc+0xd4/0xd8
[   32.493589]  __kmalloc_cache_noprof+0x16c/0x3c0
[   32.493635]  copy_to_kernel_nofault_oob+0xc8/0x418
[   32.493905]  kunit_try_run_case+0x170/0x3f0
[   32.494098]  kunit_generic_run_threadfn_adapter+0x88/0x100
[   32.494277]  kthread+0x328/0x630
[   32.494419]  ret_from_fork+0x10/0x20
[   32.494773] 
[   32.494830] The buggy address belongs to the object at fff00000c9c2a200
[   32.494830]  which belongs to the cache kmalloc-128 of size 128
[   32.495046] The buggy address is located 0 bytes to the right of
[   32.495046]  allocated 120-byte region [fff00000c9c2a200, fff00000c9c2a278)
[   32.495145] 
[   32.495192] The buggy address belongs to the physical page:
[   32.495227] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x109c2a
[   32.495354] flags: 0xbfffe0000000000(node=0|zone=2|lastcpupid=0x1ffff)
[   32.495419] page_type: f5(slab)
[   32.495466] raw: 0bfffe0000000000 fff00000c0001a00 dead000000000122 0000000000000000
[   32.495529] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   32.495572] page dumped because: kasan: bad access detected
[   32.495608] 
[   32.495627] Memory state around the buggy address:
[   32.495920]  fff00000c9c2a100: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   32.495974]  fff00000c9c2a180: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   32.496021] >fff00000c9c2a200: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   32.496312]                                                                 ^
[   32.496487]  fff00000c9c2a280: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   32.496593]  fff00000c9c2a300: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   32.496654] ==================================================================

[   27.972054] ==================================================================
[   27.972362] BUG: KASAN: slab-out-of-bounds in copy_to_kernel_nofault+0x99/0x260
[   27.972683] Write of size 8 at addr ffff8881060ac578 by task kunit_try_catch/331
[   27.973178] 
[   27.973315] CPU: 1 UID: 0 PID: 331 Comm: kunit_try_catch Tainted: G    B   W        N  6.16.0-rc5-next-20250709 #1 PREEMPT(voluntary) 
[   27.973418] Tainted: [B]=BAD_PAGE, [W]=WARN, [N]=TEST
[   27.973435] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   27.973459] Call Trace:
[   27.973480]  <TASK>
[   27.973502]  dump_stack_lvl+0x73/0xb0
[   27.973535]  print_report+0xd1/0x610
[   27.973559]  ? __virt_addr_valid+0x1db/0x2d0
[   27.973607]  ? copy_to_kernel_nofault+0x99/0x260
[   27.973632]  ? kasan_complete_mode_report_info+0x2a/0x200
[   27.973659]  ? copy_to_kernel_nofault+0x99/0x260
[   27.973683]  kasan_report+0x141/0x180
[   27.973718]  ? copy_to_kernel_nofault+0x99/0x260
[   27.973747]  kasan_check_range+0x10c/0x1c0
[   27.973798]  __kasan_check_write+0x18/0x20
[   27.973822]  copy_to_kernel_nofault+0x99/0x260
[   27.973847]  copy_to_kernel_nofault_oob+0x288/0x560
[   27.973871]  ? __pfx_copy_to_kernel_nofault_oob+0x10/0x10
[   27.973952]  ? finish_task_switch.isra.0+0x153/0x700
[   27.973980]  ? __schedule+0x10cc/0x2b60
[   27.974004]  ? trace_hardirqs_on+0x37/0xe0
[   27.974037]  ? __pfx_read_tsc+0x10/0x10
[   27.974060]  ? ktime_get_ts64+0x86/0x230
[   27.974086]  kunit_try_run_case+0x1a5/0x480
[   27.974110]  ? __pfx_kunit_try_run_case+0x10/0x10
[   27.974131]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   27.974156]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   27.974181]  ? __kthread_parkme+0x82/0x180
[   27.974203]  ? preempt_count_sub+0x50/0x80
[   27.974226]  ? __pfx_kunit_try_run_case+0x10/0x10
[   27.974249]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   27.974275]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   27.974301]  kthread+0x337/0x6f0
[   27.974321]  ? trace_preempt_on+0x20/0xc0
[   27.974344]  ? __pfx_kthread+0x10/0x10
[   27.974365]  ? _raw_spin_unlock_irq+0x47/0x80
[   27.974388]  ? calculate_sigpending+0x7b/0xa0
[   27.974414]  ? __pfx_kthread+0x10/0x10
[   27.974436]  ret_from_fork+0x116/0x1d0
[   27.974456]  ? __pfx_kthread+0x10/0x10
[   27.974477]  ret_from_fork_asm+0x1a/0x30
[   27.974510]  </TASK>
[   27.974523] 
[   27.982909] Allocated by task 331:
[   27.983133]  kasan_save_stack+0x45/0x70
[   27.983427]  kasan_save_track+0x18/0x40
[   27.983600]  kasan_save_alloc_info+0x3b/0x50
[   27.983777]  __kasan_kmalloc+0xb7/0xc0
[   27.984062]  __kmalloc_cache_noprof+0x189/0x420
[   27.984636]  copy_to_kernel_nofault_oob+0x12f/0x560
[   27.984892]  kunit_try_run_case+0x1a5/0x480
[   27.985097]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   27.985341]  kthread+0x337/0x6f0
[   27.985510]  ret_from_fork+0x116/0x1d0
[   27.985705]  ret_from_fork_asm+0x1a/0x30
[   27.985925] 
[   27.986045] The buggy address belongs to the object at ffff8881060ac500
[   27.986045]  which belongs to the cache kmalloc-128 of size 128
[   27.986592] The buggy address is located 0 bytes to the right of
[   27.986592]  allocated 120-byte region [ffff8881060ac500, ffff8881060ac578)
[   27.987022] 
[   27.987164] The buggy address belongs to the physical page:
[   27.987455] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1060ac
[   27.988130] flags: 0x200000000000000(node=0|zone=2)
[   27.988332] page_type: f5(slab)
[   27.988502] raw: 0200000000000000 ffff888100041a00 dead000000000122 0000000000000000
[   27.989023] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   27.989340] page dumped because: kasan: bad access detected
[   27.989564] 
[   27.989629] Memory state around the buggy address:
[   27.989996]  ffff8881060ac400: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   27.990297]  ffff8881060ac480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   27.990630] >ffff8881060ac500: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   27.990977]                                                                 ^
[   27.991299]  ffff8881060ac580: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   27.991602]  ffff8881060ac600: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   27.991885] ==================================================================
[   27.940768] ==================================================================
[   27.941770] BUG: KASAN: slab-out-of-bounds in copy_to_kernel_nofault+0x225/0x260
[   27.942789] Read of size 8 at addr ffff8881060ac578 by task kunit_try_catch/331
[   27.943191] 
[   27.943690] CPU: 1 UID: 0 PID: 331 Comm: kunit_try_catch Tainted: G    B   W        N  6.16.0-rc5-next-20250709 #1 PREEMPT(voluntary) 
[   27.943768] Tainted: [B]=BAD_PAGE, [W]=WARN, [N]=TEST
[   27.943797] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014
[   27.943847] Call Trace:
[   27.943864]  <TASK>
[   27.944009]  dump_stack_lvl+0x73/0xb0
[   27.944051]  print_report+0xd1/0x610
[   27.944078]  ? __virt_addr_valid+0x1db/0x2d0
[   27.944106]  ? copy_to_kernel_nofault+0x225/0x260
[   27.944130]  ? kasan_complete_mode_report_info+0x2a/0x200
[   27.944158]  ? copy_to_kernel_nofault+0x225/0x260
[   27.944182]  kasan_report+0x141/0x180
[   27.944205]  ? copy_to_kernel_nofault+0x225/0x260
[   27.944233]  __asan_report_load8_noabort+0x18/0x20
[   27.944258]  copy_to_kernel_nofault+0x225/0x260
[   27.944284]  copy_to_kernel_nofault_oob+0x1ed/0x560
[   27.944308]  ? __pfx_copy_to_kernel_nofault_oob+0x10/0x10
[   27.944331]  ? finish_task_switch.isra.0+0x153/0x700
[   27.944356]  ? __schedule+0x10cc/0x2b60
[   27.944381]  ? trace_hardirqs_on+0x37/0xe0
[   27.944414]  ? __pfx_read_tsc+0x10/0x10
[   27.944438]  ? ktime_get_ts64+0x86/0x230
[   27.944465]  kunit_try_run_case+0x1a5/0x480
[   27.944491]  ? __pfx_kunit_try_run_case+0x10/0x10
[   27.944512]  ? _raw_spin_lock_irqsave+0xa1/0x100
[   27.944537]  ? _raw_spin_unlock_irqrestore+0x5f/0x90
[   27.944562]  ? __kthread_parkme+0x82/0x180
[   27.944584]  ? preempt_count_sub+0x50/0x80
[   27.944607]  ? __pfx_kunit_try_run_case+0x10/0x10
[   27.944630]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   27.944656]  ? __pfx_kunit_generic_run_threadfn_adapter+0x10/0x10
[   27.944681]  kthread+0x337/0x6f0
[   27.944713]  ? trace_preempt_on+0x20/0xc0
[   27.944737]  ? __pfx_kthread+0x10/0x10
[   27.944758]  ? _raw_spin_unlock_irq+0x47/0x80
[   27.944794]  ? calculate_sigpending+0x7b/0xa0
[   27.944820]  ? __pfx_kthread+0x10/0x10
[   27.944843]  ret_from_fork+0x116/0x1d0
[   27.944863]  ? __pfx_kthread+0x10/0x10
[   27.944892]  ret_from_fork_asm+0x1a/0x30
[   27.944925]  </TASK>
[   27.944939] 
[   27.957490] Allocated by task 331:
[   27.957862]  kasan_save_stack+0x45/0x70
[   27.958213]  kasan_save_track+0x18/0x40
[   27.958555]  kasan_save_alloc_info+0x3b/0x50
[   27.959272]  __kasan_kmalloc+0xb7/0xc0
[   27.959638]  __kmalloc_cache_noprof+0x189/0x420
[   27.959911]  copy_to_kernel_nofault_oob+0x12f/0x560
[   27.960120]  kunit_try_run_case+0x1a5/0x480
[   27.960302]  kunit_generic_run_threadfn_adapter+0x85/0xf0
[   27.960848]  kthread+0x337/0x6f0
[   27.961186]  ret_from_fork+0x116/0x1d0
[   27.961558]  ret_from_fork_asm+0x1a/0x30
[   27.961991] 
[   27.962167] The buggy address belongs to the object at ffff8881060ac500
[   27.962167]  which belongs to the cache kmalloc-128 of size 128
[   27.962981] The buggy address is located 0 bytes to the right of
[   27.962981]  allocated 120-byte region [ffff8881060ac500, ffff8881060ac578)
[   27.963329] 
[   27.963399] The buggy address belongs to the physical page:
[   27.963565] page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1060ac
[   27.964210] flags: 0x200000000000000(node=0|zone=2)
[   27.964633] page_type: f5(slab)
[   27.964976] raw: 0200000000000000 ffff888100041a00 dead000000000122 0000000000000000
[   27.965623] raw: 0000000000000000 0000000080100010 00000000f5000000 0000000000000000
[   27.966384] page dumped because: kasan: bad access detected
[   27.966959] 
[   27.967122] Memory state around the buggy address:
[   27.967701]  ffff8881060ac400: fa fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
[   27.968414]  ffff8881060ac480: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   27.969096] >ffff8881060ac500: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 fc
[   27.969795]                                                                 ^
[   27.970463]  ffff8881060ac580: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   27.971184]  ffff8881060ac600: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc
[   27.971418] ==================================================================