====================================================== WARNING: possible circular locking dependency detected 4.13.0-rc6-next-20170824+ #8 Not tainted ------------------------------------------------------ kworker/1:1/23 is trying to acquire lock: (rcu_sched_state.barrier_mutex){+.+.}, at: [] _rcu_barrier+0x13f/0x7a0 kernel/rcu/tree.c:3502 but task is already holding lock: ((&map->work)){+.+.}, at: [] process_one_work+0xb2c/0x1be0 kernel/workqueue.c:2094 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #3 ((&map->work)){+.+.}: process_one_work+0xba5/0x1be0 kernel/workqueue.c:2095 worker_thread+0x223/0x1860 kernel/workqueue.c:2233 kthread+0x39c/0x470 kernel/kthread.c:231 ret_from_fork+0x2a/0x40 arch/x86/entry/entry_64.S:431 0xffffffffffffffff -> #2 ((complete)&rcu.completion){+.+.}: check_prevs_add kernel/locking/lockdep.c:2020 [inline] validate_chain kernel/locking/lockdep.c:2469 [inline] __lock_acquire+0x3286/0x4620 kernel/locking/lockdep.c:3498 lock_acquire+0x1d5/0x580 kernel/locking/lockdep.c:4002 complete_acquire include/linux/completion.h:39 [inline] __wait_for_common kernel/sched/completion.c:108 [inline] wait_for_common kernel/sched/completion.c:122 [inline] wait_for_completion+0xc8/0x770 kernel/sched/completion.c:143 __synchronize_srcu+0x1b5/0x250 kernel/rcu/srcutree.c:898 synchronize_srcu_expedited kernel/rcu/srcutree.c:923 [inline] synchronize_srcu+0x1a3/0x560 kernel/rcu/srcutree.c:974 quarantine_remove_cache+0xd7/0xf0 mm/kasan/quarantine.c:327 kasan_cache_shrink+0x9/0x10 mm/kasan/kasan.c:380 kmem_cache_shrink+0x15/0x30 mm/slab_common.c:857 acpi_os_purge_cache+0x15/0x20 drivers/acpi/osl.c:1560 acpi_purge_cached_objects+0x38/0xc9 drivers/acpi/acpica/utxface.c:271 acpi_initialize_objects+0xc5/0x112 drivers/acpi/acpica/utxfinit.c:302 acpi_bus_init drivers/acpi/bus.c:1131 [inline] acpi_init+0x23c/0x8e6 drivers/acpi/bus.c:1220 do_one_initcall+0x9e/0x330 init/main.c:826 do_initcall_level init/main.c:892 [inline] do_initcalls init/main.c:900 [inline] do_basic_setup init/main.c:918 [inline] kernel_init_freeable+0x469/0x521 init/main.c:1066 kernel_init+0x13/0x172 init/main.c:993 ret_from_fork+0x2a/0x40 arch/x86/entry/entry_64.S:431 -> #1 (cpu_hotplug_lock.rw_sem){++++}: check_prevs_add kernel/locking/lockdep.c:2020 [inline] validate_chain kernel/locking/lockdep.c:2469 [inline] __lock_acquire+0x3286/0x4620 kernel/locking/lockdep.c:3498 lock_acquire+0x1d5/0x580 kernel/locking/lockdep.c:4002 percpu_down_read_preempt_disable include/linux/percpu-rwsem.h:35 [inline] percpu_down_read include/linux/percpu-rwsem.h:58 [inline] cpus_read_lock+0x42/0x90 kernel/cpu.c:218 get_online_cpus include/linux/cpu.h:126 [inline] _rcu_barrier+0x33d/0x7a0 kernel/rcu/tree.c:3525 rcu_barrier_sched kernel/rcu/tree.c:3591 [inline] rcu_barrier+0x10/0x20 kernel/rcu/tree_plugin.h:891 netdev_run_todo+0x28f/0xca0 net/core/dev.c:7824 rtnl_unlock+0xe/0x10 net/core/rtnetlink.c:106 tun_detach drivers/net/tun.c:588 [inline] tun_chr_close+0x49/0x60 drivers/net/tun.c:2595 __fput+0x333/0x7f0 fs/file_table.c:210 ____fput+0x15/0x20 fs/file_table.c:246 task_work_run+0x199/0x270 kernel/task_work.c:112 exit_task_work include/linux/task_work.h:21 [inline] do_exit+0xa52/0x1b40 kernel/exit.c:865 do_group_exit+0x149/0x400 kernel/exit.c:968 get_signal+0x7e8/0x17e0 kernel/signal.c:2334 do_signal+0x94/0x1ee0 arch/x86/kernel/signal.c:808 exit_to_usermode_loop+0x224/0x300 arch/x86/entry/common.c:158 prepare_exit_to_usermode arch/x86/entry/common.c:197 [inline] syscall_return_slowpath+0x42f/0x500 arch/x86/entry/common.c:266 entry_SYSCALL_64_fastpath+0xbc/0xbe -> #0 (rcu_sched_state.barrier_mutex){+.+.}: check_prev_add+0x865/0x1520 kernel/locking/lockdep.c:1894 check_prevs_add kernel/locking/lockdep.c:2020 [inline] validate_chain kernel/locking/lockdep.c:2469 [inline] __lock_acquire+0x3286/0x4620 kernel/locking/lockdep.c:3498 lock_acquire+0x1d5/0x580 kernel/locking/lockdep.c:4002 __mutex_lock_common kernel/locking/mutex.c:756 [inline] __mutex_lock+0x16f/0x1870 kernel/locking/mutex.c:893 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:908 _rcu_barrier+0x13f/0x7a0 kernel/rcu/tree.c:3502 rcu_barrier_sched kernel/rcu/tree.c:3591 [inline] rcu_barrier+0x10/0x20 kernel/rcu/tree_plugin.h:891 htab_map_free+0x9d/0x640 kernel/bpf/hashtab.c:1112 bpf_map_free_deferred+0xac/0xd0 kernel/bpf/syscall.c:209 process_one_work+0xbfd/0x1be0 kernel/workqueue.c:2098 worker_thread+0x223/0x1860 kernel/workqueue.c:2233 kthread+0x39c/0x470 kernel/kthread.c:231 ret_from_fork+0x2a/0x40 arch/x86/entry/entry_64.S:431 other info that might help us debug this: Chain exists of: rcu_sched_state.barrier_mutex --> (complete)&rcu.completion --> (&map->work) Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock((&map->work)); lock((complete)&rcu.completion); lock((&map->work)); lock(rcu_sched_state.barrier_mutex); *** DEADLOCK *** 2 locks held by kworker/1:1/23: #0: ("events"){.+.+}, at: [] __write_once_size include/linux/compiler.h:305 [inline] #0: ("events"){.+.+}, at: [] atomic64_set arch/x86/include/asm/atomic64_64.h:33 [inline] #0: ("events"){.+.+}, at: [] atomic_long_set include/asm-generic/atomic-long.h:56 [inline] #0: ("events"){.+.+}, at: [] set_work_data kernel/workqueue.c:617 [inline] #0: ("events"){.+.+}, at: [] set_work_pool_and_clear_pending kernel/workqueue.c:644 [inline] #0: ("events"){.+.+}, at: [] process_one_work+0xad4/0x1be0 kernel/workqueue.c:2090 #1: ((&map->work)){+.+.}, at: [] process_one_work+0xb2c/0x1be0 kernel/workqueue.c:2094 stack backtrace: CPU: 1 PID: 23 Comm: kworker/1:1 Not tainted 4.13.0-rc6-next-20170824+ #8 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 Workqueue: events bpf_map_free_deferred Call Trace: __dump_stack lib/dump_stack.c:16 [inline] dump_stack+0x194/0x257 lib/dump_stack.c:52 print_circular_bug+0x503/0x710 kernel/locking/lockdep.c:1259 check_prev_add+0x865/0x1520 kernel/locking/lockdep.c:1894 check_prevs_add kernel/locking/lockdep.c:2020 [inline] validate_chain kernel/locking/lockdep.c:2469 [inline] __lock_acquire+0x3286/0x4620 kernel/locking/lockdep.c:3498 lock_acquire+0x1d5/0x580 kernel/locking/lockdep.c:4002 __mutex_lock_common kernel/locking/mutex.c:756 [inline] __mutex_lock+0x16f/0x1870 kernel/locking/mutex.c:893 mutex_lock_nested+0x16/0x20 kernel/locking/mutex.c:908 _rcu_barrier+0x13f/0x7a0 kernel/rcu/tree.c:3502 rcu_barrier_sched kernel/rcu/tree.c:3591 [inline] rcu_barrier+0x10/0x20 kernel/rcu/tree_plugin.h:891 htab_map_free+0x9d/0x640 kernel/bpf/hashtab.c:1112 bpf_map_free_deferred+0xac/0xd0 kernel/bpf/syscall.c:209 process_one_work+0xbfd/0x1be0 kernel/workqueue.c:2098 worker_thread+0x223/0x1860 kernel/workqueue.c:2233 kthread+0x39c/0x470 kernel/kthread.c:231 ret_from_fork+0x2a/0x40 arch/x86/entry/entry_64.S:431 Assertion failed! net/irda/ircomm/ircomm_core.c:ircomm_flow_request:475 self != NULL audit: type=1326 audit(1503586402.480:5): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=kernel pid=3766 comm="syz-executor4" exe="/root/syz-executor4" sig=31 arch=c000003e syscall=202 compat=0 ip=0x4512e9 code=0xffff0000 raw_sendmsg: syz-executor3 forgot to set AF_INET. Fix it! audit: type=1326 audit(1503586402.550:6): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=kernel pid=3766 comm="syz-executor4" exe="/root/syz-executor4" sig=31 arch=c000003e syscall=202 compat=0 ip=0x4512e9 code=0xffff0000 capability: warning: `syz-executor0' uses 32-bit capabilities (legacy support in use) SELinux: unrecognized netlink message: protocol=0 nlmsg_type=0 sclass=netlink_route_socket pig=3834 comm=syz-executor1 kvm [3905]: vcpu0, guest rIP: 0x660c Hyper-V uhandled wrmsr: 0x40000020 data 0x400 kvm [3905]: vcpu0, guest rIP: 0x660c Hyper-V uhandled wrmsr: 0x40000020 data 0x400 QAT: Invalid ioctl QAT: Invalid ioctl audit: type=1326 audit(1503586403.582:7): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=kernel pid=4006 comm="syz-executor1" exe="/root/syz-executor1" sig=9 arch=c000003e syscall=202 compat=0 ip=0x4512e9 code=0x0 audit: type=1326 audit(1503586403.739:8): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=kernel pid=4006 comm="syz-executor1" exe="/root/syz-executor1" sig=9 arch=c000003e syscall=202 compat=0 ip=0x4512e9 code=0x0 devpts: called with bogus options devpts: called with bogus options nla_parse: 3 callbacks suppressed netlink: 13 bytes leftover after parsing attributes in process `syz-executor1'. kvm: apic: phys broadcast and lowest prio *** Guest State *** CR0: actual=0x0000000080000033, shadow=0x0000000060000033, gh_mask=fffffffffffffff7 CR4: actual=0x0000000000002050, shadow=0x0000000000000020, gh_mask=fffffffffffff871 CR3 = 0x00000000fffbc000 RSP = 0x0000000000000f80 RIP = 0x0000000000000000 RFLAGS=0x00000002 DR7 = 0x0000000086d807a4 Sysenter RSP=0000000000000f80 CS:RIP=0050:0000000000002810 CS: sel=0x0030, attr=0x0409b, limit=0x000fffff, base=0x0000000000000000 DS: sel=0x0038, attr=0x04093, limit=0x000fffff, base=0x0000000000000000 SS: sel=0x0038, attr=0x04093, limit=0x000fffff, base=0x0000000000000000 ES: sel=0x0038, attr=0x04093, limit=0x000fffff, base=0x0000000000000000 FS: sel=0x0038, attr=0x04093, limit=0x000fffff, base=0x0000000000000000 GS: sel=0x0038, attr=0x04093, limit=0x000fffff, base=0x0000000000000000 GDTR: limit=0x000007ff, base=0x0000000000001000 LDTR: sel=0x0008, attr=0x04082, limit=0x000007ff, base=0x0000000000001800 IDTR: limit=0x000001ff, base=0x0000000000003800 TR: sel=0x00d0, attr=0x0008b, limit=0x000001ff, base=0x0000000000004e00 EFER = 0x0000000000004001 PAT = 0x0007040600070406 DebugCtl = 0x0000000000000000 DebugExceptions = 0x0000000000000000 Interruptibility = 00000000 ActivityState = 00000000 *** Host State *** RIP = 0xffffffff811b6277 RSP = 0xffff8801c11674c8 CS=0010 SS=0018 DS=0000 ES=0000 FS=0000 GS=0000 TR=0040 FSBase=00007f69a710f700 GSBase=ffff8801db200000 TRBase=ffff8801db223100 GDTBase=ffffffffff577000 IDTBase=ffffffffff57b000 CR0=0000000080050033 CR3=00000001c11de000 CR4=00000000001426f0 Sysenter RSP=0000000000000000 CS:RIP=0010:ffffffff84d9d0a0 EFER = 0x0000000000000d01 PAT = 0x0000000000000000 *** Control State *** PinBased=0000003f CPUBased=b6a1edfe SecondaryExec=0000004b EntryControls=0000d1ff ExitControls=0023efff ExceptionBitmap=00060042 PFECmask=00000000 PFECmatch=00000000 VMEntry: intr_info=00000b0d errcode=00000000 ilen=00000000 VMExit: intr_info=00000000 errcode=00000000 ilen=00000003 reason=80000021 qualification=0000000000000000 IDTVectoring: info=00000000 errcode=00000000 TSC Offset = 0xffffffdf244f7dc0 TPR Threshold = 0x00 EPT pointer = 0x00000001c181801e SELinux: unrecognized netlink message: protocol=0 nlmsg_type=6 sclass=netlink_route_socket pig=4287 comm=syz-executor4 SELinux: unrecognized netlink message: protocol=0 nlmsg_type=6 sclass=netlink_route_socket pig=4299 comm=syz-executor4 mmap: syz-executor4 (4352) uses deprecated remap_file_pages() syscall. See Documentation/vm/remap_file_pages.txt. device lo entered promiscuous mode cgroup: cgroup2: unknown option "" cgroup: cgroup2: unknown option "" SELinux: failure in selinux_parse_skb(), unable to parse packet capability: warning: `syz-executor5' uses deprecated v2 capabilities in a way that may be insecure device syz1 entered promiscuous mode device lo entered promiscuous mode device syz1 left promiscuous mode device syz1 entered promiscuous mode SELinux: unrecognized netlink message: protocol=0 nlmsg_type=0 sclass=netlink_route_socket pig=4945 comm=syz-executor3 rpcbind: RPC call returned error 22 rpcbind: RPC call returned error 22 sctp: [Deprecated]: syz-executor1 (pid 4993) Use of int in maxseg socket option. Use struct sctp_assoc_value instead audit: type=1326 audit(1503586406.796:9): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=kernel pid=5006 comm="syz-executor7" exe="/root/syz-executor7" sig=31 arch=c000003e syscall=202 compat=0 ip=0x4512e9 code=0xffff0000 sctp: [Deprecated]: syz-executor1 (pid 5028) Use of int in maxseg socket option. Use struct sctp_assoc_value instead sctp: [Deprecated]: syz-executor1 (pid 5007) Use of int in maxseg socket option. Use struct sctp_assoc_value instead audit: type=1326 audit(1503586406.889:10): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=kernel pid=5006 comm="syz-executor7" exe="/root/syz-executor7" sig=31 arch=c000003e syscall=202 compat=0 ip=0x4512e9 code=0xffff0000 sctp: [Deprecated]: syz-executor1 (pid 5028) Use of int in maxseg socket option. Use struct sctp_assoc_value instead audit: type=1326 audit(1503586406.982:11): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=kernel pid=5069 comm="syz-executor7" exe="/root/syz-executor7" sig=31 arch=c000003e syscall=202 compat=0 ip=0x4512e9 code=0xffff0000 QAT: Invalid ioctl audit: type=1326 audit(1503586407.069:12): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=kernel pid=5069 comm="syz-executor7" exe="/root/syz-executor7" sig=31 arch=c000003e syscall=202 compat=0 ip=0x4512e9 code=0xffff0000 QAT: Invalid ioctl sg_write: data in/out 393180/6 bytes for SCSI command 0x27-- guessing data in; program syz-executor7 not setting count and/or reply_len properly TCP: request_sock_TCPv6: Possible SYN flooding on port 20021. Sending cookies. Check SNMP counters. netlink: 13 bytes leftover after parsing attributes in process `syz-executor5'. netlink: 13 bytes leftover after parsing attributes in process `syz-executor5'. netlink: 9 bytes leftover after parsing attributes in process `syz-executor5'. SELinux: unrecognized netlink message: protocol=0 nlmsg_type=6 sclass=netlink_route_socket pig=5416 comm=syz-executor6 SELinux: unrecognized netlink message: protocol=0 nlmsg_type=6 sclass=netlink_route_socket pig=5457 comm=syz-executor6 QAT: Invalid ioctl netlink: 1 bytes leftover after parsing attributes in process `syz-executor6'. netlink: 1 bytes leftover after parsing attributes in process `syz-executor6'. netlink: 3 bytes leftover after parsing attributes in process `syz-executor5'. netlink: 1 bytes leftover after parsing attributes in process `syz-executor5'. netlink: 3 bytes leftover after parsing attributes in process `syz-executor5'. netlink: 1 bytes leftover after parsing attributes in process `syz-executor5'. netlink: 5 bytes leftover after parsing attributes in process `syz-executor2'. netlink: 5 bytes leftover after parsing attributes in process `syz-executor2'. TCP: request_sock_TCP: Possible SYN flooding on port 20031. Sending cookies. Check SNMP counters. device lo left promiscuous mode loop_reread_partitions: partition scan of loop0 (-\t@r9hxGQ:[il L*@R-Tr-x) failed (rc=-13) kvm [5958]: vcpu2, guest rIP: 0xfff0 disabled perfctr wrmsr: 0x186 data 0x8 kvm [5958]: vcpu2, guest rIP: 0xfff0 disabled perfctr wrmsr: 0x186 data 0x8 QAT: Invalid ioctl SELinux: unrecognized netlink message: protocol=0 nlmsg_type=0 sclass=netlink_route_socket pig=6161 comm=syz-executor6 SELinux: unrecognized netlink message: protocol=0 nlmsg_type=0 sclass=netlink_route_socket pig=6181 comm=syz-executor6 syz-executor7 (6218) used greatest stack depth: 15032 bytes left audit: type=1326 audit(1503586411.312:13): auid=4294967295 uid=0 gid=0 ses=4294967295 subj=kernel pid=6397 comm="syz-executor5" exe="/root/syz-executor5" sig=31 arch=c000003e syscall=202 compat=0 ip=0x4512e9 code=0xffff0000