====================================================== WARNING: possible circular locking dependency detected syzkaller #0 Not tainted ------------------------------------------------------ syz.7.9358/6111 is trying to acquire lock: ffffffff8ddb5b90 (cb_lock){++++}-{3:3}, at: genl_rcv+0x15/0x40 net/netlink/genetlink.c:860 but task is already holding lock: ffff8880880b1068 (&pipe->mutex/1){+.+.}-{3:3}, at: splice_from_pipe fs/splice.c:592 [inline] ffff8880880b1068 (&pipe->mutex/1){+.+.}-{3:3}, at: generic_splice_sendpage+0xff/0x180 fs/splice.c:742 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #6 (&pipe->mutex/1){+.+.}-{3:3}: __mutex_lock_common kernel/locking/mutex.c:603 [inline] __mutex_lock+0x12d/0xae0 kernel/locking/mutex.c:747 iter_file_splice_write+0x1b6/0xcf0 fs/splice.c:631 do_splice_from fs/splice.c:763 [inline] do_splice+0xe46/0x1620 fs/splice.c:1102 __do_splice fs/splice.c:1167 [inline] __do_sys_splice fs/splice.c:1374 [inline] __se_sys_splice+0x34d/0x440 fs/splice.c:1356 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 -> #5 (sb_writers#5){.+.+}-{0:0}: percpu_down_read include/linux/percpu-rwsem.h:51 [inline] __sb_start_write include/linux/fs.h:1897 [inline] sb_start_write+0x4d/0x1c0 include/linux/fs.h:1972 mnt_want_write+0x3d/0x90 fs/namespace.c:402 open_last_lookups fs/namei.c:3590 [inline] path_openat+0x75c/0x2f10 fs/namei.c:3831 do_filp_open+0x1ee/0x420 fs/namei.c:3861 file_open_name fs/open.c:1265 [inline] filp_open+0x17c/0x1e0 fs/open.c:1285 fsg_lun_open+0x63/0xf00 drivers/usb/gadget/function/storage_common.c:193 fsg_store_file+0x1a5/0x530 drivers/usb/gadget/function/storage_common.c:454 flush_write_buffer fs/configfs/file.c:207 [inline] configfs_write_iter+0x30b/0x400 fs/configfs/file.c:229 call_write_iter include/linux/fs.h:2271 [inline] new_sync_write fs/read_write.c:491 [inline] vfs_write+0x482/0x9a0 fs/read_write.c:584 ksys_write+0x14d/0x260 fs/read_write.c:637 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 -> #4 (&common->filesem){++++}-{3:3}: down_read+0x42/0x2d0 kernel/locking/rwsem.c:1520 fsg_show_file+0x29/0x130 drivers/usb/gadget/function/storage_common.c:338 fill_read_buffer fs/configfs/file.c:68 [inline] configfs_read_iter+0x296/0x560 fs/configfs/file.c:88 __kernel_read+0x2dd/0x6e0 fs/read_write.c:428 integrity_kernel_read+0x86/0xd0 security/integrity/iint.c:228 ima_calc_file_hash_tfm security/integrity/ima/ima_crypto.c:485 [inline] ima_calc_file_shash security/integrity/ima/ima_crypto.c:516 [inline] ima_calc_file_hash+0xb12/0x1950 security/integrity/ima/ima_crypto.c:573 ima_collect_measurement+0x503/0xb50 security/integrity/ima/ima_api.c:293 process_measurement+0x119b/0x1c40 security/integrity/ima/ima_main.c:351 ima_file_check+0xc8/0x110 security/integrity/ima/ima_main.c:534 do_open fs/namei.c:3679 [inline] path_openat+0x272b/0x2f10 fs/namei.c:3834 do_filp_open+0x1ee/0x420 fs/namei.c:3861 do_sys_openat2+0x14b/0x4f0 fs/open.c:1320 do_sys_open fs/open.c:1336 [inline] __do_sys_openat fs/open.c:1352 [inline] __se_sys_openat fs/open.c:1347 [inline] __x64_sys_openat+0x135/0x160 fs/open.c:1347 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 -> #3 (&p->frag_sem){++++}-{3:3}: down_read+0x42/0x2d0 kernel/locking/rwsem.c:1520 flush_write_buffer fs/configfs/file.c:205 [inline] configfs_write_iter+0x20e/0x400 fs/configfs/file.c:229 call_write_iter include/linux/fs.h:2271 [inline] new_sync_write fs/read_write.c:491 [inline] vfs_write+0x482/0x9a0 fs/read_write.c:584 ksys_write+0x14d/0x260 fs/read_write.c:637 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 -> #2 (&buffer->mutex){+.+.}-{3:3}: __mutex_lock_common kernel/locking/mutex.c:603 [inline] __mutex_lock+0x12d/0xae0 kernel/locking/mutex.c:747 configfs_read_iter+0x6e/0x560 fs/configfs/file.c:86 __kernel_read+0x2dd/0x6e0 fs/read_write.c:428 integrity_kernel_read+0x86/0xd0 security/integrity/iint.c:228 ima_calc_file_hash_tfm security/integrity/ima/ima_crypto.c:485 [inline] ima_calc_file_shash security/integrity/ima/ima_crypto.c:516 [inline] ima_calc_file_hash+0xb12/0x1950 security/integrity/ima/ima_crypto.c:573 ima_collect_measurement+0x503/0xb50 security/integrity/ima/ima_api.c:293 process_measurement+0x119b/0x1c40 security/integrity/ima/ima_main.c:351 ima_file_check+0xc8/0x110 security/integrity/ima/ima_main.c:534 do_open fs/namei.c:3679 [inline] path_openat+0x272b/0x2f10 fs/namei.c:3834 do_filp_open+0x1ee/0x420 fs/namei.c:3861 do_sys_openat2+0x14b/0x4f0 fs/open.c:1320 do_sys_open fs/open.c:1336 [inline] __do_sys_openat fs/open.c:1352 [inline] __se_sys_openat fs/open.c:1347 [inline] __x64_sys_openat+0x135/0x160 fs/open.c:1347 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 -> #1 (&iint_mutex_key[depth]){+.+.}-{3:3}: __mutex_lock_common kernel/locking/mutex.c:603 [inline] __mutex_lock+0x12d/0xae0 kernel/locking/mutex.c:747 process_measurement+0x717/0x1c40 security/integrity/ima/ima_main.c:261 ima_file_check+0xc8/0x110 security/integrity/ima/ima_main.c:534 do_open fs/namei.c:3679 [inline] path_openat+0x272b/0x2f10 fs/namei.c:3834 do_file_open_root+0x2ef/0x5a0 fs/namei.c:3886 file_open_root+0x163/0x1c0 fs/open.c:1300 kernel_read_file_from_path_initns+0x14d/0x220 fs/kernel_read_file.c:163 fw_get_filesystem_firmware drivers/base/firmware_loader/main.c:539 [inline] _request_firmware+0x895/0x1280 drivers/base/firmware_loader/main.c:859 request_firmware+0x32/0x50 drivers/base/firmware_loader/main.c:933 reg_reload_regdb+0x96/0x490 net/wireless/reg.c:1116 genl_family_rcv_msg_doit+0x22f/0x350 net/netlink/genetlink.c:756 genl_family_rcv_msg net/netlink/genetlink.c:833 [inline] genl_rcv_msg+0x601/0x790 net/netlink/genetlink.c:850 netlink_rcv_skb+0x1ef/0x440 net/netlink/af_netlink.c:2516 genl_rcv+0x24/0x40 net/netlink/genetlink.c:861 netlink_unicast_kernel net/netlink/af_netlink.c:1318 [inline] netlink_unicast+0x7ad/0x920 net/netlink/af_netlink.c:1344 netlink_sendmsg+0x8ad/0xbd0 net/netlink/af_netlink.c:1877 sock_sendmsg_nosec net/socket.c:718 [inline] __sock_sendmsg net/socket.c:730 [inline] ____sys_sendmsg+0x5ed/0x9a0 net/socket.c:2519 ___sys_sendmsg+0x2a2/0x360 net/socket.c:2573 __sys_sendmsg net/socket.c:2602 [inline] __do_sys_sendmsg net/socket.c:2611 [inline] __se_sys_sendmsg+0x1c3/0x2b0 net/socket.c:2609 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 -> #0 (cb_lock){++++}-{3:3}: check_prev_add kernel/locking/lockdep.c:3095 [inline] check_prevs_add kernel/locking/lockdep.c:3214 [inline] validate_chain kernel/locking/lockdep.c:3830 [inline] __lock_acquire+0x2d18/0x7c40 kernel/locking/lockdep.c:5063 lock_acquire+0x1bb/0x4a0 kernel/locking/lockdep.c:5678 down_read+0x42/0x2d0 kernel/locking/rwsem.c:1520 genl_rcv+0x15/0x40 net/netlink/genetlink.c:860 netlink_unicast_kernel net/netlink/af_netlink.c:1318 [inline] netlink_unicast+0x7ad/0x920 net/netlink/af_netlink.c:1344 netlink_sendmsg+0x8ad/0xbd0 net/netlink/af_netlink.c:1877 sock_sendmsg_nosec net/socket.c:718 [inline] __sock_sendmsg net/socket.c:730 [inline] sock_sendmsg net/socket.c:753 [inline] kernel_sendmsg+0x246/0x370 net/socket.c:777 sock_no_sendpage+0x137/0x1c0 net/core/sock.c:3268 kernel_sendpage+0x27d/0x570 net/socket.c:3606 sock_sendpage+0x7a/0xb0 net/socket.c:1082 pipe_to_sendpage+0x22f/0x320 fs/splice.c:360 splice_from_pipe_feed fs/splice.c:414 [inline] __splice_from_pipe+0x333/0x8e0 fs/splice.c:558 splice_from_pipe fs/splice.c:593 [inline] generic_splice_sendpage+0x111/0x180 fs/splice.c:742 do_splice_from fs/splice.c:763 [inline] do_splice+0xe46/0x1620 fs/splice.c:1102 __do_splice fs/splice.c:1167 [inline] __do_sys_splice fs/splice.c:1374 [inline] __se_sys_splice+0x34d/0x440 fs/splice.c:1356 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 other info that might help us debug this: Chain exists of: cb_lock --> sb_writers#5 --> &pipe->mutex/1 Possible unsafe locking scenario: CPU0 CPU1 ---- ---- lock(&pipe->mutex/1); lock(sb_writers#5); lock(&pipe->mutex/1); lock(cb_lock); *** DEADLOCK *** 1 lock held by syz.7.9358/6111: #0: ffff8880880b1068 (&pipe->mutex/1){+.+.}-{3:3}, at: splice_from_pipe fs/splice.c:592 [inline] #0: ffff8880880b1068 (&pipe->mutex/1){+.+.}-{3:3}, at: generic_splice_sendpage+0xff/0x180 fs/splice.c:742 stack backtrace: CPU: 0 PID: 6111 Comm: syz.7.9358 Not tainted syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/16/2026 Call Trace: dump_stack_lvl+0x188/0x24e lib/dump_stack.c:106 check_noncircular+0x296/0x330 kernel/locking/lockdep.c:2170 check_prev_add kernel/locking/lockdep.c:3095 [inline] check_prevs_add kernel/locking/lockdep.c:3214 [inline] validate_chain kernel/locking/lockdep.c:3830 [inline] __lock_acquire+0x2d18/0x7c40 kernel/locking/lockdep.c:5063 lock_acquire+0x1bb/0x4a0 kernel/locking/lockdep.c:5678 down_read+0x42/0x2d0 kernel/locking/rwsem.c:1520 genl_rcv+0x15/0x40 net/netlink/genetlink.c:860 netlink_unicast_kernel net/netlink/af_netlink.c:1318 [inline] netlink_unicast+0x7ad/0x920 net/netlink/af_netlink.c:1344 netlink_sendmsg+0x8ad/0xbd0 net/netlink/af_netlink.c:1877 sock_sendmsg_nosec net/socket.c:718 [inline] __sock_sendmsg net/socket.c:730 [inline] sock_sendmsg net/socket.c:753 [inline] kernel_sendmsg+0x246/0x370 net/socket.c:777 sock_no_sendpage+0x137/0x1c0 net/core/sock.c:3268 kernel_sendpage+0x27d/0x570 net/socket.c:3606 sock_sendpage+0x7a/0xb0 net/socket.c:1082 pipe_to_sendpage+0x22f/0x320 fs/splice.c:360 splice_from_pipe_feed fs/splice.c:414 [inline] __splice_from_pipe+0x333/0x8e0 fs/splice.c:558 splice_from_pipe fs/splice.c:593 [inline] generic_splice_sendpage+0x111/0x180 fs/splice.c:742 do_splice_from fs/splice.c:763 [inline] do_splice+0xe46/0x1620 fs/splice.c:1102 __do_splice fs/splice.c:1167 [inline] __do_sys_splice fs/splice.c:1374 [inline] __se_sys_splice+0x34d/0x440 fs/splice.c:1356 do_syscall_x64 arch/x86/entry/common.c:46 [inline] do_syscall_64+0x4c/0xa0 arch/x86/entry/common.c:76 entry_SYSCALL_64_after_hwframe+0x68/0xd2 RIP: 0033:0x7f0f4e39e159 Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 e8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007f0f4f1c6028 EFLAGS: 00000246 ORIG_RAX: 0000000000000113 RAX: ffffffffffffffda RBX: 00007f0f4e625fa0 RCX: 00007f0f4e39e159 RDX: 0000000000000005 RSI: 0000000000000000 RDI: 0000000000000003 RBP: 00007f0f4e43506b R08: 0000000000003000 R09: 100000000000000d R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 00007f0f4e626038 R14: 00007f0f4e625fa0 R15: 00007ffd50590698 netlink: 28 bytes leftover after parsing attributes in process `syz.7.9358'.