kasan: CONFIG_KASAN_INLINE enabled kasan: GPF could be caused by NULL-ptr deref or user memory access general protection fault: 0000 [#1] PREEMPT SMP KASAN Modules linked in: CPU: 1 PID: 31231 Comm: syz-executor.5 Not tainted 4.14.273-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 task: ffff88807e46a3c0 task.stack: ffff8880b4e30000 RIP: 0010:cdev_del+0x22/0x90 fs/char_dev.c:602 RSP: 0018:ffff8880b4e37ba0 EFLAGS: 00010207 RAX: dffffc0000000000 RBX: ffff888238fd9700 RCX: ffffc900089f3000 RDX: 000000000000000c RSI: ffffffff8187ae5d RDI: 0000000000000064 RBP: 0000000000000000 R08: ffffffff8b9c7270 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: ffff888238fd9708 R13: ffff8882384ce4c8 R14: ffff8880b1a59300 R15: ffff8880abc24470 FS: 00007f7d90403700(0000) GS:ffff8880ba500000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 000056221dfd4160 CR3: 0000000096b2b000 CR4: 00000000003406e0 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:2305 [inline] gsmld_close+0xaa/0x1f0 drivers/tty/n_gsm.c:2374 tty_ldisc_close+0x8c/0xc0 drivers/tty/tty_ldisc.c:505 tty_set_ldisc+0x1b3/0x5d0 drivers/tty/tty_ldisc.c:600 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+0x46/0xbb RIP: 0033:0x7f7d91aaf049 RSP: 002b:00007f7d90403168 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00007f7d91bc2030 RCX: 00007f7d91aaf049 RDX: 0000000020000640 RSI: 0000000000005423 RDI: 0000000000000003 RBP: 00007f7d91b0908d R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007fffa3c6babf R14: 00007f7d90403300 R15: 0000000000022000 Code: e5 44 f7 ff eb d2 0f 1f 00 55 48 89 fd 48 83 ec 08 e8 e3 93 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: ffff8880b4e37ba0 ---[ end trace 82bae87aa45be7f9 ]--- ---------------- Code disassembly (best guess): 0: e5 44 in $0x44,%eax 2: f7 ff idiv %edi 4: eb d2 jmp 0xffffffd8 6: 0f 1f 00 nopl (%rax) 9: 55 push %rbp a: 48 89 fd mov %rdi,%rbp d: 48 83 ec 08 sub $0x8,%rsp 11: e8 e3 93 cd ff callq 0xffcd93f9 16: 48 8d 7d 64 lea 0x64(%rbp),%rdi 1a: 48 b8 00 00 00 00 00 movabs $0xdffffc0000000000,%rax 21: fc ff df 24: 48 89 fa mov %rdi,%rdx 27: 48 c1 ea 03 shr $0x3,%rdx * 2b: 0f b6 14 02 movzbl (%rdx,%rax,1),%edx <-- trapping instruction 2f: 48 89 f8 mov %rdi,%rax 32: 83 e0 07 and $0x7,%eax 35: 83 c0 03 add $0x3,%eax 38: 38 d0 cmp %dl,%al 3a: 7c 04 jl 0x40 3c: 84 d2 test %dl,%dl 3e: 75 4f jne 0x8f