[ 67.891377][ T43] audit: type=1400 audit(1794794879.886:210): avc: denied { write } for pid=6086 comm="dhcpcd-run-hook" name="hook-state" dev="tmpfs" ino=1858 scontext=system_u:system_r:dhcpc_t tcontext=system_u:object_r:tmpfs_t tclass=dir permissive=1 [ 67.933344][ T43] audit: type=1400 audit(1794794879.926:211): avc: denied { write } for pid=6089 comm="rm" name="hook-state" dev="tmpfs" ino=1858 scontext=system_u:system_r:dhcpc_t tcontext=system_u:object_r:tmpfs_t tclass=dir permissive=1 Warning: Permanently added '[localhost]:9694' (ED25519) to the list of known hosts. [ 68.642527][ T43] audit: type=1400 audit(1794794880.636:212): avc: denied { write } for pid=6098 comm="dhcpcd-run-hook" name="hook-state" dev="tmpfs" ino=1858 scontext=system_u:system_r:dhcpc_t tcontext=system_u:object_r:tmpfs_t tclass=dir permissive=1 [*] Starting reproducer for circular locking dependency in __cachefiles_write... [*] Step 1: Setting up IMA measurement policy... [+] securityfs already mounted. [+] Wrote 'measure func=FILE_CHECK' into IMA policy. [*] Step 2: Setting up CacheFiles backing cache... [+] Backing cache directory ./cachefiles_dir ready. [ 68.703691][ T6102] ima: policy update completed [+] /dev/cachefiles opened successfully. [+] 'dir' command sent to /dev/cachefiles. [ 68.703697][ T43] audit: type=1807 audit(1794794880.696:213): action=measure func=FILE_CHECK res=1 [+] CacheFiles cache bound successfully. [*] Step 3: Starting 9P protocol server over socketpair... [+] socketpair created successfully. [+] 9P server thread spawned successfully. [*] Step 4: Mounting 9P filesystem with cache=fscache,ignoreqv... [ 68.703801][ T43] audit: type=1802 audit(1794794880.696:214): pid=6102 uid=0 auid=4294967295 ses=4294967295 subj=root:sysadm_r:sysadm_t op=policy_update cause=completed comm="syz-executor273" res=1 errno=0 [ 68.705651][ T43] audit: type=1400 audit(1794794880.696:215): avc: denied { write } for pid=6103 comm="rm" name="hook-state" dev="tmpfs" ino=1858 scontext=system_u:system_r:dhcpc_t tcontext=system_u:object_r:tmpfs_t tclass=dir permissive=1 [ 68.706615][ T43] audit: type=1400 audit(1794794880.696:216): avc: denied { read write } for pid=6102 comm="syz-executor273" name="cachefiles" dev="devtmpfs" ino=82 scontext=root:sysadm_r:sysadm_t tcontext=system_u:object_r:cachefiles_device_t tclass=chr_file permissive=1 [ 68.706658][ T43] audit: type=1400 audit(1794794880.696:217): avc: denied { open } for pid=6102 comm="syz-executor273" path="/dev/cachefiles" dev="devtmpfs" ino=82 scontext=root:sysadm_r:sysadm_t tcontext=system_u:object_r:cachefiles_device_t tclass=chr_file permissive=1 [+] 9P filesystem mounted at ./mnt_9p. [*] Step 5: Establishing lockdep Edge 1 (sb_writers -> ima_iint_mutex)... [ 68.709089][ T43] audit: type=1400 audit(1794794880.706:218): avc: denied { create_files_as } for pid=6102 comm="syz-executor273" scontext=root:sysadm_r:sysadm_t tcontext=root:object_r:root_t tclass=kernel_service permissive=1 [ 68.712321][ T6102] netfs: Cache "CacheFiles" added (type cachefiles) [ 68.712344][ T6102] CacheFiles: File cache on CacheFiles registered [+] Edge 1 established (sb_writers -> ima_iint_mutex). [*] Step 6: Establishing lockdep Edge 2 (ima_iint_mutex -> 9p_inode->i_rwsem)... [ 68.749225][ T43] audit: type=1400 audit(1794794880.746:219): avc: denied { mount } for pid=6102 comm="syz-executor273" name="/" dev="9p" ino=3 scontext=root:sysadm_r:sysadm_t tcontext=system_u:object_r:unlabeled_t tclass=filesystem permissive=1 [ 68.751628][ T43] audit: type=1800 audit(1794794880.746:220): pid=6106 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:initrc_t op=collect_data cause=failed comm="udevd" name="uevent" dev="sysfs" ino=143149 res=0 errno=-22 [+] Edge 2 established (ima_iint_mutex -> 9p_inode->i_rwsem). [*] Step 7: Triggering circular locking dependency (9p_inode->i_rwsem -> sb_writers)... [ 69.050857][ T6102] [ 69.051919][ T6102] ====================================================== [ 69.054825][ T6102] WARNING: possible circular locking dependency detected [ 69.057641][ T6102] syzkaller #0 Not tainted [ 69.059511][ T6102] ------------------------------------------------------ [ 69.062398][ T6102] syz-executor273/6102 is trying to acquire lock: [ 69.065031][ T6102] ffff88802c81e478 (sb_writers#5){.+.+}-{0:0}, at: __cachefiles_write+0x56f/0xd40 [ 69.068865][ T6102] [ 69.068865][ T6102] but task is already holding lock: [ 69.071927][ T6102] ffff888052ca8d00 (&sb->s_type->i_mutex_key#25){++++}-{4:4}, at: do_truncate+0x14e/0x240 [ 69.075991][ T6102] [ 69.075991][ T6102] which lock already depends on the new lock. [ 69.075991][ T6102] [ 69.080193][ T6102] [ 69.080193][ T6102] the existing dependency chain (in reverse order) is: [ 69.083843][ T6102] [ 69.083843][ T6102] -> #2 (&sb->s_type->i_mutex_key#25){++++}-{4:4}: [ 69.087400][ T6102] lock_acquire+0x1d1/0x380 [ 69.089388][ T6102] down_read_interruptible+0x97/0x520 [ 69.091831][ T6102] netfs_start_io_read+0x1f/0x100 [ 69.094123][ T6102] netfs_buffered_read_iter+0xf3/0x190 [ 69.096630][ T6102] netfs_file_read_iter+0x10f/0x190 [ 69.099008][ T6102] v9fs_file_read_iter+0x9b/0x100 [ 69.101329][ T6102] __kernel_read+0x397/0xac0 [ 69.103470][ T6102] integrity_kernel_read+0x7e/0xb0 [ 69.105836][ T6102] ima_calc_file_hash_tfm+0x25e/0x350 [ 69.108360][ T6102] ima_calc_file_hash+0x1e3/0x380 [ 69.110760][ T6102] ima_collect_measurement+0x952/0xb30 [ 69.113269][ T6102] process_measurement+0xe04/0x2360 [ 69.115630][ T6102] ima_file_check+0xbf/0x110 [ 69.117793][ T6102] security_file_post_open+0xc4/0x210 [ 69.120234][ T6102] path_openat+0x5d0/0x23f0 [ 69.122344][ T6102] do_file_open+0x20e/0x430 [ 69.124436][ T6102] do_sys_openat2+0x163/0x1d0 [ 69.126376][ T6102] __x64_sys_openat+0x12d/0x210 [ 69.128075][ T6102] do_syscall_64+0x123/0x7b0 [ 69.129697][ T6102] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 69.131690][ T6102] [ 69.131690][ T6102] -> #1 (&ima_iint_mutex_key[depth]){+.+.}-{4:4}: [ 69.134570][ T6102] lock_acquire+0x1d1/0x380 [ 69.136163][ T6102] __mutex_lock+0x19f/0x1c10 [ 69.137773][ T6102] process_measurement+0x5ab/0x2360 [ 69.139532][ T6102] ima_file_check+0xbf/0x110 [ 69.141133][ T6102] security_file_post_open+0xc4/0x210 [ 69.142963][ T6102] path_openat+0x5d0/0x23f0 [ 69.144576][ T6102] do_file_open+0x20e/0x430 [ 69.146160][ T6102] do_sys_openat2+0x163/0x1d0 [ 69.147781][ T6102] __x64_sys_openat+0x12d/0x210 [ 69.149449][ T6102] do_syscall_64+0x123/0x7b0 [ 69.151056][ T6102] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 69.153032][ T6102] [ 69.153032][ T6102] -> #0 (sb_writers#5){.+.+}-{0:0}: [ 69.155339][ T6102] check_prev_add+0xeb/0xe60 [ 69.156947][ T6102] __lock_acquire+0x1528/0x1f40 [ 69.158618][ T6102] lock_acquire+0x1d1/0x380 [ 69.160184][ T6102] vfs_iocb_iter_write+0x1fe/0xa50 [ 69.161920][ T6102] __cachefiles_write+0x56f/0xd40 [ 69.163654][ T6102] cachefiles_write+0xc2/0x150 [ 69.165438][ T6102] cachefiles_issue_write+0x513/0x810 [ 69.167265][ T6102] netfs_do_issue_write+0xee/0x340 [ 69.169007][ T6102] netfs_advance_write+0x37e/0x4c0 [ 69.170757][ T6102] netfs_writepages+0x10bb/0x2390 [ 69.172480][ T6102] do_writepages+0x278/0x600 [ 69.174159][ T6102] filemap_writeback+0x22d/0x2e0 [ 69.175904][ T6102] v9fs_vfs_setattr_dotl+0x8fe/0xcf0 [ 69.177777][ T6102] notify_change+0xb09/0x1350 [ 69.179387][ T6102] do_truncate+0x1df/0x240 [ 69.180910][ T6102] path_openat+0x1e93/0x23f0 [ 69.182495][ T6102] do_file_open+0x20e/0x430 [ 69.184125][ T6102] do_sys_openat2+0x163/0x1d0 [ 69.185773][ T6102] __x64_sys_openat+0x12d/0x210 [ 69.187431][ T6102] do_syscall_64+0x123/0x7b0 [ 69.189032][ T6102] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 69.191031][ T6102] [ 69.191031][ T6102] other info that might help us debug this: [ 69.191031][ T6102] [ 69.194220][ T6102] Chain exists of: [ 69.194220][ T6102] sb_writers#5 --> &ima_iint_mutex_key[depth] --> &sb->s_type->i_mutex_key#25 [ 69.194220][ T6102] [ 69.198715][ T6102] Possible unsafe locking scenario: [ 69.198715][ T6102] [ 69.200988][ T6102] CPU0 CPU1 [ 69.202639][ T6102] ---- ---- [ 69.204352][ T6102] lock(&sb->s_type->i_mutex_key#25); [ 69.206168][ T6102] lock(&ima_iint_mutex_key[depth]); [ 69.208582][ T6102] lock(&sb->s_type->i_mutex_key#25); [ 69.211057][ T6102] rlock(sb_writers#5); [ 69.212384][ T6102] [ 69.212384][ T6102] *** DEADLOCK *** [ 69.212384][ T6102] [ 69.214926][ T6102] locks held by syz-executor273/6102: 2, on CPU#3: [ 69.216930][ T6102] #0: ffff88802ea90478 (sb_writers#14){.+.+}-{0:0}, at: path_openat+0x1920/0x23f0 [ 69.219836][ T6102] #1: ffff888052ca8d00 (&sb->s_type->i_mutex_key#25){++++}-{4:4}, at: do_truncate+0x14e/0x240 [ 69.223000][ T6102] [ 69.223000][ T6102] stack backtrace: [ 69.224878][ T6102] CPU: 3 UID: 0 PID: 6102 Comm: syz-executor273 Not tainted syzkaller #0 PREEMPT(full) [ 69.227839][ T6102] Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2 04/01/2014 [ 69.230918][ T6102] Call Trace: [ 69.231986][ T6102] [ 69.232925][ T6102] dump_stack_lvl+0x100/0x190 [ 69.234639][ T6102] print_circular_bug.cold+0x178/0x1be [ 69.236340][ T6102] check_noncircular+0x146/0x160 [ 69.237920][ T6102] ? do_writepages+0x278/0x600 [ 69.239419][ T6102] check_prev_add+0xeb/0xe60 [ 69.240872][ T6102] __lock_acquire+0x1528/0x1f40 [ 69.242406][ T6102] lock_acquire+0x1d1/0x380 [ 69.243896][ T6102] ? __cachefiles_write+0x56f/0xd40 [ 69.245517][ T6102] ? __pfx___might_resched+0x10/0x10 [ 69.247163][ T6102] vfs_iocb_iter_write+0x1fe/0xa50 [ 69.248757][ T6102] ? __cachefiles_write+0x56f/0xd40 [ 69.250382][ T6102] ? cachefiles_grab_object+0x102/0x170 [ 69.252100][ T6102] __cachefiles_write+0x56f/0xd40 [ 69.253753][ T6102] ? __pfx_netfs_write_subrequest_terminated+0x10/0x10 [ 69.256073][ T6102] ? __pfx_netfs_write_subrequest_terminated+0x10/0x10 [ 69.258199][ T6102] cachefiles_write+0xc2/0x150 [ 69.259701][ T6102] cachefiles_issue_write+0x513/0x810 [ 69.261365][ T6102] ? __pfx_cachefiles_issue_write+0x10/0x10 [ 69.263194][ T6102] ? rcu_is_watching+0x13/0xc0 [ 69.264733][ T6102] netfs_do_issue_write+0xee/0x340 [ 69.266342][ T6102] netfs_advance_write+0x37e/0x4c0 [ 69.267939][ T6102] netfs_writepages+0x10bb/0x2390 [ 69.269507][ T6102] ? __pfx_netfs_writepages+0x10/0x10 [ 69.271163][ T6102] ? v9fs_fid_xattr_get+0x10f/0x300 [ 69.272778][ T6102] ? v9fs_xattr_handler_get+0x6b/0x120 [ 69.274515][ T6102] ? lock_acquire+0x1d1/0x380 [ 69.275990][ T6102] ? __pfx_netfs_writepages+0x10/0x10 [ 69.277674][ T6102] do_writepages+0x278/0x600 [ 69.279117][ T6102] ? __pfx_do_writepages+0x10/0x10 [ 69.280710][ T6102] ? do_raw_spin_unlock+0x145/0x1e0 [ 69.282332][ T6102] ? _raw_spin_unlock+0x28/0x50 [ 69.283919][ T6102] filemap_writeback+0x22d/0x2e0 [ 69.285568][ T6102] ? __pfx_filemap_writeback+0x10/0x10 [ 69.287250][ T6102] ? check_noncircular+0x97/0x160 [ 69.288818][ T6102] ? setattr_prepare+0x1d4/0xa30 [ 69.290374][ T6102] v9fs_vfs_setattr_dotl+0x8fe/0xcf0 [ 69.292023][ T6102] ? __pfx_v9fs_vfs_setattr_dotl+0x10/0x10 [ 69.293886][ T6102] ? evm_inode_setattr+0x41/0x6e0 [ 69.295454][ T6102] ? __pfx_make_vfsgid+0x10/0x10 [ 69.297014][ T6102] ? __pfx_v9fs_vfs_setattr_dotl+0x10/0x10 [ 69.298835][ T6102] notify_change+0xb09/0x1350 [ 69.300300][ T6102] do_truncate+0x1df/0x240 [ 69.301706][ T6102] ? __pfx_do_truncate+0x10/0x10 [ 69.303245][ T6102] ? __pfx___mutex_unlock_slowpath+0x10/0x10 [ 69.305139][ T6102] path_openat+0x1e93/0x23f0 [ 69.306585][ T6102] ? __pfx_path_openat+0x10/0x10 [ 69.308135][ T6102] do_file_open+0x20e/0x430 [ 69.309567][ T6102] ? __pfx_do_file_open+0x10/0x10 [ 69.311131][ T6102] ? _raw_spin_unlock+0x28/0x50 [ 69.312650][ T6102] ? alloc_fd+0x471/0x7a0 [ 69.314008][ T6102] do_sys_openat2+0x163/0x1d0 [ 69.315478][ T6102] ? __pfx_do_sys_openat2+0x10/0x10 [ 69.317112][ T6102] ? __pfx_get_timespec64+0x10/0x10 [ 69.318732][ T6102] __x64_sys_openat+0x12d/0x210 [ 69.320251][ T6102] ? __pfx___x64_sys_openat+0x10/0x10 [ 69.321926][ T6102] do_syscall_64+0x123/0x7b0 [ 69.323374][ T6102] entry_SYSCALL_64_after_hwframe+0x77/0x7f [ 69.325221][ T6102] RIP: 0033:0x7feefe53f45e [ 69.326622][ T6102] Code: 08 0f 85 f5 e2 ff ff 49 89 fb 48 89 f0 48 89 d7 48 89 ce 4c 89 c2 4d 89 ca 4c 8b 44 24 08 4c 8b 4c 24 10 4c 89 5c 24 08 0f 05 90 41 57 41 56 4d 89 c6 41 55 4d 89 cd 41 54 55 53 48 83 ec 08 [ 69.332483][ T6102] RSP: 002b:00007fff976f93e8 EFLAGS: 00000246 ORIG_RAX: 0000000000000101 [ 69.335063][ T6102] RAX: ffffffffffffffda RBX: 0000555558a8a400 RCX: 00007feefe53f45e [ 69.337506][ T6102] RDX: 0000000000000202 RSI: 00007feefe58e995 RDI: ffffffffffffff9c [ 69.339946][ T6102] RBP: 00007feefe58e995 R08: 0000000000000000 R09: 0000000000000000 [ 69.342394][ T6102] R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000005 [ 69.345206][ T6102] R13: 00007fff976fa3f0 R14: 00007feefe58e979 R15: 0000000000000003 [ 69.347670][ T6102] [+] Reproduction sequence completed. Waiting for lockdep output... [ 71.428338][ T1449] ieee802154 phy0 wpan0: encryption failed: -22 [ 71.428414][ T1449] ieee802154 phy1 wpan1: encryption failed: -22 [ 71.575052][ T6102] CacheFiles: File cache on CacheFiles unregistering [ 71.575069][ T6102] netfs: Withdrawing cache "CacheFiles" (1 objs) [+] Done. [ 76.547328][ T25] cfg80211: failed to load regulatory.db [ 76.553186][ T43] kauditd_printk_skb: 15 callbacks suppressed [ 76.553198][ T43] audit: type=1800 audit(1794794888.546:236): pid=5196 uid=0 auid=4294967295 ses=4294967295 subj=system_u:system_r:initrc_t op=collect_data cause=failed comm="udevd" name="uevent" dev="sysfs" ino=4993 res=0 errno=-22