netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. ====================================================== WARNING: possible circular locking dependency detected 4.14.206-syzkaller #0 Not tainted ------------------------------------------------------ //selinux/14214 is trying to acquire lock: ("dio/%s"sb->s_id){+.+.}, at: [] flush_workqueue+0xcb/0x1310 kernel/workqueue.c:2621 but task is already holding lock: (&sb->s_type->i_mutex_key#10){+.+.}, at: [] inode_trylock include/linux/fs.h:739 [inline] (&sb->s_type->i_mutex_key#10){+.+.}, at: [] ext4_file_write_iter+0x1cc/0xd20 fs/ext4/file.c:236 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #2 (&sb->s_type->i_mutex_key#10){+.+.}: down_write+0x34/0x90 kernel/locking/rwsem.c:54 inode_lock include/linux/fs.h:719 [inline] __generic_file_fsync+0x9e/0x190 fs/libfs.c:987 ext4_sync_file+0x8ed/0x12c0 fs/ext4/fsync.c:118 vfs_fsync_range+0x103/0x260 fs/sync.c:196 generic_write_sync include/linux/fs.h:2682 [inline] dio_complete+0x561/0x8d0 fs/direct-io.c:330 process_one_work+0x793/0x14a0 kernel/workqueue.c:2116 worker_thread+0x5cc/0xff0 kernel/workqueue.c:2250 kthread+0x30d/0x420 kernel/kthread.c:232 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:404 -> #1 ((&dio->complete_work)){+.+.}: process_one_work+0x736/0x14a0 kernel/workqueue.c:2092 worker_thread+0x5cc/0xff0 kernel/workqueue.c:2250 kthread+0x30d/0x420 kernel/kthread.c:232 ret_from_fork+0x24/0x30 arch/x86/entry/entry_64.S:404 -> #0 ("dio/%s"sb->s_id){+.+.}: lock_acquire+0x170/0x3f0 kernel/locking/lockdep.c:3998 flush_workqueue+0xfa/0x1310 kernel/workqueue.c:2624 drain_workqueue+0x177/0x3e0 kernel/workqueue.c:2789 destroy_workqueue+0x71/0x710 kernel/workqueue.c:4102 sb_init_dio_done_wq+0x61/0x80 fs/direct-io.c:635 do_blockdev_direct_IO fs/direct-io.c:1286 [inline] __blockdev_direct_IO+0x3dea/0xdc60 fs/direct-io.c:1422 ext4_direct_IO_write fs/ext4/inode.c:3716 [inline] ext4_direct_IO+0x888/0x1b80 fs/ext4/inode.c:3857 generic_file_direct_write+0x1df/0x420 mm/filemap.c:2958 __generic_file_write_iter+0x2a2/0x590 mm/filemap.c:3137 ext4_file_write_iter+0x7c5/0xd20 fs/ext4/file.c:270 call_write_iter include/linux/fs.h:1778 [inline] aio_write+0x2ed/0x560 fs/aio.c:1553 io_submit_one fs/aio.c:1641 [inline] do_io_submit+0x847/0x1570 fs/aio.c:1709 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x46/0xbb other info that might help us debug this: Chain exists of: "dio/%s"sb->s_id --> (&dio->complete_work) --> &sb->s_type->i_mutex_key#10 Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&sb->s_type->i_mutex_key#10); lock((&dio->complete_work)); lock(&sb->s_type->i_mutex_key#10); lock("dio/%s"sb->s_id); *** DEADLOCK *** 2 locks held by //selinux/14214: #0: (sb_writers#3){.+.+}, at: [] file_start_write include/linux/fs.h:2712 [inline] #0: (sb_writers#3){.+.+}, at: [] aio_write+0x408/0x560 fs/aio.c:1552 #1: (&sb->s_type->i_mutex_key#10){+.+.}, at: [] inode_trylock include/linux/fs.h:739 [inline] #1: (&sb->s_type->i_mutex_key#10){+.+.}, at: [] ext4_file_write_iter+0x1cc/0xd20 fs/ext4/file.c:236 stack backtrace: CPU: 1 PID: 14214 Comm: //selinux Not tainted 4.14.206-syzkaller #0 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+0x1b2/0x283 lib/dump_stack.c:58 print_circular_bug.constprop.0.cold+0x2d7/0x41e kernel/locking/lockdep.c:1258 check_prev_add kernel/locking/lockdep.c:1905 [inline] check_prevs_add kernel/locking/lockdep.c:2022 [inline] validate_chain kernel/locking/lockdep.c:2464 [inline] __lock_acquire+0x2e0e/0x3f20 kernel/locking/lockdep.c:3491 lock_acquire+0x170/0x3f0 kernel/locking/lockdep.c:3998 flush_workqueue+0xfa/0x1310 kernel/workqueue.c:2624 drain_workqueue+0x177/0x3e0 kernel/workqueue.c:2789 destroy_workqueue+0x71/0x710 kernel/workqueue.c:4102 sb_init_dio_done_wq+0x61/0x80 fs/direct-io.c:635 do_blockdev_direct_IO fs/direct-io.c:1286 [inline] __blockdev_direct_IO+0x3dea/0xdc60 fs/direct-io.c:1422 ext4_direct_IO_write fs/ext4/inode.c:3716 [inline] ext4_direct_IO+0x888/0x1b80 fs/ext4/inode.c:3857 generic_file_direct_write+0x1df/0x420 mm/filemap.c:2958 __generic_file_write_iter+0x2a2/0x590 mm/filemap.c:3137 ext4_file_write_iter+0x7c5/0xd20 fs/ext4/file.c:270 call_write_iter include/linux/fs.h:1778 [inline] aio_write+0x2ed/0x560 fs/aio.c:1553 io_submit_one fs/aio.c:1641 [inline] do_io_submit+0x847/0x1570 fs/aio.c:1709 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x46/0xbb RIP: 0033:0x45deb9 RSP: 002b:00007f84e398bc78 EFLAGS: 00000246 ORIG_RAX: 00000000000000d1 RAX: ffffffffffffffda RBX: 0000000000008300 RCX: 000000000045deb9 RDX: 00000000200003c0 RSI: 00000000000041e3 RDI: 00007f84e3969000 RBP: 000000000118bf60 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 000000000118bf2c R13: 00007ffe94b8d05f R14: 00007f84e398c9c0 R15: 000000000118bf2c netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. L1TF CPU bug present and SMT on, data leak possible. See CVE-2018-3646 and https://www.kernel.org/doc/html/latest/admin-guide/hw-vuln/l1tf.html for details. syz-executor.4 uses obsolete (PF_INET,SOCK_PACKET) kvm [14761]: vcpu0, guest rIP: 0x13c Hyper-V uhandled wrmsr: 0x40000007 data 0x65 kvm [14761]: vcpu0, guest rIP: 0x14c Hyper-V uhandled wrmsr: 0x40000007 data 0xb6 kvm [14761]: vcpu0, guest rIP: 0x14c Hyper-V uhandled wrmsr: 0x40000007 data 0x67 kvm [14761]: vcpu0, guest rIP: 0x14c Hyper-V uhandled wrmsr: 0x40000007 data 0xde kvm [14761]: vcpu0, guest rIP: 0x14c Hyper-V uhandled wrmsr: 0x40000007 data 0xfc kvm [14761]: vcpu0, guest rIP: 0x14c Hyper-V uhandled wrmsr: 0x40000007 data 0xbe kvm [14761]: vcpu0, guest rIP: 0x14c Hyper-V uhandled wrmsr: 0x40000007 data 0x9f kvm [14761]: vcpu0, guest rIP: 0x14c Hyper-V uhandled wrmsr: 0x40000007 data 0xb8 kvm [14761]: vcpu0, guest rIP: 0x14c Hyper-V uhandled wrmsr: 0x40000007 data 0xfe kvm [14761]: vcpu0, guest rIP: 0x14c Hyper-V uhandled wrmsr: 0x40000007 data 0xd2 nla_parse: 9 callbacks suppressed netlink: 316 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 316 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 316 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.2'. netlink: 8 bytes leftover after parsing attributes in process `syz-executor.1'. net_ratelimit: 14 callbacks suppressed ip_tables: iptables: counters copy to user failed while replacing table ip_tables: iptables: counters copy to user failed while replacing table ip_tables: iptables: counters copy to user failed while replacing table ip_tables: iptables: counters copy to user failed while replacing table FAULT_INJECTION: forcing a failure. name fail_page_alloc, interval 1, probability 0, space 0, times 1 CPU: 0 PID: 15497 Comm: syz-executor.5 Not tainted 4.14.206-syzkaller #0 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+0x1b2/0x283 lib/dump_stack.c:58 fail_dump lib/fault-inject.c:51 [inline] should_fail.cold+0x10a/0x154 lib/fault-inject.c:149 should_fail_alloc_page mm/page_alloc.c:2898 [inline] prepare_alloc_pages mm/page_alloc.c:4131 [inline] __alloc_pages_nodemask+0x22c/0x2720 mm/page_alloc.c:4179 alloc_pages_current+0x155/0x260 mm/mempolicy.c:2113 alloc_pages include/linux/gfp.h:520 [inline] skb_page_frag_refill+0x1bf/0x490 net/core/sock.c:2206 tun_build_skb drivers/net/tun.c:1296 [inline] tun_get_user+0x1ba1/0x4260 drivers/net/tun.c:1468 tun_chr_write_iter+0xcf/0x180 drivers/net/tun.c:1608 call_write_iter include/linux/fs.h:1778 [inline] new_sync_write fs/read_write.c:469 [inline] __vfs_write+0x44c/0x630 fs/read_write.c:482 vfs_write+0x17f/0x4d0 fs/read_write.c:544 SYSC_write fs/read_write.c:590 [inline] SyS_write+0xf2/0x210 fs/read_write.c:582 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x46/0xbb RIP: 0033:0x417751 RSP: 002b:00007f92bca00c60 EFLAGS: 00000293 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 000000000118bf20 RCX: 0000000000417751 RDX: 000000000000002a RSI: 0000000020000000 RDI: 00000000000000f0 RBP: 00007f92bca00ca0 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000064 R11: 0000000000000293 R12: 0000000000000000 R13: 00007ffc774a2a0f R14: 00007f92bca019c0 R15: 000000000118bf2c ip_tables: iptables: counters copy to user failed while replacing table FAULT_INJECTION: forcing a failure. name failslab, interval 1, probability 0, space 0, times 1 FAULT_INJECTION: forcing a failure. name failslab, interval 1, probability 0, space 0, times 1 CPU: 0 PID: 15522 Comm: syz-executor.4 Not tainted 4.14.206-syzkaller #0 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+0x1b2/0x283 lib/dump_stack.c:58 fail_dump lib/fault-inject.c:51 [inline] should_fail.cold+0x10a/0x154 lib/fault-inject.c:149 should_failslab+0xd6/0x130 mm/failslab.c:32 slab_pre_alloc_hook mm/slab.h:421 [inline] slab_alloc mm/slab.c:3376 [inline] kmem_cache_alloc_trace+0x29a/0x3d0 mm/slab.c:3616 kmalloc include/linux/slab.h:488 [inline] kzalloc include/linux/slab.h:661 [inline] assoc_array_insert+0xb9/0x2820 lib/assoc_array.c:998 __key_link_begin+0x106/0x2b0 security/keys/keyring.c:1234 key_link+0x6f/0x230 security/keys/keyring.c:1367 keyctl_keyring_link+0x65/0xb0 security/keys/keyctl.c:520 SYSC_keyctl security/keys/keyctl.c:1729 [inline] SyS_keyctl+0x251/0x390 security/keys/keyctl.c:1701 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x46/0xbb RIP: 0033:0x45deb9 RSP: 002b:00007f9a7f928c78 EFLAGS: 00000246 ORIG_RAX: 00000000000000fa RAX: ffffffffffffffda RBX: 0000000000020540 RCX: 000000000045deb9 RDX: fffffffffffffffd RSI: 000000000f16ff25 RDI: 0000000000000008 RBP: 00007f9a7f928ca0 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007ffc0cf0105f R14: 00007f9a7f9299c0 R15: 000000000118bf2c CPU: 1 PID: 15515 Comm: syz-executor.5 Not tainted 4.14.206-syzkaller #0 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+0x1b2/0x283 lib/dump_stack.c:58 fail_dump lib/fault-inject.c:51 [inline] should_fail.cold+0x10a/0x154 lib/fault-inject.c:149 should_failslab+0xd6/0x130 mm/failslab.c:32 slab_pre_alloc_hook mm/slab.h:421 [inline] slab_alloc mm/slab.c:3376 [inline] kmem_cache_alloc+0x40/0x3c0 mm/slab.c:3550 __build_skb+0x2e/0x2d0 net/core/skbuff.c:281 build_skb+0x1a/0x160 net/core/skbuff.c:312 tun_build_skb drivers/net/tun.c:1357 [inline] tun_get_user+0x2199/0x4260 drivers/net/tun.c:1468 ip_tables: iptables: counters copy to user failed while replacing table tun_chr_write_iter+0xcf/0x180 drivers/net/tun.c:1608 call_write_iter include/linux/fs.h:1778 [inline] new_sync_write fs/read_write.c:469 [inline] __vfs_write+0x44c/0x630 fs/read_write.c:482 vfs_write+0x17f/0x4d0 fs/read_write.c:544 SYSC_write fs/read_write.c:590 [inline] SyS_write+0xf2/0x210 fs/read_write.c:582 do_syscall_64+0x1d5/0x640 arch/x86/entry/common.c:292 entry_SYSCALL_64_after_hwframe+0x46/0xbb RIP: 0033:0x417751 RSP: 002b:00007f92bca00c60 EFLAGS: 00000293 ORIG_RAX: 0000000000000001 RAX: ffffffffffffffda RBX: 000000000118bf20 RCX: 0000000000417751 RDX: 000000000000002a RSI: 0000000020000000 RDI: 00000000000000f0 RBP: 00007f92bca00ca0 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000064 R11: 0000000000000293 R12: 0000000000000001 R13: 00007ffc774a2a0f R14: 00007f92bca019c0 R15: 000000000118bf2c ip_tables: iptables: counters copy to user failed while replacing table ip_tables: iptables: counters copy to user failed while replacing table ip_tables: iptables: counters copy to user failed while replacing table ip_tables: iptables: counters copy to user failed while replacing table Unknown ioctl -2145894094 Unknown ioctl -2145894094 device batadv_slave_0 entered promiscuous mode device batadv_slave_0 left promiscuous mode device batadv_slave_0 entered promiscuous mode device batadv_slave_0 left promiscuous mode