FAULT_INJECTION: forcing a failure. name fail_usercopy, interval 1, probability 0, space 0, times 0 ====================================================== WARNING: possible circular locking dependency detected 6.15.0-syzkaller-g3ce7cdde66e6 #0 Not tainted ------------------------------------------------------ syz.2.140/6353 is trying to acquire lock: ffffffff8e133280 (console_owner){-...}-{0:0}, at: console_trylock_spinning kernel/printk/printk.c:2048 [inline] ffffffff8e133280 (console_owner){-...}-{0:0}, at: vprintk_emit+0x444/0x7a0 kernel/printk/printk.c:2449 but task is already holding lock: ffff8880b873b918 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x2a/0x140 kernel/sched/core.c:606 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #4 (&rq->__lock){-.-.}-{2:2}: lock_acquire+0x120/0x360 kernel/locking/lockdep.c:5871 _raw_spin_lock_nested+0x32/0x50 kernel/locking/spinlock.c:378 raw_spin_rq_lock_nested+0x2a/0x140 kernel/sched/core.c:606 raw_spin_rq_lock kernel/sched/sched.h:1532 [inline] task_rq_lock+0xbc/0x470 kernel/sched/core.c:708 cgroup_move_task+0x9a/0x590 kernel/sched/psi.c:1161 css_set_move_task+0x658/0x9e0 kernel/cgroup/cgroup.c:918 cgroup_post_fork+0x1ef/0x790 kernel/cgroup/cgroup.c:6759 copy_process+0x3862/0x3c00 kernel/fork.c:2413 kernel_clone+0x21e/0x870 kernel/fork.c:2599 user_mode_thread+0xdd/0x140 kernel/fork.c:2677 rest_init+0x23/0x300 init/main.c:709 start_kernel+0x47d/0x500 init/main.c:1101 x86_64_start_reservations+0x24/0x30 arch/x86/kernel/head64.c:307 x86_64_start_kernel+0x143/0x1c0 arch/x86/kernel/head64.c:288 common_startup_64+0x13e/0x147 -> #3 (&p->pi_lock){-.-.}-{2:2}: lock_acquire+0x120/0x360 kernel/locking/lockdep.c:5871 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0xa7/0xf0 kernel/locking/spinlock.c:162 class_raw_spinlock_irqsave_constructor include/linux/spinlock.h:557 [inline] try_to_wake_up+0x6e/0x1290 kernel/sched/core.c:4226 __wake_up_common kernel/sched/wait.c:89 [inline] __wake_up_common_lock+0x134/0x1f0 kernel/sched/wait.c:106 tty_port_default_wakeup+0xa2/0xf0 drivers/tty/tty_port.c:69 serial8250_tx_chars+0x72e/0x970 drivers/tty/serial/8250/8250_port.c:1842 serial8250_handle_irq+0x633/0xbb0 drivers/tty/serial/8250/8250_port.c:1950 serial8250_default_handle_irq+0xbf/0x1b0 drivers/tty/serial/8250/8250_port.c:1970 serial8250_interrupt+0xa2/0x1d0 drivers/tty/serial/8250/8250_core.c:86 __handle_irq_event_percpu+0x28c/0x980 kernel/irq/handle.c:158 handle_irq_event_percpu kernel/irq/handle.c:193 [inline] handle_irq_event+0x8b/0x1e0 kernel/irq/handle.c:210 handle_edge_irq+0x267/0x9c0 kernel/irq/chip.c:789 generic_handle_irq_desc include/linux/irqdesc.h:173 [inline] handle_irq arch/x86/kernel/irq.c:254 [inline] call_irq_handler arch/x86/kernel/irq.c:266 [inline] __common_interrupt+0x143/0x250 arch/x86/kernel/irq.c:292 common_interrupt+0xb6/0xe0 arch/x86/kernel/irq.c:285 asm_common_interrupt+0x26/0x40 arch/x86/include/asm/idtentry.h:693 native_safe_halt arch/x86/include/asm/irqflags.h:48 [inline] pv_native_safe_halt+0x13/0x20 arch/x86/kernel/paravirt.c:81 arch_safe_halt arch/x86/include/asm/paravirt.h:107 [inline] default_idle+0x13/0x20 arch/x86/kernel/process.c:743 default_idle_call+0x74/0xb0 kernel/sched/idle.c:117 cpuidle_idle_call kernel/sched/idle.c:185 [inline] do_idle+0x1e8/0x510 kernel/sched/idle.c:325 cpu_startup_entry+0x44/0x60 kernel/sched/idle.c:423 rest_init+0x2de/0x300 init/main.c:744 start_kernel+0x47d/0x500 init/main.c:1101 x86_64_start_reservations+0x24/0x30 arch/x86/kernel/head64.c:307 x86_64_start_kernel+0x143/0x1c0 arch/x86/kernel/head64.c:288 common_startup_64+0x13e/0x147 -> #2 (&tty->write_wait){-.-.}-{3:3}: lock_acquire+0x120/0x360 kernel/locking/lockdep.c:5871 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0xa7/0xf0 kernel/locking/spinlock.c:162 __wake_up_common_lock+0x2f/0x1f0 kernel/sched/wait.c:105 tty_port_default_wakeup+0xa2/0xf0 drivers/tty/tty_port.c:69 serial8250_tx_chars+0x72e/0x970 drivers/tty/serial/8250/8250_port.c:1842 serial8250_handle_irq+0x633/0xbb0 drivers/tty/serial/8250/8250_port.c:1950 serial8250_default_handle_irq+0xbf/0x1b0 drivers/tty/serial/8250/8250_port.c:1970 serial8250_interrupt+0xa2/0x1d0 drivers/tty/serial/8250/8250_core.c:86 __handle_irq_event_percpu+0x28c/0x980 kernel/irq/handle.c:158 handle_irq_event_percpu kernel/irq/handle.c:193 [inline] handle_irq_event+0x8b/0x1e0 kernel/irq/handle.c:210 handle_edge_irq+0x267/0x9c0 kernel/irq/chip.c:789 generic_handle_irq_desc include/linux/irqdesc.h:173 [inline] handle_irq arch/x86/kernel/irq.c:254 [inline] call_irq_handler arch/x86/kernel/irq.c:266 [inline] __common_interrupt+0x143/0x250 arch/x86/kernel/irq.c:292 common_interrupt+0xb6/0xe0 arch/x86/kernel/irq.c:285 asm_common_interrupt+0x26/0x40 arch/x86/include/asm/idtentry.h:693 __raw_spin_unlock_irqrestore include/linux/spinlock_api_smp.h:152 [inline] _raw_spin_unlock_irqrestore+0xa8/0x110 kernel/locking/spinlock.c:194 spin_unlock_irqrestore include/linux/spinlock.h:406 [inline] uart_port_unlock_irqrestore include/linux/serial_core.h:786 [inline] uart_write+0x3ba/0xa40 drivers/tty/serial/serial_core.c:636 process_output_block drivers/tty/n_tty.c:561 [inline] n_tty_write+0xd35/0x11d0 drivers/tty/n_tty.c:2377 iterate_tty_write drivers/tty/tty_io.c:1015 [inline] file_tty_write+0x503/0x990 drivers/tty/tty_io.c:1090 new_sync_write fs/read_write.c:593 [inline] vfs_write+0x54b/0xa90 fs/read_write.c:686 ksys_write+0x145/0x250 fs/read_write.c:738 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0x3b0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f -> #1 (&port_lock_key){-.-.}-{3:3}: lock_acquire+0x120/0x360 kernel/locking/lockdep.c:5871 __raw_spin_lock_irqsave include/linux/spinlock_api_smp.h:110 [inline] _raw_spin_lock_irqsave+0xa7/0xf0 kernel/locking/spinlock.c:162 uart_port_lock_irqsave include/linux/serial_core.h:715 [inline] serial8250_console_write+0x17e/0x1ba0 drivers/tty/serial/8250/8250_port.c:3415 console_emit_next_record kernel/printk/printk.c:3138 [inline] console_flush_all+0x728/0xc40 kernel/printk/printk.c:3226 __console_flush_and_unlock kernel/printk/printk.c:3285 [inline] console_unlock+0xc4/0x270 kernel/printk/printk.c:3325 vprintk_emit+0x5b7/0x7a0 kernel/printk/printk.c:2450 _printk+0xcf/0x120 kernel/printk/printk.c:2475 register_console+0xa8b/0xf90 kernel/printk/printk.c:4125 univ8250_console_init+0x52/0x90 drivers/tty/serial/8250/8250_core.c:513 console_init+0x1a1/0x670 kernel/printk/printk.c:4323 start_kernel+0x2cc/0x500 init/main.c:1035 x86_64_start_reservations+0x24/0x30 arch/x86/kernel/head64.c:307 x86_64_start_kernel+0x143/0x1c0 arch/x86/kernel/head64.c:288 common_startup_64+0x13e/0x147 -> #0 (console_owner){-...}-{0:0}: check_prev_add kernel/locking/lockdep.c:3168 [inline] check_prevs_add kernel/locking/lockdep.c:3287 [inline] validate_chain+0xb9b/0x2140 kernel/locking/lockdep.c:3911 __lock_acquire+0xab9/0xd20 kernel/locking/lockdep.c:5240 lock_acquire+0x120/0x360 kernel/locking/lockdep.c:5871 console_trylock_spinning kernel/printk/printk.c:2048 [inline] vprintk_emit+0x460/0x7a0 kernel/printk/printk.c:2449 _printk+0xcf/0x120 kernel/printk/printk.c:2475 fail_dump lib/fault-inject.c:66 [inline] should_fail_ex+0x3f5/0x560 lib/fault-inject.c:174 strncpy_from_user+0x36/0x290 lib/strncpy_from_user.c:118 strncpy_from_user_nofault+0x72/0x150 mm/maccess.c:193 bpf_probe_read_user_str_common kernel/trace/bpf_trace.c:215 [inline] ____bpf_probe_read_compat_str kernel/trace/bpf_trace.c:310 [inline] bpf_probe_read_compat_str+0xe2/0x180 kernel/trace/bpf_trace.c:306 bpf_prog_d151c66365667d32+0x5d/0x63 bpf_dispatcher_nop_func include/linux/bpf.h:1322 [inline] __bpf_prog_run include/linux/filter.h:718 [inline] bpf_prog_run include/linux/filter.h:725 [inline] __bpf_trace_run kernel/trace/bpf_trace.c:2258 [inline] bpf_trace_run2+0x281/0x4b0 kernel/trace/bpf_trace.c:2299 __bpf_trace_tlb_flush+0xf5/0x150 include/trace/events/tlb.h:38 __do_trace_tlb_flush include/trace/events/tlb.h:38 [inline] trace_tlb_flush+0x115/0x140 include/trace/events/tlb.h:38 switch_mm_irqs_off+0x53e/0x7a0 arch/x86/mm/tlb.c:-1 context_switch kernel/sched/core.c:5380 [inline] __schedule+0x106c/0x4d00 kernel/sched/core.c:6785 preempt_schedule_common+0x83/0xd0 kernel/sched/core.c:6965 preempt_schedule+0xae/0xc0 kernel/sched/core.c:6989 preempt_schedule_thunk+0x16/0x30 arch/x86/entry/thunk.S:12 on_each_cpu_cond_mask+0x7a/0x80 kernel/smp.c:1053 on_each_cpu include/linux/smp.h:71 [inline] smp_text_poke_sync_each_cpu arch/x86/kernel/alternative.c:2660 [inline] smp_text_poke_batch_finish+0x5e0/0x1100 arch/x86/kernel/alternative.c:2870 arch_jump_label_transform_apply+0x1c/0x30 arch/x86/kernel/jump_label.c:146 static_key_enable_cpuslocked+0x128/0x250 kernel/jump_label.c:210 static_key_enable+0x1a/0x20 kernel/jump_label.c:223 tracepoint_add_func+0x994/0xa10 kernel/tracepoint.c:315 tracepoint_probe_register_prio_may_exist+0x5f/0xa0 kernel/tracepoint.c:435 bpf_raw_tp_link_attach+0x4ff/0x6b0 kernel/bpf/syscall.c:4133 bpf_raw_tracepoint_open+0x19b/0x1f0 kernel/bpf/syscall.c:4164 __sys_bpf+0x3cd/0x860 kernel/bpf/syscall.c:6020 __do_sys_bpf kernel/bpf/syscall.c:6085 [inline] __se_sys_bpf kernel/bpf/syscall.c:6083 [inline] __x64_sys_bpf+0x7c/0x90 kernel/bpf/syscall.c:6083 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0x3b0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f other info that might help us debug this: Chain exists of: console_owner --> &p->pi_lock --> &rq->__lock Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&rq->__lock); lock(&p->pi_lock); lock(&rq->__lock); lock(console_owner); *** DEADLOCK *** 6 locks held by syz.2.140/6353: #0: ffffffff8e194168 (tracepoints_mutex){+.+.}-{4:4}, at: tracepoint_probe_register_prio_may_exist+0x43/0xa0 kernel/tracepoint.c:431 #1: ffffffff8dfd71d0 (cpu_hotplug_lock){++++}-{0:0}, at: static_key_enable+0x12/0x20 kernel/jump_label.c:222 #2: ffffffff8e1fae68 (jump_label_mutex){+.+.}-{4:4}, at: jump_label_lock kernel/jump_label.c:27 [inline] #2: ffffffff8e1fae68 (jump_label_mutex){+.+.}-{4:4}, at: static_key_enable_cpuslocked+0xcb/0x250 kernel/jump_label.c:207 #3: ffffffff8dfea848 (text_mutex){+.+.}-{4:4}, at: arch_jump_label_transform_apply+0x17/0x30 arch/x86/kernel/jump_label.c:145 #4: ffff8880b873b918 (&rq->__lock){-.-.}-{2:2}, at: raw_spin_rq_lock_nested+0x2a/0x140 kernel/sched/core.c:606 #5: ffffffff8e13f060 (rcu_read_lock){....}-{1:3}, at: rcu_lock_acquire include/linux/rcupdate.h:331 [inline] #5: ffffffff8e13f060 (rcu_read_lock){....}-{1:3}, at: rcu_read_lock include/linux/rcupdate.h:841 [inline] #5: ffffffff8e13f060 (rcu_read_lock){....}-{1:3}, at: __bpf_trace_run kernel/trace/bpf_trace.c:2257 [inline] #5: ffffffff8e13f060 (rcu_read_lock){....}-{1:3}, at: bpf_trace_run2+0x186/0x4b0 kernel/trace/bpf_trace.c:2299 stack backtrace: CPU: 1 UID: 0 PID: 6353 Comm: syz.2.140 Not tainted 6.15.0-syzkaller-g3ce7cdde66e6 #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025 Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 print_circular_bug+0x2ee/0x310 kernel/locking/lockdep.c:2046 check_noncircular+0x134/0x160 kernel/locking/lockdep.c:2178 check_prev_add kernel/locking/lockdep.c:3168 [inline] check_prevs_add kernel/locking/lockdep.c:3287 [inline] validate_chain+0xb9b/0x2140 kernel/locking/lockdep.c:3911 __lock_acquire+0xab9/0xd20 kernel/locking/lockdep.c:5240 lock_acquire+0x120/0x360 kernel/locking/lockdep.c:5871 console_trylock_spinning kernel/printk/printk.c:2048 [inline] vprintk_emit+0x460/0x7a0 kernel/printk/printk.c:2449 _printk+0xcf/0x120 kernel/printk/printk.c:2475 fail_dump lib/fault-inject.c:66 [inline] should_fail_ex+0x3f5/0x560 lib/fault-inject.c:174 strncpy_from_user+0x36/0x290 lib/strncpy_from_user.c:118 strncpy_from_user_nofault+0x72/0x150 mm/maccess.c:193 bpf_probe_read_user_str_common kernel/trace/bpf_trace.c:215 [inline] ____bpf_probe_read_compat_str kernel/trace/bpf_trace.c:310 [inline] bpf_probe_read_compat_str+0xe2/0x180 kernel/trace/bpf_trace.c:306 bpf_prog_d151c66365667d32+0x5d/0x63 bpf_dispatcher_nop_func include/linux/bpf.h:1322 [inline] __bpf_prog_run include/linux/filter.h:718 [inline] bpf_prog_run include/linux/filter.h:725 [inline] __bpf_trace_run kernel/trace/bpf_trace.c:2258 [inline] bpf_trace_run2+0x281/0x4b0 kernel/trace/bpf_trace.c:2299 __bpf_trace_tlb_flush+0xf5/0x150 include/trace/events/tlb.h:38 __do_trace_tlb_flush include/trace/events/tlb.h:38 [inline] trace_tlb_flush+0x115/0x140 include/trace/events/tlb.h:38 switch_mm_irqs_off+0x53e/0x7a0 arch/x86/mm/tlb.c:-1 context_switch kernel/sched/core.c:5380 [inline] __schedule+0x106c/0x4d00 kernel/sched/core.c:6785 preempt_schedule_common+0x83/0xd0 kernel/sched/core.c:6965 preempt_schedule+0xae/0xc0 kernel/sched/core.c:6989 preempt_schedule_thunk+0x16/0x30 arch/x86/entry/thunk.S:12 on_each_cpu_cond_mask+0x7a/0x80 kernel/smp.c:1053 on_each_cpu include/linux/smp.h:71 [inline] smp_text_poke_sync_each_cpu arch/x86/kernel/alternative.c:2660 [inline] smp_text_poke_batch_finish+0x5e0/0x1100 arch/x86/kernel/alternative.c:2870 arch_jump_label_transform_apply+0x1c/0x30 arch/x86/kernel/jump_label.c:146 static_key_enable_cpuslocked+0x128/0x250 kernel/jump_label.c:210 static_key_enable+0x1a/0x20 kernel/jump_label.c:223 tracepoint_add_func+0x994/0xa10 kernel/tracepoint.c:315 tracepoint_probe_register_prio_may_exist+0x5f/0xa0 kernel/tracepoint.c:435 bpf_raw_tp_link_attach+0x4ff/0x6b0 kernel/bpf/syscall.c:4133 bpf_raw_tracepoint_open+0x19b/0x1f0 kernel/bpf/syscall.c:4164 __sys_bpf+0x3cd/0x860 kernel/bpf/syscall.c:6020 __do_sys_bpf kernel/bpf/syscall.c:6085 [inline] __se_sys_bpf kernel/bpf/syscall.c:6083 [inline] __x64_sys_bpf+0x7c/0x90 kernel/bpf/syscall.c:6083 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0x3b0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f806ff8e929 Code: Unable to access opcode bytes at 0x7f806ff8e8ff. RSP: 002b:00007f8070e60038 EFLAGS: 00000246 ORIG_RAX: 0000000000000141 RAX: ffffffffffffffda RBX: 00007f80701b5fa0 RCX: 00007f806ff8e929 RDX: 0000000000000010 RSI: 0000200000000980 RDI: 0000000000000011 RBP: 00007f8070e60090 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000002 R13: 0000000000000000 R14: 00007f80701b5fa0 R15: 00007ffec61a41d8 CPU: 1 UID: 0 PID: 6353 Comm: syz.2.140 Not tainted 6.15.0-syzkaller-g3ce7cdde66e6 #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025 Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 fail_dump lib/fault-inject.c:73 [inline] should_fail_ex+0x414/0x560 lib/fault-inject.c:174 strncpy_from_user+0x36/0x290 lib/strncpy_from_user.c:118 strncpy_from_user_nofault+0x72/0x150 mm/maccess.c:193 bpf_probe_read_user_str_common kernel/trace/bpf_trace.c:215 [inline] ____bpf_probe_read_compat_str kernel/trace/bpf_trace.c:310 [inline] bpf_probe_read_compat_str+0xe2/0x180 kernel/trace/bpf_trace.c:306 bpf_prog_d151c66365667d32+0x5d/0x63 bpf_dispatcher_nop_func include/linux/bpf.h:1322 [inline] __bpf_prog_run include/linux/filter.h:718 [inline] bpf_prog_run include/linux/filter.h:725 [inline] __bpf_trace_run kernel/trace/bpf_trace.c:2258 [inline] bpf_trace_run2+0x281/0x4b0 kernel/trace/bpf_trace.c:2299 __bpf_trace_tlb_flush+0xf5/0x150 include/trace/events/tlb.h:38 __do_trace_tlb_flush include/trace/events/tlb.h:38 [inline] trace_tlb_flush+0x115/0x140 include/trace/events/tlb.h:38 switch_mm_irqs_off+0x53e/0x7a0 arch/x86/mm/tlb.c:-1 context_switch kernel/sched/core.c:5380 [inline] __schedule+0x106c/0x4d00 kernel/sched/core.c:6785 preempt_schedule_common+0x83/0xd0 kernel/sched/core.c:6965 preempt_schedule+0xae/0xc0 kernel/sched/core.c:6989 preempt_schedule_thunk+0x16/0x30 arch/x86/entry/thunk.S:12 on_each_cpu_cond_mask+0x7a/0x80 kernel/smp.c:1053 on_each_cpu include/linux/smp.h:71 [inline] smp_text_poke_sync_each_cpu arch/x86/kernel/alternative.c:2660 [inline] smp_text_poke_batch_finish+0x5e0/0x1100 arch/x86/kernel/alternative.c:2870 arch_jump_label_transform_apply+0x1c/0x30 arch/x86/kernel/jump_label.c:146 static_key_enable_cpuslocked+0x128/0x250 kernel/jump_label.c:210 static_key_enable+0x1a/0x20 kernel/jump_label.c:223 tracepoint_add_func+0x994/0xa10 kernel/tracepoint.c:315 tracepoint_probe_register_prio_may_exist+0x5f/0xa0 kernel/tracepoint.c:435 bpf_raw_tp_link_attach+0x4ff/0x6b0 kernel/bpf/syscall.c:4133 bpf_raw_tracepoint_open+0x19b/0x1f0 kernel/bpf/syscall.c:4164 __sys_bpf+0x3cd/0x860 kernel/bpf/syscall.c:6020 __do_sys_bpf kernel/bpf/syscall.c:6085 [inline] __se_sys_bpf kernel/bpf/syscall.c:6083 [inline] __x64_sys_bpf+0x7c/0x90 kernel/bpf/syscall.c:6083 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0x3b0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f RIP: 0033:0x7f806ff8e929 Code: Unable to access opcode bytes at 0x7f806ff8e8ff. RSP: 002b:00007f8070e60038 EFLAGS: 00000246 ORIG_RAX: 0000000000000141 RAX: ffffffffffffffda RBX: 00007f80701b5fa0 RCX: 00007f806ff8e929 RDX: 0000000000000010 RSI: 0000200000000980 RDI: 0000000000000011 RBP: 00007f8070e60090 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000002 R13: 0000000000000000 R14: 00007f80701b5fa0 R15: 00007ffec61a41d8