vfs_ioctl fs/ioctl.c:46 [inline] file_ioctl fs/ioctl.c:501 [inline] do_vfs_ioctl+0xcdb/0x12e0 fs/ioctl.c:688 page dumped because: VM_BUG_ON_PAGE(page_ref_count(page) == 0) ------------[ cut here ]------------ kernel BUG at include/linux/mm.h:519! invalid opcode: 0000 [#1] PREEMPT SMP KASAN CPU: 1 PID: 20378 Comm: syz-executor.3 Not tainted 4.19.211-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 ksys_ioctl+0x9b/0xc0 fs/ioctl.c:705 RIP: 0010:put_page_testzero include/linux/mm.h:519 [inline] RIP: 0010:put_page include/linux/mm.h:962 [inline] RIP: 0010:__skb_frag_unref include/linux/skbuff.h:2842 [inline] RIP: 0010:skb_release_data+0x3bf/0x920 net/core/skbuff.c:577 __do_sys_ioctl fs/ioctl.c:712 [inline] __se_sys_ioctl fs/ioctl.c:710 [inline] __x64_sys_ioctl+0x6f/0xb0 fs/ioctl.c:710 Code: b4 0a fb e9 2a fe ff ff e8 3e c9 f1 fa 48 8d 6b ff e9 b5 fe ff ff e8 30 c9 f1 fa 48 c7 c6 20 50 4c 89 48 89 ef e8 e1 5a 19 fb <0f> 0b 4c 8b 34 24 e8 16 c9 f1 fa 49 8d 7e 08 48 b8 00 00 00 00 00 RSP: 0018:ffff8880ba1075e8 EFLAGS: 00010206 do_syscall_64+0xf9/0x620 arch/x86/entry/common.c:293 RAX: ffff8880aa464100 RBX: ffffea00023d6a34 RCX: 0000000000000000 entry_SYSCALL_64_after_hwframe+0x49/0xbe RDX: 0000000000000100 RSI: ffffffff8670bc4f RDI: ffffea00023d6a38 RIP: 0033:0x7fd5c44cfda7 RBP: ffffea00023d6a00 R08: 000000000000003e R09: 0000000000000000 Code: 3c 1c 48 f7 d8 49 39 c4 72 b8 e8 04 54 02 00 85 c0 78 bd 48 83 c4 08 4c 89 e0 5b 41 5c c3 0f 1f 44 00 00 b8 10 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 bc ff ff ff f7 d8 64 89 01 48 R10: 0000000000000005 R11: 0000000000000000 R12: 0000000000000000 RSP: 002b:00007fd5c2e44f28 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 R13: dffffc0000000000 R14: 0000000000000000 R15: ffff88809f0bc330 RAX: ffffffffffffffda RBX: 00007fd5c45199c8 RCX: 00007fd5c44cfda7 FS: 00005555557e7400(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000 RDX: 0000000000000004 RSI: 0000000000004c00 RDI: 0000000000000005 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 RBP: 0000000000000005 R08: 0000000000000000 R09: 00007fd5c2e451d0 CR2: 0000001b30a2e000 CR3: 000000009eac7000 CR4: 00000000003426e0 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000004 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 R13: 0000000000000004 R14: 0000000020000248 R15: 0000000000000003 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: skb_release_all net/core/skbuff.c:640 [inline] __kfree_skb+0x46/0x60 net/core/skbuff.c:654 sk_wmem_free_skb include/net/sock.h:1468 [inline] tcp_write_queue_purge+0x24d/0x800 net/ipv4/tcp.c:2543 tcp_reset+0xfe/0x490 net/ipv4/tcp_input.c:4085 tcp_validate_incoming+0x117d/0x1670 net/ipv4/tcp_input.c:5456 tcp_rcv_state_process+0xb7a/0x4c50 net/ipv4/tcp_input.c:6096 tcp_v6_do_rcv+0x47c/0x1370 net/ipv6/tcp_ipv6.c:1373 tcp_v6_rcv+0x26b8/0x3990 net/ipv6/tcp_ipv6.c:1577 ip6_input_finish+0x46a/0x17a0 net/ipv6/ip6_input.c:385 NF_HOOK include/linux/netfilter.h:289 [inline] ip6_input+0xcf/0x3c0 net/ipv6/ip6_input.c:428 dst_input include/net/dst.h:461 [inline] ip6_rcv_finish+0x1d9/0x2f0 net/ipv6/ip6_input.c:76 NF_HOOK include/linux/netfilter.h:289 [inline] ipv6_rcv+0xf2/0x3f0 net/ipv6/ip6_input.c:273 __netif_receive_skb_one_core+0x114/0x180 net/core/dev.c:4954 __netif_receive_skb+0x27/0x1c0 net/core/dev.c:5066 process_backlog+0x241/0x700 net/core/dev.c:5849 napi_poll net/core/dev.c:6280 [inline] net_rx_action+0x4ac/0xfb0 net/core/dev.c:6346 __do_softirq+0x265/0x980 kernel/softirq.c:292 do_softirq_own_stack+0x2a/0x40 arch/x86/entry/entry_64.S:1092 do_softirq.part.0+0x160/0x1c0 kernel/softirq.c:336 do_softirq kernel/softirq.c:328 [inline] __local_bh_enable_ip+0x20e/0x270 kernel/softirq.c:189 local_bh_enable include/linux/bottom_half.h:32 [inline] inet_csk_listen_stop+0x1e7/0x8a0 net/ipv4/inet_connection_sock.c:1033 tcp_close+0xca3/0xfd0 net/ipv4/tcp.c:2351 inet_release+0xd7/0x1e0 net/ipv4/af_inet.c:427 inet6_release+0x4c/0x70 net/ipv6/af_inet6.c:472 __sock_release+0xcd/0x2a0 net/socket.c:599 sock_close+0x15/0x20 net/socket.c:1214 __fput+0x2ce/0x890 fs/file_table.c:278 task_work_run+0x148/0x1c0 kernel/task_work.c:113 tracehook_notify_resume include/linux/tracehook.h:193 [inline] exit_to_usermode_loop+0x251/0x2a0 arch/x86/entry/common.c:167 prepare_exit_to_usermode arch/x86/entry/common.c:198 [inline] syscall_return_slowpath arch/x86/entry/common.c:271 [inline] do_syscall_64+0x538/0x620 arch/x86/entry/common.c:296 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x7f6972cb0c2b Code: 0f 05 48 3d 00 f0 ff ff 77 45 c3 0f 1f 40 00 48 83 ec 18 89 7c 24 0c e8 63 fc ff ff 8b 7c 24 0c 41 89 c0 b8 03 00 00 00 0f 05 <48> 3d 00 f0 ff ff 77 35 44 89 c7 89 44 24 0c e8 a1 fc ff ff 8b 44 RSP: 002b:00007ffe25891190 EFLAGS: 00000293 ORIG_RAX: 0000000000000003 RAX: 0000000000000000 RBX: 0000000000000005 RCX: 00007f6972cb0c2b RDX: 0000000000000000 RSI: 0000001b30a283dc RDI: 0000000000000004 RBP: 00007f6972e12960 R08: 0000000000000000 R09: 000000006ad6696d R10: 0000000000000000 R11: 0000000000000293 R12: 0000000000053d53 R13: 00007ffe25891290 R14: 00007f6972e11030 R15: 0000000000000032 Modules linked in: ---[ end trace 96c5cf3bb62697d8 ]--- RIP: 0010:put_page_testzero include/linux/mm.h:519 [inline] RIP: 0010:put_page include/linux/mm.h:962 [inline] RIP: 0010:__skb_frag_unref include/linux/skbuff.h:2842 [inline] RIP: 0010:skb_release_data+0x3bf/0x920 net/core/skbuff.c:577 Code: b4 0a fb e9 2a fe ff ff e8 3e c9 f1 fa 48 8d 6b ff e9 b5 fe ff ff e8 30 c9 f1 fa 48 c7 c6 20 50 4c 89 48 89 ef e8 e1 5a 19 fb <0f> 0b 4c 8b 34 24 e8 16 c9 f1 fa 49 8d 7e 08 48 b8 00 00 00 00 00 RSP: 0018:ffff8880ba1075e8 EFLAGS: 00010206 RAX: ffff8880aa464100 RBX: ffffea00023d6a34 RCX: 0000000000000000 RDX: 0000000000000100 RSI: ffffffff8670bc4f RDI: ffffea00023d6a38 RBP: ffffea00023d6a00 R08: 000000000000003e R09: 0000000000000000 R10: 0000000000000005 R11: 0000000000000000 R12: 0000000000000000 R13: dffffc0000000000 R14: 0000000000000000 R15: ffff88809f0bc330 FS: 00005555557e7400(0000) GS:ffff8880ba100000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000001b30a2e000 CR3: 000000009eac7000 CR4: 00000000003426e0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 ---------------- Code disassembly (best guess): 0: 3c 1c cmp $0x1c,%al 2: 48 f7 d8 neg %rax 5: 49 39 c4 cmp %rax,%r12 8: 72 b8 jb 0xffffffc2 a: e8 04 54 02 00 callq 0x25413 f: 85 c0 test %eax,%eax 11: 78 bd js 0xffffffd0 13: 48 83 c4 08 add $0x8,%rsp 17: 4c 89 e0 mov %r12,%rax 1a: 5b pop %rbx 1b: 41 5c pop %r12 1d: c3 retq 1e: 0f 1f 44 00 00 nopl 0x0(%rax,%rax,1) 23: b8 10 00 00 00 mov $0x10,%eax 28: 0f 05 syscall * 2a: 48 3d 01 f0 ff ff cmp $0xfffffffffffff001,%rax <-- trapping instruction 30: 73 01 jae 0x33 32: c3 retq 33: 48 c7 c1 bc ff ff ff mov $0xffffffffffffffbc,%rcx 3a: f7 d8 neg %eax 3c: 64 89 01 mov %eax,%fs:(%rcx) 3f: 48 rex.W