====================================================== WARNING: possible circular locking dependency detected 4.15.0+ #290 Not tainted ------------------------------------------------------ syz-executor5/11086 is trying to acquire lock: (rtnl_mutex){+.+.}, at: [<00000000c27b2ea1>] rtnl_lock+0x17/0x20 net/core/rtnetlink.c:74 but task is already holding lock: (sk_lock-AF_INET){+.+.}, at: [<0000000014d5745e>] lock_sock include/net/sock.h:1461 [inline] (sk_lock-AF_INET){+.+.}, at: [<0000000014d5745e>] ip_setsockopt+0x8c/0xb0 net/ipv4/ip_sockglue.c:1259 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (sk_lock-AF_INET){+.+.}: lock_sock_nested+0xc2/0x110 net/core/sock.c:2780 lock_sock include/net/sock.h:1461 [inline] do_ip_getsockopt+0x1b3/0x2170 net/ipv4/ip_sockglue.c:1335 ip_getsockopt+0x90/0x220 net/ipv4/ip_sockglue.c:1566 tcp_getsockopt+0x82/0xd0 net/ipv4/tcp.c:3359 sock_common_getsockopt+0x95/0xd0 net/core/sock.c:2937 SYSC_getsockopt net/socket.c:1880 [inline] SyS_getsockopt+0x178/0x340 net/socket.c:1862 entry_SYSCALL_64_fastpath+0x29/0xa0 -> #0 (rtnl_mutex){+.+.}: lock_acquire+0x1d5/0x580 kernel/locking/lockdep.c:3920 __mutex_lock_common kernel/locking/mutex.c:756 [inline] __mutex_lock+0x16f/0x1a80 kernel/locking/mutex.c:893 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:908 rtnl_lock+0x17/0x20 net/core/rtnetlink.c:74 register_netdevice_notifier+0xad/0x860 net/core/dev.c:1607 tee_tg_check+0x1a0/0x280 net/netfilter/xt_TEE.c:106 xt_check_target+0x22c/0x7d0 net/netfilter/x_tables.c:845 check_target net/ipv4/netfilter/ip_tables.c:513 [inline] find_check_entry.isra.8+0x8c8/0xcb0 net/ipv4/netfilter/ip_tables.c:554 translate_table+0xed1/0x1610 net/ipv4/netfilter/ip_tables.c:725 do_replace net/ipv4/netfilter/ip_tables.c:1141 [inline] do_ipt_set_ctl+0x370/0x5f0 net/ipv4/netfilter/ip_tables.c:1675 nf_sockopt net/netfilter/nf_sockopt.c:106 [inline] nf_setsockopt+0x67/0xc0 net/netfilter/nf_sockopt.c:115 ip_setsockopt+0xa1/0xb0 net/ipv4/ip_sockglue.c:1260 udp_setsockopt+0x45/0x80 net/ipv4/udp.c:2401 sock_common_setsockopt+0x95/0xd0 net/core/sock.c:2978 SYSC_setsockopt net/socket.c:1849 [inline] SyS_setsockopt+0x189/0x360 net/socket.c:1828 entry_SYSCALL_64_fastpath+0x29/0xa0 other info that might help us debug this: Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(sk_lock-AF_INET); lock(rtnl_mutex); lock(sk_lock-AF_INET); lock(rtnl_mutex); *** DEADLOCK *** 1 lock held by syz-executor5/11086: #0: (sk_lock-AF_INET){+.+.}, at: [<0000000014d5745e>] lock_sock include/net/sock.h:1461 [inline] #0: (sk_lock-AF_INET){+.+.}, at: [<0000000014d5745e>] ip_setsockopt+0x8c/0xb0 net/ipv4/ip_sockglue.c:1259 stack backtrace: CPU: 1 PID: 11086 Comm: syz-executor5 Not tainted 4.15.0+ #290 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:53 print_circular_bug.isra.38+0x2cd/0x2dc kernel/locking/lockdep.c:1223 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+0x30a8/0x3e00 kernel/locking/lockdep.c:3431 lock_acquire+0x1d5/0x580 kernel/locking/lockdep.c:3920 __mutex_lock_common kernel/locking/mutex.c:756 [inline] __mutex_lock+0x16f/0x1a80 kernel/locking/mutex.c:893 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:908 rtnl_lock+0x17/0x20 net/core/rtnetlink.c:74 register_netdevice_notifier+0xad/0x860 net/core/dev.c:1607 tee_tg_check+0x1a0/0x280 net/netfilter/xt_TEE.c:106 xt_check_target+0x22c/0x7d0 net/netfilter/x_tables.c:845 check_target net/ipv4/netfilter/ip_tables.c:513 [inline] find_check_entry.isra.8+0x8c8/0xcb0 net/ipv4/netfilter/ip_tables.c:554 translate_table+0xed1/0x1610 net/ipv4/netfilter/ip_tables.c:725 do_replace net/ipv4/netfilter/ip_tables.c:1141 [inline] do_ipt_set_ctl+0x370/0x5f0 net/ipv4/netfilter/ip_tables.c:1675 nf_sockopt net/netfilter/nf_sockopt.c:106 [inline] nf_setsockopt+0x67/0xc0 net/netfilter/nf_sockopt.c:115 ip_setsockopt+0xa1/0xb0 net/ipv4/ip_sockglue.c:1260 udp_setsockopt+0x45/0x80 net/ipv4/udp.c:2401 sock_common_setsockopt+0x95/0xd0 net/core/sock.c:2978 SYSC_setsockopt net/socket.c:1849 [inline] SyS_setsockopt+0x189/0x360 net/socket.c:1828 entry_SYSCALL_64_fastpath+0x29/0xa0 RIP: 0033:0x453299 RSP: 002b:00007f896449cc58 EFLAGS: 00000212 ORIG_RAX: 0000000000000036 RAX: ffffffffffffffda RBX: 000000000071bea0 RCX: 0000000000453299 RDX: 0000000000000040 RSI: 0000000000000000 RDI: 0000000000000013 RBP: 00000000000005c4 R08: 00000000000002e0 R09: 0000000000000000 R10: 000000002002ccf8 R11: 0000000000000212 R12: 00000000006f7b00 R13: 00000000ffffffff R14: 00007f896449d6d4 R15: 0000000000000000 binder: 11225 RLIMIT_NICE not set binder: undelivered transaction 43, process died. QAT: Invalid ioctl binder: BINDER_SET_CONTEXT_MGR already set binder: 11221:11243 ioctl 40046207 0 returned -16 QAT: Invalid ioctl binder: 11225 RLIMIT_NICE not set binder_alloc: 11221: binder_alloc_buf, no vma binder: 11221:11243 transaction failed 29189/-3, size 0-0 line 2903 binder: undelivered TRANSACTION_ERROR: 29189 binder: undelivered TRANSACTION_COMPLETE rfkill: input handler disabled rfkill: input handler enabled PPPIOCDETACH file->f_count=2 binder: BINDER_SET_CONTEXT_MGR already set binder: 11333:11358 ioctl 40046207 0 returned -16 binder: undelivered death notification, 0000000000000000 binder: undelivered death notification, 0000000000000000 sctp: [Deprecated]: syz-executor5 (pid 11374) Use of int in maxseg socket option. Use struct sctp_assoc_value instead sctp: [Deprecated]: syz-executor5 (pid 11391) Use of int in maxseg socket option. Use struct sctp_assoc_value instead kauditd_printk_skb: 865 callbacks suppressed audit: type=1400 audit(1517487900.555:4902): avc: denied { dac_read_search } for pid=11431 comm="syz-executor1" capability=2 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487900.556:4903): avc: denied { net_admin } for pid=11446 comm="syz-executor4" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487900.556:4904): avc: denied { map } for pid=11458 comm="modprobe" path="/bin/kmod" dev="sda1" ino=1440 scontext=system_u:system_r:kernel_t:s0 tcontext=system_u:object_r:file_t:s0 tclass=file permissive=1 audit: type=1400 audit(1517487900.562:4905): avc: denied { net_admin } for pid=4227 comm="syz-executor2" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487900.591:4906): avc: denied { net_admin } for pid=11450 comm="syz-executor7" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487900.594:4907): avc: denied { map } for pid=11459 comm="modprobe" path="/bin/kmod" dev="sda1" ino=1440 scontext=system_u:system_r:kernel_t:s0 tcontext=system_u:object_r:file_t:s0 tclass=file permissive=1 audit: type=1400 audit(1517487900.597:4908): avc: denied { net_admin } for pid=4225 comm="syz-executor5" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487900.603:4909): avc: denied { net_admin } for pid=4219 comm="syz-executor4" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487900.604:4911): avc: denied { map } for pid=11459 comm="modprobe" path="/etc/ld.so.cache" dev="sda1" ino=2503 scontext=system_u:system_r:kernel_t:s0 tcontext=system_u:object_r:file_t:s0 tclass=file permissive=1 audit: type=1400 audit(1517487900.603:4910): avc: denied { net_admin } for pid=4219 comm="syz-executor4" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 QAT: Invalid ioctl QAT: failed to copy from user. ptrace attach of "/root/syz-executor4"[4219] was attempted by "/root/syz-executor4"[11603] ptrace attach of "/root/syz-executor4"[4219] was attempted by "/root/syz-executor4"[11603] QAT: Invalid ioctl QAT: failed to copy from user. device eql entered promiscuous mode TCP: request_sock_TCP: Possible SYN flooding on port 20030. Sending cookies. Check SNMP counters. device eql entered promiscuous mode netlink: 'syz-executor7': attribute type 3 has an invalid length. do_dccp_getsockopt: sockopt(PACKET_SIZE) is deprecated: fix your app xt_CT: You must specify a L4 protocol, and not use inversions on it. device eql entered promiscuous mode binder: BINDER_SET_CONTEXT_MGR already set binder: 11936:11949 ioctl 40046207 0 returned -16 binder_alloc: 11936: binder_alloc_buf, no vma binder: 11936:11949 transaction failed 29189/-3, size 0-0 line 2903 binder: undelivered TRANSACTION_ERROR: 29189 binder: send failed reply for transaction 48 to 11936:11941 binder: undelivered TRANSACTION_COMPLETE binder: undelivered TRANSACTION_ERROR: 29189 sctp: [Deprecated]: syz-executor7 (pid 11984) Use of int in max_burst socket option deprecated. Use struct sctp_assoc_value instead sctp: [Deprecated]: syz-executor7 (pid 11984) Use of int in max_burst socket option deprecated. Use struct sctp_assoc_value instead ipt_CLUSTERIP: Please specify destination IP ipt_CLUSTERIP: Please specify destination IP QAT: Invalid ioctl QAT: Invalid ioctl xt_LED: No 'id' parameter given. xt_LED: No 'id' parameter given. loop_reread_partitions: partition scan of loop0 (Zl5fm1] ^7$><>qLW!^2“NFeu%m) failed (rc=-13) QAT: Stopping all acceleration devices. QAT: Invalid ioctl QAT: Stopping all acceleration devices. QAT: Invalid ioctl kauditd_printk_skb: 774 callbacks suppressed audit: type=1400 audit(1517487905.576:5686): avc: denied { dac_read_search } for pid=12436 comm="syz-executor3" capability=2 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487905.603:5687): avc: denied { dac_override } for pid=12432 comm="syz-executor2" capability=1 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487905.645:5688): avc: denied { dac_override } for pid=12432 comm="syz-executor2" capability=1 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487905.646:5689): avc: denied { net_admin } for pid=4226 comm="syz-executor3" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487905.655:5690): avc: denied { dac_override } for pid=12432 comm="syz-executor2" capability=1 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487905.680:5691): avc: denied { net_admin } for pid=4219 comm="syz-executor4" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487905.693:5692): avc: denied { net_admin } for pid=4231 comm="syz-executor0" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487905.698:5693): avc: denied { net_admin } for pid=4227 comm="syz-executor2" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487905.704:5694): avc: denied { net_admin } for pid=4220 comm="syz-executor1" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 audit: type=1400 audit(1517487905.704:5695): avc: denied { net_admin } for pid=4220 comm="syz-executor1" capability=12 scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=cap_userns permissive=1 xt_CT: You must specify a L4 protocol, and not use inversions on it. sctp: [Deprecated]: syz-executor6 (pid 12641) Use of struct sctp_assoc_value in delayed_ack socket option. Use struct sctp_sack_info instead ieee80211 phy2: Selected rate control algorithm 'minstrel_ht' ieee80211 phy3: Selected rate control algorithm 'minstrel_ht' syz-executor1: vmalloc: allocation failure: 0 bytes, mode:0x14000c0(GFP_KERNEL), nodemask=(null) syz-executor1 cpuset=/ mems_allowed=0 CPU: 1 PID: 12737 Comm: syz-executor1 Not tainted 4.15.0+ #290 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:53 warn_alloc+0x19a/0x2b0 mm/page_alloc.c:3306 __vmalloc_node_range+0x4f0/0x650 mm/vmalloc.c:1775 __vmalloc_node mm/vmalloc.c:1804 [inline] __vmalloc_node_flags mm/vmalloc.c:1818 [inline] vmalloc+0x45/0x50 mm/vmalloc.c:1840 sel_write_load+0x1f5/0x1910 security/selinux/selinuxfs.c:495 __vfs_write+0xef/0x970 fs/read_write.c:480 vfs_write+0x189/0x510 fs/read_write.c:544 SYSC_write fs/read_write.c:589 [inline] SyS_write+0xef/0x220 fs/read_write.c:581 entry_SYSCALL_64_fastpath+0x29/0xa0 RIP: 0033:0x453299 RSP: 002b:00007f9068b9bc58 EFLAGS: 00000212 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 00007f9068b9c700 RCX: 0000000000453299 RDX: 0000000000000000 RSI: 00000000200f8fd1 RDI: 0000000000000013 RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000212 R12: 0000000000000000 R13: 0000000000a2f33f R14: 00007f9068b9c9c0 R15: 0000000000000000 Mem-Info: active_anon:97841 inactive_anon:63 isolated_anon:0 active_file:3543 inactive_file:8388 isolated_file:0 unevictable:0 dirty:93 writeback:0 unstable:0 slab_reclaimable:11366 slab_unreclaimable:90397 mapped:24217 shmem:201 pagetables:810 bounce:0 free:1389242 free_pcp:423 free_cma:0 Node 0 active_anon:391364kB inactive_anon:252kB active_file:14172kB inactive_file:33552kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:96868kB dirty:372kB writeback:0kB shmem:804kB shmem_thp: 0kB shmem_pmdmapped: 0kB anon_thp: 149504kB writeback_tmp:0kB unstable:0kB all_unreclaimable? no Node 0 DMA free:15908kB min:164kB low:204kB high:244kB active_anon:0kB inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:0kB writepending:0kB present:15992kB managed:15908kB mlocked:0kB kernel_stack:0kB pagetables:0kB bounce:0kB free_pcp:0kB local_pcp:0kB free_cma:0kB lowmem_reserve[]: 0 2868 6378 6378 Node 0 DMA32 free:2939140kB min:30316kB low:37892kB high:45468kB active_anon:0kB inactive_anon:0kB active_file:0kB inactive_file:0kB unevictable:0kB writepending:0kB present:3129292kB managed:2939968kB mlocked:0kB kernel_stack:0kB pagetables:0kB bounce:0kB free_pcp:828kB local_pcp:676kB free_cma:0kB lowmem_reserve[]: 0 0 3510 3510 Node 0 Normal free:2601920kB min:37100kB low:46372kB high:55644kB active_anon:391364kB inactive_anon:252kB active_file:14172kB inactive_file:33552kB unevictable:0kB writepending:372kB present:4718592kB managed:3594332kB mlocked:0kB kernel_stack:4992kB pagetables:3240kB bounce:0kB free_pcp:864kB local_pcp:492kB free_cma:0kB lowmem_reserve[]: 0 0 0 0 Node 0 DMA: 1*4kB (U) 0*8kB 0*16kB 1*32kB (U) 2*64kB (U) 1*128kB (U) 1*256kB (U) 0*512kB 1*1024kB (U) 1*2048kB (M) 3*4096kB (M) = 15908kB Node 0 DMA32: 1*4kB (M) 2*8kB (UM) 3*16kB (UM) 2*32kB (M) 2*64kB (UM) 2*128kB (M) 3*256kB (UM) 4*512kB (UM) 3*1024kB (UM) 2*2048kB (UM) 715*4096kB (M) = 2939140kB Node 0 Normal: 372*4kB (UME) 617*8kB (UME) 1419*16kB (UM) 564*32kB (UME) 285*64kB (UM) 22*128kB (ME) 85*256kB (UME) 62*512kB (UME) 30*1024kB (UM) 14*2048kB (UME) 591*4096kB (UM) = 2601864kB Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=2048kB 12131 total pagecache pages 0 pages in swap cache Swap cache stats: add 0, delete 0, find 0/0 Free swap = 0kB Total swap = 0kB 1965969 pages RAM 0 pages HighMem/MovableOnly 328417 pages reserved loop_reread_partitions: partition scan of loop0 () failed (rc=-13) syz-executor1: vmalloc: allocation failure: 0 bytes, mode:0x14000c0(GFP_KERNEL), nodemask=(null) syz-executor1 cpuset=/ mems_allowed=0 CPU: 0 PID: 12749 Comm: syz-executor1 Not tainted 4.15.0+ #290 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Call Trace: __dump_stack lib/dump_stack.c:17 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:53 warn_alloc+0x19a/0x2b0 mm/page_alloc.c:3306 __vmalloc_node_range+0x4f0/0x650 mm/vmalloc.c:1775 __vmalloc_node mm/vmalloc.c:1804 [inline] __vmalloc_node_flags mm/vmalloc.c:1818 [inline] vmalloc+0x45/0x50 mm/vmalloc.c:1840 sel_write_load+0x1f5/0x1910 security/selinux/selinuxfs.c:495 __vfs_write+0xef/0x970 fs/read_write.c:480 vfs_write+0x189/0x510 fs/read_write.c:544 SYSC_write fs/read_write.c:589 [inline] SyS_write+0xef/0x220 fs/read_write.c:581 entry_SYSCALL_64_fastpath+0x29/0xa0 RIP: 0033:0x453299 RSP: 002b:00007f9068b7ac58 EFLAGS: 00000212 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 000000000071bf58 RCX: 0000000000453299 RDX: 0000000000000000 RSI: 00000000200f8fd1 RDI: 0000000000000015 RBP: 00000000000005f9 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000212 R12: 00000000006f7ff8 R13: 00000000ffffffff R14: 00007f9068b7b6d4 R15: 0000000000000002 binder: BINDER_SET_CONTEXT_MGR already set binder: 12761:12768 ioctl 40046207 0 returned -16 binder_alloc: 12761: binder_alloc_buf, no vma binder: 12761:12768 transaction failed 29189/-3, size 0-0 line 2903 binder: undelivered TRANSACTION_ERROR: 29189 binder: send failed reply for transaction 51 to 12761:12763 binder: undelivered TRANSACTION_COMPLETE binder: undelivered TRANSACTION_ERROR: 29189