Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x1b2/0x281 lib/dump_stack.c:58 fail_dump lib/fault-inject.c:51 [inline] should_fail.cold+0x10a/0x149 lib/fault-inject.c:149 should_failslab+0xd6/0x130 mm/failslab.c:32 slab_pre_alloc_hook mm/slab.h:421 [inline] slab_alloc mm/slab.c:3376 [inline] kmem_cache_alloc+0x28e/0x3c0 mm/slab.c:3550 general protection fault: 0000 [#1] PREEMPT SMP KASAN Modules linked in: sock_alloc_inode+0x19/0x250 net/socket.c:251 CPU: 0 PID: 19382 Comm: syz-executor.2 Not tainted 4.14.299-syzkaller #0 alloc_inode+0x5d/0x170 fs/inode.c:209 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 new_inode_pseudo+0x14/0xe0 fs/inode.c:898 task: ffff8880b3fac440 task.stack: ffff8880a96e8000 sock_alloc+0x3c/0x270 net/socket.c:569 RIP: 0010:cdev_del+0x22/0x90 fs/char_dev.c:602 __sock_create+0x8a/0x620 net/socket.c:1239 RSP: 0018:ffff8880a96efca0 EFLAGS: 00010207 sock_create net/socket.c:1315 [inline] SYSC_socketpair net/socket.c:1387 [inline] SyS_socketpair+0xdf/0x480 net/socket.c:1366 RAX: dffffc0000000000 RBX: ffff8880b0a28b00 RCX: 0000000000000000 RDX: 000000000000000c RSI: ffff8880b3faccf0 RDI: 0000000000000064 RBP: 0000000000000000 R08: ffffffff8b9a6658 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: ffff8880b0a28b08 R13: ffff8880af100108 R14: ffff8880a18c2ec0 R15: ffff8880b024e8d8 FS: 0000555556936400(0000) GS:ffff8880ba400000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 CR2: 0000555555c83708 CR3: 0000000099272000 CR4: 00000000003406f0 entry_SYSCALL_64_after_hwframe+0x5e/0xd3 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: tty_unregister_device drivers/tty/tty_io.c:3046 [inline] tty_unregister_device+0x101/0x1a0 drivers/tty/tty_io.c:3041 gsmld_detach_gsm drivers/tty/n_gsm.c:2361 [inline] gsmld_close+0xaa/0x1f0 drivers/tty/n_gsm.c:2430 tty_ldisc_close+0x8c/0xc0 drivers/tty/tty_ldisc.c:505 tty_ldisc_kill drivers/tty/tty_ldisc.c:651 [inline] tty_ldisc_release+0xe8/0x400 drivers/tty/tty_ldisc.c:818 tty_release_struct+0x20/0xe0 drivers/tty/tty_io.c:1603 tty_release+0xb3f/0x10d0 drivers/tty/tty_io.c:1776 __fput+0x25f/0x7a0 fs/file_table.c:210 task_work_run+0x11f/0x190 kernel/task_work.c:113 tracehook_notify_resume include/linux/tracehook.h:191 [inline] exit_to_usermode_loop+0x1ad/0x200 arch/x86/entry/common.c:164 prepare_exit_to_usermode arch/x86/entry/common.c:199 [inline] syscall_return_slowpath arch/x86/entry/common.c:270 [inline] do_syscall_64+0x4a3/0x640 arch/x86/entry/common.c:297 entry_SYSCALL_64_after_hwframe+0x5e/0xd3 Code: 05 3e f7 ff eb d2 0f 1f 00 55 48 89 fd 48 83 ec 08 e8 33 80 cd ff 48 8d 7d 64 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <0f> b6 14 02 48 89 f8 83 e0 07 83 c0 03 38 d0 7c 04 84 d2 75 4f RIP: cdev_del+0x22/0x90 fs/char_dev.c:602 RSP: ffff8880a96efca0 FAULT_INJECTION: forcing a failure. name failslab, interval 1, probability 0, space 0, times 0 CPU: 0 PID: 19488 Comm: syz-executor.0 Tainted: G D 4.14.299-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x1b2/0x281 lib/dump_stack.c:58 fail_dump lib/fault-inject.c:51 [inline] should_fail.cold+0x10a/0x149 lib/fault-inject.c:149 should_failslab+0xd6/0x130 mm/failslab.c:32 slab_pre_alloc_hook mm/slab.h:421 [inline] slab_alloc mm/slab.c:3376 [inline] kmem_cache_alloc_trace+0x29a/0x3d0 mm/slab.c:3616 kmalloc include/linux/slab.h:488 [inline] kzalloc include/linux/slab.h:661 [inline] tty_register_device_attr+0x1d2/0x710 drivers/tty/tty_io.c:2982 gsmld_attach_gsm drivers/tty/n_gsm.c:2340 [inline] gsmld_open+0x548/0x7b0 drivers/tty/n_gsm.c:2466 tty_ldisc_open+0x6c/0xb0 drivers/tty/tty_ldisc.c:481 tty_set_ldisc+0x287/0x5d0 drivers/tty/tty_ldisc.c:606 tiocsetd drivers/tty/tty_io.c:2351 [inline] tty_ioctl+0xa2a/0x1430 drivers/tty/tty_io.c:2595 vfs_ioctl fs/ioctl.c:46 [inline] file_ioctl fs/ioctl.c:500 [inline] do_vfs_ioctl+0x75a/0xff0 fs/ioctl.c:684 SYSC_ioctl fs/ioctl.c:701 [inline] SyS_ioctl+0x7f/0xb0 fs/ioctl.c:692 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x5e/0xd3 kasan: CONFIG_KASAN_INLINE enabled kasan: GPF could be caused by NULL-ptr deref or user memory access general protection fault: 0000 [#2] PREEMPT SMP KASAN Modules linked in: CPU: 0 PID: 19475 Comm: syz-executor.0 Tainted: G D 4.14.299-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022 task: ffff8880b10da680 task.stack: ffff88809df08000 RIP: 0010:cdev_del+0x22/0x90 fs/char_dev.c:602 RSP: 0018:ffff88809df0fca0 EFLAGS: 00010207 RAX: dffffc0000000000 RBX: ffff8880b0a28b00 RCX: 0000000000000000 RDX: 000000000000000c RSI: 0000000000000002 RDI: 0000000000000064 RBP: 0000000000000000 R08: 0000000000000001 R09: 0000000000000000 R10: 0000000000000000 R11: ffff8880b10da680 R12: ffff8880b0a28b08 R13: ffff8880af100308 R14: ffff8880a18c24c0 R15: ffff8880a1b4f558 FS: 0000555555c83400(0000) GS:ffff8880ba400000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000001b2f522000 CR3: 000000009ecdd000 CR4: 00000000003406f0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: tty_unregister_device drivers/tty/tty_io.c:3046 [inline] tty_unregister_device+0x101/0x1a0 drivers/tty/tty_io.c:3041 gsmld_detach_gsm drivers/tty/n_gsm.c:2361 [inline] gsmld_close+0xaa/0x1f0 drivers/tty/n_gsm.c:2430 tty_ldisc_close+0x8c/0xc0 drivers/tty/tty_ldisc.c:505 tty_ldisc_kill drivers/tty/tty_ldisc.c:651 [inline] tty_ldisc_release+0xe8/0x400 drivers/tty/tty_ldisc.c:818 tty_release_struct+0x20/0xe0 drivers/tty/tty_io.c:1603 tty_release+0xb3f/0x10d0 drivers/tty/tty_io.c:1776 __fput+0x25f/0x7a0 fs/file_table.c:210 task_work_run+0x11f/0x190 kernel/task_work.c:113 tracehook_notify_resume include/linux/tracehook.h:191 [inline] exit_to_usermode_loop+0x1ad/0x200 arch/x86/entry/common.c:164 prepare_exit_to_usermode arch/x86/entry/common.c:199 [inline] syscall_return_slowpath arch/x86/entry/common.c:270 [inline] do_syscall_64+0x4a3/0x640 arch/x86/entry/common.c:297 entry_SYSCALL_64_after_hwframe+0x5e/0xd3 Code: 05 3e f7 ff eb d2 0f 1f 00 55 48 89 fd 48 83 ec 08 e8 33 80 cd ff 48 8d 7d 64 48 b8 00 00 00 00 00 fc ff df 48 89 fa 48 c1 ea 03 <0f> b6 14 02 48 89 f8 83 e0 07 83 c0 03 38 d0 7c 04 84 d2 75 4f RIP: cdev_del+0x22/0x90 fs/char_dev.c:602 RSP: ffff88809df0fca0 ---[ end trace 99cbe1156379510a ]--- ---------------- Code disassembly (best guess), 1 bytes skipped: 0: 3e f7 ff ds idiv %edi 3: eb d2 jmp 0xffffffd7 5: 0f 1f 00 nopl (%rax) 8: 55 push %rbp 9: 48 89 fd mov %rdi,%rbp c: 48 83 ec 08 sub $0x8,%rsp 10: e8 33 80 cd ff callq 0xffcd8048 15: 48 8d 7d 64 lea 0x64(%rbp),%rdi 19: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax 20: fc ff df 23: 48 89 fa mov %rdi,%rdx 26: 48 c1 ea 03 shr $0x3,%rdx * 2a: 0f b6 14 02 movzbl (%rdx,%rax,1),%edx <-- trapping instruction 2e: 48 89 f8 mov %rdi,%rax 31: 83 e0 07 and $0x7,%eax 34: 83 c0 03 add $0x3,%eax 37: 38 d0 cmp %dl,%al 39: 7c 04 jl 0x3f 3b: 84 d2 test %dl,%dl 3d: 75 4f jne 0x8e