====================================================== WARNING: possible circular locking dependency detected 4.15.0+ #290 Not tainted ------------------------------------------------------ syz-executor6/11729 is trying to acquire lock: (rtnl_mutex){+.+.}, at: [<00000000ba14ae79>] rtnl_lock+0x17/0x20 net/core/rtnetlink.c:74 but task is already holding lock: (sk_lock-AF_INET){+.+.}, at: [<00000000ec67bf0f>] lock_sock include/net/sock.h:1461 [inline] (sk_lock-AF_INET){+.+.}, at: [<00000000ec67bf0f>] 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_setsockopt.isra.12+0x1d9/0x3210 net/ipv4/ip_sockglue.c:646 ip_setsockopt+0x3a/0xb0 net/ipv4/ip_sockglue.c:1252 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 -> #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-executor6/11729: #0: (sk_lock-AF_INET){+.+.}, at: [<00000000ec67bf0f>] lock_sock include/net/sock.h:1461 [inline] #0: (sk_lock-AF_INET){+.+.}, at: [<00000000ec67bf0f>] ip_setsockopt+0x8c/0xb0 net/ipv4/ip_sockglue.c:1259 stack backtrace: CPU: 0 PID: 11729 Comm: syz-executor6 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:00007f81ad0d4c58 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: 00007f81ad0d56d4 R15: 0000000000000000 snd_dummy snd_dummy.0: control 120:0:0::0 is already present x_tables: ip_tables: ipcomp match: only valid for protocol 108 x_tables: ip_tables: ipcomp match: only valid for protocol 108 QAT: Invalid ioctl QAT: Invalid ioctl binder: 11854:11857 BC_ACQUIRE_DONE u0000000000000000 no match binder: 11854:11867 BC_ACQUIRE_DONE u0000000000000000 no match device eql entered promiscuous mode kvm [11947]: vcpu0, guest rIP: 0xfff0 Hyper-V uhandled wrmsr: 0x40000020 data 0x0 kvm [11947]: vcpu0, guest rIP: 0xfff0 Hyper-V uhandled wrmsr: 0x40000020 data 0x0 QAT: Invalid ioctl QAT: Invalid ioctl could not allocate digest TFM handle ߘi5!Ij&`+Qo- gǽ$Wtd could not allocate digest TFM handle ߘi5!Ij&`+Qo- gǽ$Wtd tty_warn_deprecated_flags: 'syz-executor1' is using deprecated serial flags (with no effect): 00000200 tty_warn_deprecated_flags: 'syz-executor1' is using deprecated serial flags (with no effect): 00000200 kauditd_printk_skb: 265 callbacks suppressed audit: type=1400 audit(1517487109.016:821): avc: denied { relabelto } for pid=12389 comm="syz-executor5" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=system_u:object_r:policy_src_t:s0 tclass=packet permissive=1 binder: 12454 RLIMIT_NICE not set binder: 12464 RLIMIT_NICE not set syz-executor1: vmalloc: allocation failure: 0 bytes, mode:0x14000c0(GFP_KERNEL), nodemask=(null) syz-executor1 cpuset=/ mems_allowed=0 CPU: 1 PID: 12537 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:00007f271039ac58 EFLAGS: 00000212 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 00007f271039a950 RCX: 0000000000453299 RDX: 0000000000000000 RSI: 00000000200f8fd1 RDI: 0000000000000013 RBP: 00007f271039a940 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000212 R12: 00000000004b7d7d R13: 00007f271039aac8 R14: 00000000004b7d8f R15: 0000000000000000 warn_alloc_show_mem: 1 callbacks suppressed Mem-Info: active_anon:70926 inactive_anon:63 isolated_anon:0 active_file:3580 inactive_file:8314 isolated_file:0 unevictable:0 dirty:162 writeback:0 unstable:0 slab_reclaimable:9974 slab_unreclaimable:88813 mapped:24117 shmem:69 pagetables:756 bounce:0 free:1418376 free_pcp:430 free_cma:0 Node 0 active_anon:285644kB inactive_anon:252kB active_file:14320kB inactive_file:33256kB unevictable:0kB isolated(anon):0kB isolated(file):0kB mapped:96468kB dirty:648kB writeback:0kB shmem:276kB shmem_thp: 0kB shmem_pmdmapped: 0kB anon_thp: 51200kB 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:680kB free_cma:0kB lowmem_reserve[]: 0 0 3510 3510 Node 0 Normal free:2704284kB min:37100kB low:46372kB high:55644kB active_anon:300036kB inactive_anon:272kB active_file:14400kB inactive_file:33200kB unevictable:0kB writepending:668kB present:4718592kB managed:3594332kB mlocked:0kB kernel_stack:4544kB pagetables:3108kB bounce:0kB free_pcp:712kB local_pcp:616kB 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 rfkill: input handler disabled 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: 25*4kB (ME) 125*8kB (UM) 71*16kB (UME) 1066*32kB (UM) 861*64kB (UM) 151*128kB (UME) 25*256kB (UME) 27*512kB (UME) 25*1024kB (UM) 4*2048kB (UM) 620*4096kB (M) = 2704316kB Node 0 hugepages_total=0 hugepages_free=0 hugepages_surp=0 hugepages_size=2048kB 11973 total pagecache pages 0 pages in swap cache Swap cache stats: add 0, delete 0, find 0/0 Free swap = 0kB Total swap = 0kB rfkill: input handler enabled 1965969 pages RAM 0 pages HighMem/MovableOnly 328417 pages reserved IPVS: ftp: loaded support on port[0] = 21 IPv6: ADDRCONF(NETDEV_UP): bridge0: link is not ready audit: type=1326 audit(1517487111.468:822): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=12781 comm="syz-executor0" exe="/root/syz-executor0" sig=0 arch=c000003e syscall=202 compat=0 ip=0x453299 code=0x7ffc0000 audit: type=1326 audit(1517487111.475:823): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=12781 comm="syz-executor0" exe="/root/syz-executor0" sig=0 arch=c000003e syscall=154 compat=0 ip=0x453299 code=0x7ffc0000 audit: type=1326 audit(1517487111.476:824): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=12781 comm="syz-executor0" exe="/root/syz-executor0" sig=0 arch=c000003e syscall=202 compat=0 ip=0x453299 code=0x7ffc0000 audit: type=1326 audit(1517487111.476:825): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=12781 comm="syz-executor0" exe="/root/syz-executor0" sig=0 arch=c000003e syscall=2 compat=0 ip=0x40d591 code=0x7ffc0000 audit: type=1326 audit(1517487111.476:826): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=12781 comm="syz-executor0" exe="/root/syz-executor0" sig=0 arch=c000003e syscall=202 compat=0 ip=0x453299 code=0x7ffc0000 audit: type=1326 audit(1517487111.477:827): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=12781 comm="syz-executor0" exe="/root/syz-executor0" sig=0 arch=c000003e syscall=55 compat=0 ip=0x453299 code=0x7ffc0000 audit: type=1326 audit(1517487111.478:828): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=12781 comm="syz-executor0" exe="/root/syz-executor0" sig=0 arch=c000003e syscall=202 compat=0 ip=0x453299 code=0x7ffc0000 audit: type=1326 audit(1517487111.479:829): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=12781 comm="syz-executor0" exe="/root/syz-executor0" sig=0 arch=c000003e syscall=55 compat=0 ip=0x453299 code=0x7ffc0000 audit: type=1326 audit(1517487111.479:830): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 pid=12781 comm="syz-executor0" exe="/root/syz-executor0" sig=0 arch=c000003e syscall=202 compat=0 ip=0x453299 code=0x7ffc0000 netlink: 3 bytes leftover after parsing attributes in process `syz-executor2'. netlink: 3 bytes leftover after parsing attributes in process `syz-executor2'. netlink: 3 bytes leftover after parsing attributes in process `syz-executor2'. netlink: 3 bytes leftover after parsing attributes in process `syz-executor2'. tc_dump_action: action bad kind tc_dump_action: action bad kind PF_BRIDGE: br_mdb_parse() with unknown ifindex PF_BRIDGE: br_mdb_parse() with unknown ifindex binder: 13268 RLIMIT_NICE not set binder_alloc: 13252: binder_alloc_buf, no vma binder: 13252:13284 transaction failed 29189/-3, size 0-0 line 2903 binder: BINDER_SET_CONTEXT_MGR already set binder: 13252:13298 ioctl 40046207 0 returned -16 binder: 13284 RLIMIT_NICE not set binder_alloc: 13252: binder_alloc_buf, no vma binder: 13252:13298 transaction failed 29189/-3, size 0-0 line 2903 binder: undelivered TRANSACTION_ERROR: 29189 binder: undelivered TRANSACTION_ERROR: 29189 kauditd_printk_skb: 51 callbacks suppressed audit: type=1400 audit(1517487114.030:882): avc: denied { prog_run } for pid=13306 comm="syz-executor0" scontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tcontext=unconfined_u:system_r:insmod_t:s0-s0:c0.c1023 tclass=bpf permissive=1 netlink: 'syz-executor1': attribute type 1 has an invalid length. ipt_ECN: unsupported ECN operation 2 ipt_ECN: unsupported ECN operation 2