================================================================== BUG: KASAN: slab-out-of-bounds in instrument_atomic_write include/linux/instrumented.h:82 [inline] BUG: KASAN: slab-out-of-bounds in clear_bit include/asm-generic/bitops/instrumented-atomic.h:41 [inline] BUG: KASAN: slab-out-of-bounds in mm_drop_cid kernel/sched/sched.h:3746 [inline] BUG: KASAN: slab-out-of-bounds in mm_cid_schedout kernel/sched/sched.h:3927 [inline] BUG: KASAN: slab-out-of-bounds in mm_cid_switch_to kernel/sched/sched.h:3934 [inline] BUG: KASAN: slab-out-of-bounds in context_switch kernel/sched/core.c:5249 [inline] BUG: KASAN: slab-out-of-bounds in __schedule+0x3ca9/0x5fa0 kernel/sched/core.c:6867 Write of size 8 at addr ffff88801b8b79d0 by task syz.2.2749/1970 CPU: 1 UID: 0 PID: 1970 Comm: syz.2.2749 Tainted: G L syzkaller #0 PREEMPT(full) Tainted: [L]=SOFTLOCKUP Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 Call Trace: __dump_stack lib/dump_stack.c:94 [inline] dump_stack_lvl+0x100/0x190 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0x156/0x4c9 mm/kasan/report.c:482 kasan_report+0xdf/0x1a0 mm/kasan/report.c:595 check_region_inline mm/kasan/generic.c:186 [inline] kasan_check_range+0x10f/0x1e0 mm/kasan/generic.c:200 instrument_atomic_write include/linux/instrumented.h:82 [inline] clear_bit include/asm-generic/bitops/instrumented-atomic.h:41 [inline] mm_drop_cid kernel/sched/sched.h:3746 [inline] mm_cid_schedout kernel/sched/sched.h:3927 [inline] mm_cid_switch_to kernel/sched/sched.h:3934 [inline] context_switch kernel/sched/core.c:5249 [inline] __schedule+0x3ca9/0x5fa0 kernel/sched/core.c:6867 preempt_schedule_common+0x42/0xc0 kernel/sched/core.c:7051 preempt_schedule_thunk+0x16/0x30 arch/x86/entry/thunk.S:12 class_preempt_destructor include/linux/preempt.h:468 [inline] try_to_wake_up+0x644/0x1a60 kernel/sched/core.c:4070 io_acct_activate_free_worker+0x1e5/0x2d0 io_uring/io-wq.c:309 create_worker_cb+0xbf/0x380 io_uring/io-wq.c:362 task_work_run+0x150/0x240 kernel/task_work.c:233 get_signal+0x1bd/0x21e0 kernel/signal.c:2807 arch_do_signal_or_restart+0x91/0x770 arch/x86/kernel/signal.c:337 __exit_to_user_mode_loop kernel/entry/common.c:41 [inline] exit_to_user_mode_loop+0x86/0x4b0 kernel/entry/common.c:75 __exit_to_user_mode_prepare include/linux/irq-entry-common.h:226 [inline] syscall_exit_to_user_mode_prepare include/linux/irq-entry-common.h:256 [inline] syscall_exit_to_user_mode_work include/linux/entry-common.h:159 [inline] syscall_exit_to_user_mode include/linux/entry-common.h:194 [inline] __do_fast_syscall_32+0x4b6/0x660 arch/x86/entry/syscall_32.c:310 do_fast_syscall_32+0x32/0x70 arch/x86/entry/syscall_32.c:332 entry_SYSENTER_compat_after_hwframe+0x84/0x8e RIP: 0023:0xf7fc2579 Code: b8 01 10 06 03 74 b4 01 10 07 03 74 b0 01 10 08 03 74 d8 01 00 00 00 00 00 00 00 00 00 00 00 00 00 51 52 55 89 e5 0f 34 cd 80 <5d> 5a 59 c3 90 90 90 90 2e 8d b4 26 00 00 00 00 8d b4 26 00 00 00 RSP: 002b:00000000f544450c EFLAGS: 00000292 ORIG_RAX: 00000000000001aa RAX: 0000000000000800 RBX: 0000000000000007 RCX: 0000000000003516 RDX: 000000000000addf RSI: 0000000000000002 RDI: 0000000000000000 RBP: 000000000001517f R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000292 R12: 0000000000000000 R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000 Allocated by task 0: kasan_save_stack+0x30/0x50 mm/kasan/common.c:57 kasan_save_track+0x14/0x30 mm/kasan/common.c:78 poison_kmalloc_redzone mm/kasan/common.c:398 [inline] __kasan_kmalloc+0xaa/0xb0 mm/kasan/common.c:415 kmalloc_node_noprof include/linux/slab.h:983 [inline] perf_pmu_register+0x318/0xc90 kernel/events/core.c:12472 perf_event_init+0x149/0x670 kernel/events/core.c:14906 start_kernel+0x2b2/0x480 init/main.c:1128 x86_64_start_reservations+0x24/0x30 arch/x86/kernel/head64.c:310 x86_64_start_kernel+0x122/0x130 arch/x86/kernel/head64.c:291 common_startup_64+0x13e/0x148 The buggy address belongs to the object at ffff88801b8b7800 which belongs to the cache kmalloc-512 of size 512 The buggy address is located 168 bytes to the right of allocated 296-byte region [ffff88801b8b7800, ffff88801b8b7928) The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x1b8b4 head: order:2 mapcount:0 entire_mapcount:0 nr_pages_mapped:0 pincount:0 anon flags: 0xfff00000000040(head|node=0|zone=1|lastcpupid=0x7ff) page_type: f5(slab) raw: 00fff00000000040 ffff88801b842c80 0000000000000000 dead000000000001 raw: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000 head: 00fff00000000040 ffff88801b842c80 0000000000000000 dead000000000001 head: 0000000000000000 0000000000100010 00000000f5000000 0000000000000000 head: 00fff00000000002 ffffea00006e2d01 00000000ffffffff 00000000ffffffff head: ffffffffffffffff 0000000000000000 00000000ffffffff 0000000000000004 page dumped because: kasan: bad access detected page_owner tracks the page as allocated page last allocated via order 2, migratetype Unmovable, gfp_mask 0x52000(__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP), pid 0, tgid 0 (swapper/0), ts 953495319, free_ts 0 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x1e1/0x250 mm/page_alloc.c:1884 prep_new_page mm/page_alloc.c:1892 [inline] get_page_from_freelist+0xe3d/0x2e10 mm/page_alloc.c:3945 __alloc_frozen_pages_noprof+0x26c/0x2410 mm/page_alloc.c:5240 alloc_pages_mpol+0x1fb/0x550 mm/mempolicy.c:2486 alloc_slab_page mm/slub.c:3075 [inline] allocate_slab mm/slub.c:3248 [inline] new_slab+0x2c4/0x440 mm/slub.c:3302 ___slab_alloc+0xda3/0x1ca0 mm/slub.c:4656 __slab_alloc.isra.0+0x63/0x110 mm/slub.c:4779 __slab_alloc_node mm/slub.c:4855 [inline] slab_alloc_node mm/slub.c:5251 [inline] __do_kmalloc_node mm/slub.c:5656 [inline] __kmalloc_noprof+0x618/0x9c0 mm/slub.c:5669 kmalloc_noprof include/linux/slab.h:961 [inline] kzalloc_noprof include/linux/slab.h:1094 [inline] __alloc_workqueue+0xd62/0x1880 kernel/workqueue.c:5717 alloc_workqueue_noprof+0xd2/0x200 kernel/workqueue.c:5820 workqueue_init_early+0xb21/0xc70 kernel/workqueue.c:7854 start_kernel+0x227/0x480 init/main.c:1097 x86_64_start_reservations+0x24/0x30 arch/x86/kernel/head64.c:310 x86_64_start_kernel+0x122/0x130 arch/x86/kernel/head64.c:291 common_startup_64+0x13e/0x148 page_owner free stack trace missing Memory state around the buggy address: ffff88801b8b7880: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff88801b8b7900: 00 00 00 00 00 fc fc fc fc fc fc fc fc fc fc fc >ffff88801b8b7980: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ^ ffff88801b8b7a00: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ffff88801b8b7a80: fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc fc ================================================================== ---------------- Code disassembly (best guess), 2 bytes skipped: 0: 10 06 adc %al,(%rsi) 2: 03 74 b4 01 add 0x1(%rsp,%rsi,4),%esi 6: 10 07 adc %al,(%rdi) 8: 03 74 b0 01 add 0x1(%rax,%rsi,4),%esi c: 10 08 adc %cl,(%rax) e: 03 74 d8 01 add 0x1(%rax,%rbx,8),%esi 1e: 00 51 52 add %dl,0x52(%rcx) 21: 55 push %rbp 22: 89 e5 mov %esp,%ebp 24: 0f 34 sysenter 26: cd 80 int $0x80 * 28: 5d pop %rbp <-- trapping instruction 29: 5a pop %rdx 2a: 59 pop %rcx 2b: c3 ret 2c: 90 nop 2d: 90 nop 2e: 90 nop 2f: 90 nop 30: 2e 8d b4 26 00 00 00 cs lea 0x0(%rsi,%riz,1),%esi 37: 00 38: 8d .byte 0x8d 39: b4 26 mov $0x26,%ah 3b: 00 00 add %al,(%rax)