netlink: 4944 bytes leftover after parsing attributes in process `syz-executor0'. ====================================================== WARNING: possible circular locking dependency detected 4.17.0-rc2+ #23 Not tainted ------------------------------------------------------ syz-executor7/6752 is trying to acquire lock: (ptrval) (&mm->mmap_sem){++++}, at: __might_fault+0xfb/0x1e0 mm/memory.c:4554 but task is already holding lock: (ptrval) (sk_lock-AF_INET6){+.+.}, at: lock_sock include/net/sock.h:1469 [inline] (ptrval) (sk_lock-AF_INET6){+.+.}, at: dccp_sendmsg+0x2cf/0x1020 net/dccp/proto.c:793 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (sk_lock-AF_INET6){+.+.}: lock_sock_nested+0xd0/0x120 net/core/sock.c:2844 lock_sock include/net/sock.h:1469 [inline] tcp_mmap+0x1c7/0x14f0 net/ipv4/tcp.c:1759 sock_mmap+0x8e/0xc0 net/socket.c:1144 call_mmap include/linux/fs.h:1789 [inline] mmap_region+0xd13/0x1820 mm/mmap.c:1723 do_mmap+0xc79/0x11d0 mm/mmap.c:1494 do_mmap_pgoff include/linux/mm.h:2237 [inline] vm_mmap_pgoff+0x1fb/0x2a0 mm/util.c:357 ksys_mmap_pgoff+0x4c9/0x640 mm/mmap.c:1544 __do_sys_mmap arch/x86/kernel/sys_x86_64.c:100 [inline] __se_sys_mmap arch/x86/kernel/sys_x86_64.c:91 [inline] __x64_sys_mmap+0xe9/0x1b0 arch/x86/kernel/sys_x86_64.c:91 do_syscall_64+0x1b1/0x800 arch/x86/entry/common.c:287 entry_SYSCALL_64_after_hwframe+0x49/0xbe -> #0 (&mm->mmap_sem){++++}: lock_acquire+0x1dc/0x520 kernel/locking/lockdep.c:3920 __might_fault+0x155/0x1e0 mm/memory.c:4555 _copy_from_iter_full+0x2fd/0xd10 lib/iov_iter.c:607 copy_from_iter_full include/linux/uio.h:124 [inline] memcpy_from_msg include/linux/skbuff.h:3306 [inline] dccp_sendmsg+0x418/0x1020 net/dccp/proto.c:803 inet_sendmsg+0x19f/0x690 net/ipv4/af_inet.c:798 sock_sendmsg_nosec net/socket.c:629 [inline] sock_sendmsg+0xd5/0x120 net/socket.c:639 ___sys_sendmsg+0x805/0x940 net/socket.c:2117 __sys_sendmsg+0x115/0x270 net/socket.c:2155 __do_sys_sendmsg net/socket.c:2164 [inline] __se_sys_sendmsg net/socket.c:2162 [inline] __x64_sys_sendmsg+0x78/0xb0 net/socket.c:2162 do_syscall_64+0x1b1/0x800 arch/x86/entry/common.c:287 entry_SYSCALL_64_after_hwframe+0x49/0xbe other info that might help us debug this: IPVS: ftp: loaded support on port[0] = 21 Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(sk_lock-AF_INET6); lock(&mm->mmap_sem); lock(sk_lock-AF_INET6); lock(&mm->mmap_sem); *** DEADLOCK *** 1 lock held by syz-executor7/6752: #0: (ptrval) (sk_lock-AF_INET6){+.+.} IPVS: set_ctl: invalid protocol: 63 172.20.20.187:20002 rū , at: lock_sock include/net/sock.h:1469 [inline] , at: dccp_sendmsg+0x2cf/0x1020 net/dccp/proto.c:793 stack backtrace: CPU: 1 PID: 6752 Comm: syz-executor7 Not tainted 4.17.0-rc2+ #23 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: IPVS: set_ctl: invalid protocol: 63 172.20.20.187:20002 rū __dump_stack lib/dump_stack.c:77 [inline] dump_stack+0x1b9/0x294 lib/dump_stack.c:113 print_circular_bug.isra.36.cold.54+0x1bd/0x27d kernel/locking/lockdep.c:1223 IPVS: ftp: loaded support on port[0] = 21 check_prev_add kernel/locking/lockdep.c:1863 [inline] check_prevs_add kernel/locking/lockdep.c:1976 [inline] validate_chain kernel/locking/lockdep.c:2417 [inline] __lock_acquire+0x343e/0x5140 kernel/locking/lockdep.c:3431 lock_acquire+0x1dc/0x520 kernel/locking/lockdep.c:3920 __might_fault+0x155/0x1e0 mm/memory.c:4555 _copy_from_iter_full+0x2fd/0xd10 lib/iov_iter.c:607 copy_from_iter_full include/linux/uio.h:124 [inline] memcpy_from_msg include/linux/skbuff.h:3306 [inline] dccp_sendmsg+0x418/0x1020 net/dccp/proto.c:803 inet_sendmsg+0x19f/0x690 net/ipv4/af_inet.c:798 sock_sendmsg_nosec net/socket.c:629 [inline] sock_sendmsg+0xd5/0x120 net/socket.c:639 ___sys_sendmsg+0x805/0x940 net/socket.c:2117 __sys_sendmsg+0x115/0x270 net/socket.c:2155 __do_sys_sendmsg net/socket.c:2164 [inline] __se_sys_sendmsg net/socket.c:2162 [inline] __x64_sys_sendmsg+0x78/0xb0 net/socket.c:2162 do_syscall_64+0x1b1/0x800 arch/x86/entry/common.c:287 entry_SYSCALL_64_after_hwframe+0x49/0xbe RIP: 0033:0x455979 RSP: 002b:00007f2c7aaf9c68 EFLAGS: 00000246 ORIG_RAX: 000000000000002e RAX: ffffffffffffffda RBX: 00007f2c7aafa6d4 RCX: 0000000000455979 RDX: 0000000000000000 RSI: 0000000020b76fc8 RDI: 0000000000000015 RBP: 000000000072bea0 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 00000000ffffffff R13: 00000000000004fd R14: 00000000006fa858 R15: 0000000000000000 dccp_close: ABORT with 65423 bytes unread dccp_close: ABORT with 65423 bytes unread dccp_close: ABORT with 65423 bytes unread dccp_close: ABORT with 65423 bytes unread IPVS: ftp: loaded support on port[0] = 21 dccp_close: ABORT with 65423 bytes unread dccp_close: ABORT with 65423 bytes unread device lo entered promiscuous mode dccp_close: ABORT with 65423 bytes unread dccp_close: ABORT with 65423 bytes unread dccp_close: ABORT with 36 bytes unread IPVS: set_ctl: invalid protocol: 0 224.0.0.2:20000 sed IPVS: set_ctl: invalid protocol: 0 224.0.0.2:20000 sed IPVS: ftp: loaded support on port[0] = 21 IPVS: ftp: loaded support on port[0] = 21 x_tables: eb_tables: IDLETIMER.0 target: invalid size 40 (kernel) != (user) 5 x_tables: eb_tables: IDLETIMER.0 target: invalid size 40 (kernel) != (user) 5 IPVS: ftp: loaded support on port[0] = 21 kernel msg: ebtables bug: please report to author: Entries_size never zero kernel msg: ebtables bug: please report to author: Valid hook without chain kernel msg: ebtables bug: please report to author: Valid hook without chain IPVS: set_ctl: invalid protocol: 51 127.0.0.1:20004 dh netlink: 'syz-executor5': attribute type 39 has an invalid length. IPVS: set_ctl: invalid protocol: 51 127.0.0.1:20004 dh netlink: 4 bytes leftover after parsing attributes in process `syz-executor2'. netlink: 4 bytes leftover after parsing attributes in process `syz-executor2'. x_tables: eb_tables: IDLETIMER.0 target: invalid size 40 (kernel) != (user) 5 kernel msg: ebtables bug: please report to author: EBT_ENTRY_OR_ENTRIES shouldn't be set in distinguisher x_tables: eb_tables: IDLETIMER.0 target: invalid size 40 (kernel) != (user) 5 kernel msg: ebtables bug: please report to author: EBT_ENTRY_OR_ENTRIES shouldn't be set in distinguisher IPv4: Oversized IP packet from 127.0.0.1 IPv4: Oversized IP packet from 127.0.0.1 kernel msg: ebtables bug: please report to author: entries_size too small