[ OK ] Started Update UTMP about System Runlevel Changes. [ OK ] Started Load/Save RF Kill Switch Status. Debian GNU/Linux 9 syzkaller ttyS0 Warning: Permanently added '10.128.1.121' (ECDSA) to the list of known hosts. executing program syzkaller login: [ 29.071483] ip6_tables: ip6tables: counters copy to user failed while replacing table [ 29.084891] IPVS: ftp: loaded support on port[0] = 21 executing program executing program [ 29.148941] ip6_tables: ip6tables: counters copy to user failed while replacing table [ 29.161616] IPVS: ftp: loaded support on port[0] = 21 [ 29.203072] ip6_tables: ip6tables: counters copy to user failed while replacing table [ 29.243794] [ 29.245459] ====================================================== [ 29.253041] WARNING: possible circular locking dependency detected [ 29.260892] 4.14.227-syzkaller #0 Not tainted [ 29.266316] ------------------------------------------------------ [ 29.272968] kworker/u4:1/22 is trying to acquire lock: [ 29.278855] (&table[i].mutex){+.+.}, at: [] nf_tables_netdev_event+0x10d/0x4d0 [ 29.288091] [ 29.288091] but task is already holding lock: [ 29.294666] (rtnl_mutex){+.+.}, at: [] ip6gre_exit_net+0x70/0x570 [ 29.302760] [ 29.302760] which lock already depends on the new lock. [ 29.302760] [ 29.311908] [ 29.311908] the existing dependency chain (in reverse order) is: [ 29.320352] [ 29.320352] -> #2 (rtnl_mutex){+.+.}: [ 29.326298] __mutex_lock+0xc4/0x1310 [ 29.330911] unregister_netdevice_notifier+0x5e/0x2b0 [ 29.337123] tee_tg_destroy+0x5c/0xb0 [ 29.341839] cleanup_entry+0x232/0x310 [ 29.346380] __do_replace+0x38d/0x580 [ 29.350943] do_ip6t_set_ctl+0x256/0x3b0 [ 29.355859] nf_setsockopt+0x5f/0xb0 [ 29.360090] ipv6_setsockopt+0xc0/0x120 [ 29.364584] tcp_setsockopt+0x7b/0xc0 [ 29.369518] SyS_setsockopt+0x110/0x1e0 [ 29.374511] do_syscall_64+0x1d5/0x640 [ 29.379092] entry_SYSCALL_64_after_hwframe+0x46/0xbb [ 29.385206] [ 29.385206] -> #1 (&xt[i].mutex){+.+.}: [ 29.391026] __mutex_lock+0xc4/0x1310 [ 29.395636] target_revfn+0x43/0x210 [ 29.400122] xt_find_revision+0x15e/0x1d0 [ 29.405931] nfnl_compat_get+0x1f7/0x870 [ 29.410975] nfnetlink_rcv_msg+0x9bb/0xc00 [ 29.415904] netlink_rcv_skb+0x125/0x390 [ 29.420970] nfnetlink_rcv+0x1ab/0x1da0 [ 29.425752] netlink_unicast+0x437/0x610 [ 29.430523] netlink_sendmsg+0x62e/0xb80 [ 29.435197] sock_sendmsg+0xb5/0x100 [ 29.439659] ___sys_sendmsg+0x6c8/0x800 [ 29.444143] __sys_sendmsg+0xa3/0x120 [ 29.448525] SyS_sendmsg+0x27/0x40 [ 29.452638] do_syscall_64+0x1d5/0x640 [ 29.457170] entry_SYSCALL_64_after_hwframe+0x46/0xbb [ 29.463063] [ 29.463063] -> #0 (&table[i].mutex){+.+.}: [ 29.468948] lock_acquire+0x170/0x3f0 [ 29.473793] __mutex_lock+0xc4/0x1310 [ 29.479003] nf_tables_netdev_event+0x10d/0x4d0 [ 29.484905] notifier_call_chain+0x108/0x1a0 [ 29.490083] rollback_registered_many+0x765/0xba0 [ 29.495711] unregister_netdevice_many.part.0+0x18/0x2e0 [ 29.501854] unregister_netdevice_many+0x36/0x50 [ 29.507429] ip6gre_exit_net+0x41e/0x570 [ 29.512493] ops_exit_list+0xa5/0x150 [ 29.516808] cleanup_net+0x3b3/0x840 [ 29.521178] process_one_work+0x793/0x14a0 [ 29.526014] worker_thread+0x5cc/0xff0 [ 29.530782] kthread+0x30d/0x420 [ 29.535018] ret_from_fork+0x24/0x30 [ 29.539419] [ 29.539419] other info that might help us debug this: [ 29.539419] [ 29.548072] Chain exists of: [ 29.548072] &table[i].mutex --> &xt[i].mutex --> rtnl_mutex [ 29.548072] [ 29.558554] Possible unsafe locking scenario: [ 29.558554] [ 29.565441] CPU0 CPU1 [ 29.570572] ---- ---- [ 29.575734] lock(rtnl_mutex); [ 29.579409] lock(&xt[i].mutex); [ 29.585922] lock(rtnl_mutex); [ 29.591730] lock(&table[i].mutex); [ 29.595820] [ 29.595820] *** DEADLOCK *** [ 29.595820] [ 29.602361] 4 locks held by kworker/u4:1/22: [ 29.607112] #0: ("%s""netns"){+.+.}, at: [] process_one_work+0x6b0/0x14a0 [ 29.616623] #1: (net_cleanup_work){+.+.}, at: [] process_one_work+0x6e6/0x14a0 [ 29.626417] #2: (net_mutex){+.+.}, at: [] cleanup_net+0x110/0x840 [ 29.634930] #3: (rtnl_mutex){+.+.}, at: [] ip6gre_exit_net+0x70/0x570 [ 29.643894] [ 29.643894] stack backtrace: [ 29.648637] CPU: 1 PID: 22 Comm: kworker/u4:1 Not tainted 4.14.227-syzkaller #0 [ 29.656799] Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011 [ 29.666979] Workqueue: netns cleanup_net [ 29.671431] Call Trace: [ 29.674376] dump_stack+0x1b2/0x281 [ 29.678327] print_circular_bug.constprop.0.cold+0x2d7/0x41e [ 29.684791] __lock_acquire+0x2e0e/0x3f20 [ 29.689398] ? unwind_next_frame+0x404/0x17d0 [ 29.694567] ? trace_hardirqs_on+0x10/0x10 [ 29.698998] ? check_usage_forwards+0x2d0/0x2d0 [ 29.704132] ? ret_from_fork+0x24/0x30 [ 29.708227] lock_acquire+0x170/0x3f0 [ 29.712836] ? nf_tables_netdev_event+0x10d/0x4d0 [ 29.717849] ? nf_tables_netdev_event+0x10d/0x4d0 [ 29.723240] __mutex_lock+0xc4/0x1310 [ 29.727865] ? nf_tables_netdev_event+0x10d/0x4d0 [ 29.733333] ? nf_tables_netdev_event+0x10d/0x4d0 [ 29.739615] ? __ww_mutex_wakeup_for_backoff+0x210/0x210 [ 29.745819] ? trace_hardirqs_on+0x10/0x10 [ 29.750300] ? trace_hardirqs_on_caller+0x3a8/0x580 [ 29.755652] ? lock_downgrade+0x740/0x740 [ 29.760369] nf_tables_netdev_event+0x10d/0x4d0 [ 29.766091] ? mirred_device_event+0x12f/0x170 [ 29.771161] ? nf_tables_netdev_init_net+0x140/0x140 [ 29.776491] ? mirred_device_event+0x12f/0x170 [ 29.781422] ? __local_bh_enable_ip+0xc1/0x170 [ 29.786349] notifier_call_chain+0x108/0x1a0 [ 29.791449] rollback_registered_many+0x765/0xba0 [ 29.797014] ? __ww_mutex_wakeup_for_backoff+0x210/0x210 [ 29.802821] ? netdev_state_change+0xf0/0xf0 [ 29.807372] ? lock_acquire+0x170/0x3f0 [ 29.811496] unregister_netdevice_many.part.0+0x18/0x2e0 [ 29.817513] unregister_netdevice_many+0x36/0x50 [ 29.822338] ip6gre_exit_net+0x41e/0x570 [ 29.826877] ? lock_downgrade+0x740/0x740 [ 29.831047] ? ip6gre_dellink+0x260/0x260 [ 29.835201] ? ip6gre_dellink+0x260/0x260 [ 29.840368] ops_exit_list+0xa5/0x150 [ 29.844505] cleanup_net+0x3b3/0x840 [ 29.848847] ? net_drop_ns+0x70/0x70 [ 29.852843] ? lock_acquire+0x170/0x3f0 [ 29.857335] ? rcu_lockdep_current_cpu_online+0xed/0x140 [ 29.863752] process_one_work+0x793/0x14a0 [ 29.868589] ? work_busy+0x320/0x320 [ 29.872876] ? worker_thread+0x158/0xff0 [ 29.877142] ? _raw_spin_unlock_irq+0x24/0x80 [ 29.882170] worker_thread+0x5cc/0xff0 [ 29.886140] ? rescuer_thread+0xc80/0xc80 [ 29.890459] kthread+0x30d/0x420 [ 29.894098] ? kthread_create_on_node+0xd0/0xd0 [ 29.898973] ret_from_fork+0x24/0x30 executing program [ 30.525134] IPVS: ftp: loaded support on port[0] = 21 [ 30.558080] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 31.196631] IPVS: ftp: loaded support on port[0] = 21 [ 31.231832] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 31.855064] IPVS: ftp: loaded support on port[0] = 21 [ 31.893889] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 32.514847] IPVS: ftp: loaded support on port[0] = 21 [ 32.547770] ip6_tables: ip6tables: counters copy to user failed while replacing table [ 32.559775] IPVS: ftp: loaded support on port[0] = 21 executing program [ 32.595937] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 33.205166] IPVS: ftp: loaded support on port[0] = 21 [ 33.239445] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 33.251598] IPVS: ftp: loaded support on port[0] = 21 [ 33.287553] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 34.381662] IPVS: ftp: loaded support on port[0] = 21 [ 34.415836] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 35.470296] IPVS: ftp: loaded support on port[0] = 21 [ 35.504918] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 36.154138] IPVS: ftp: loaded support on port[0] = 21 [ 36.186417] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 36.812690] IPVS: ftp: loaded support on port[0] = 21 [ 36.844702] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 37.463660] IPVS: ftp: loaded support on port[0] = 21 [ 37.495611] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 38.162849] IPVS: ftp: loaded support on port[0] = 21 [ 38.195888] ip6_tables: ip6tables: counters copy to user failed while replacing table executing program [ 38.852451] IPVS: ftp: loaded support on port[0] = 21 [ 38.887299] ip6_tables: ip6tables: counters copy to user failed while replacing table