syzbot


KCSAN: data-race in __d_rehash / fast_dput (3)

Status: moderation: reported on 2024/07/06 06:52
Subsystems: fs
[Documentation on labels]
Reported-by: syzbot+b2d3368ead515aba5cd1@syzkaller.appspotmail.com
First crash: 137d, last: 26d
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream KCSAN: data-race in __d_rehash / fast_dput (2) fs 1 173d 173d 0/28 auto-obsoleted due to no activity on 2024/07/05 19:42
upstream KCSAN: data-race in __d_rehash / fast_dput ext4 2 236d 270d 0/28 auto-obsoleted due to no activity on 2024/05/03 21:19

Sample crash report:
==================================================================
BUG: KCSAN: data-race in __d_rehash / fast_dput

write to 0xffff88810650ab50 of 8 bytes by task 3312 on cpu 1:
 hlist_bl_add_head_rcu include/linux/rculist_bl.h:81 [inline]
 __d_rehash+0xa9/0x210 fs/dcache.c:2419
 __d_add+0x373/0x4a0 fs/dcache.c:2634
 d_splice_alias+0xd6/0x270 fs/dcache.c:3025
 proc_sys_lookup+0x386/0x440 fs/proc/proc_sysctl.c:539
 lookup_open fs/namei.c:3573 [inline]
 open_last_lookups fs/namei.c:3694 [inline]
 path_openat+0xd40/0x1fa0 fs/namei.c:3930
 do_filp_open+0xf7/0x200 fs/namei.c:3960
 do_sys_openat2+0xab/0x120 fs/open.c:1415
 do_sys_open fs/open.c:1430 [inline]
 __do_sys_openat fs/open.c:1446 [inline]
 __se_sys_openat fs/open.c:1441 [inline]
 __x64_sys_openat+0xf3/0x120 fs/open.c:1441
 x64_sys_call+0x1025/0x2d60 arch/x86/include/generated/asm/syscalls_64.h:258
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

read to 0xffff88810650ab50 of 8 bytes by task 3313 on cpu 0:
 hlist_bl_unhashed include/linux/list_bl.h:54 [inline]
 d_unhashed include/linux/dcache.h:354 [inline]
 retain_dentry fs/dcache.c:698 [inline]
 fast_dput+0xd8/0x2c0 fs/dcache.c:811
 dput+0x24/0xd0 fs/dcache.c:851
 __fput+0x3fb/0x6d0 fs/file_table.c:439
 __fput_sync+0x43/0x60 fs/file_table.c:516
 __do_sys_close fs/open.c:1567 [inline]
 __se_sys_close+0xf9/0x1a0 fs/open.c:1552
 __x64_sys_close+0x1f/0x30 fs/open.c:1552
 x64_sys_call+0x25cb/0x2d60 arch/x86/include/generated/asm/syscalls_64.h:4
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xc9/0x1c0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f

value changed: 0xffff888237558f00 -> 0xffff8881065296c8

Reported by Kernel Concurrency Sanitizer on:
CPU: 0 UID: 0 PID: 3313 Comm: syz-executor Not tainted 6.12.0-rc4-syzkaller-00261-g850925a8133c #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/13/2024
==================================================================
chnl_net:caif_netlink_parms(): no params data found
bridge0: port 1(bridge_slave_0) entered blocking state
bridge0: port 1(bridge_slave_0) entered disabled state
bridge_slave_0: entered allmulticast mode
bridge_slave_0: entered promiscuous mode
bridge0: port 2(bridge_slave_1) entered blocking state
bridge0: port 2(bridge_slave_1) entered disabled state
bridge_slave_1: entered allmulticast mode
bridge_slave_1: entered promiscuous mode
bond0: (slave bond_slave_0): Enslaving as an active interface with an up link
bond0: (slave bond_slave_1): Enslaving as an active interface with an up link
team0: Port device team_slave_0 added
team0: Port device team_slave_1 added
batman_adv: batadv0: Adding interface: batadv_slave_0
batman_adv: batadv0: The MTU of interface batadv_slave_0 is too small (1500) to handle the transport of batman-adv packets. Packets going over this interface will be fragmented on layer2 which could impact the performance. Setting the MTU to 1560 would solve the problem.
batman_adv: batadv0: Not using interface batadv_slave_0 (retrying later): interface not active
batman_adv: batadv0: Adding interface: batadv_slave_1
batman_adv: batadv0: The MTU of interface batadv_slave_1 is too small (1500) to handle the transport of batman-adv packets. Packets going over this interface will be fragmented on layer2 which could impact the performance. Setting the MTU to 1560 would solve the problem.
batman_adv: batadv0: Not using interface batadv_slave_1 (retrying later): interface not active
hsr_slave_0: entered promiscuous mode
hsr_slave_1: entered promiscuous mode
debugfs: Directory 'hsr0' with parent 'hsr' already present!
Cannot create hsr debugfs directory
netdevsim netdevsim3 netdevsim0: renamed from eth0
netdevsim netdevsim3 netdevsim1: renamed from eth1
netdevsim netdevsim3 netdevsim2: renamed from eth2
netdevsim netdevsim3 netdevsim3: renamed from eth3
8021q: adding VLAN 0 to HW filter on device bond0
8021q: adding VLAN 0 to HW filter on device team0
8021q: adding VLAN 0 to HW filter on device batadv0
veth0_vlan: entered promiscuous mode
veth1_vlan: entered promiscuous mode
veth0_macvtap: entered promiscuous mode
veth1_macvtap: entered promiscuous mode
batman_adv: batadv0: Interface activated: batadv_slave_0
batman_adv: batadv0: Interface activated: batadv_slave_1
netdevsim netdevsim3 netdevsim0: set [1, 0] type 2 family 0 port 6081 - 0
netdevsim netdevsim3 netdevsim1: set [1, 0] type 2 family 0 port 6081 - 0
netdevsim netdevsim3 netdevsim2: set [1, 0] type 2 family 0 port 6081 - 0
netdevsim netdevsim3 netdevsim3: set [1, 0] type 2 family 0 port 6081 - 0
soft_limit_in_bytes is deprecated and will be removed. Please report your usecase to linux-mm@kvack.org if you depend on this functionality.

Crashes (18):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2024/10/26 01:14 upstream 850925a8133c 045e728d .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/10/22 06:26 upstream d12937763990 a93682b3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/10/16 08:25 upstream 2f87d0916ce0 bde2d81c .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/10/12 19:10 upstream 09f6b0c8904b 084d8178 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/10/05 00:16 upstream 2f91ff27b0ee d7906eff .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/10/02 01:52 upstream e32cde8d2bd7 ea2b66a6 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/09/24 23:37 upstream abf2050f51fd 5643e0e9 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/09/19 22:31 upstream 2004cef11ea0 6f888b75 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/09/19 14:09 upstream 839c4f596f89 c673ca06 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/09/03 16:30 upstream 67784a74e258 326f9c5a .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/08/24 18:56 upstream d2bafcf224f3 d7d32352 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/08/14 15:13 upstream 6b0f8db921ab e6b88e20 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/08/13 04:46 upstream d74da846046a 7b0f4b46 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/08/11 18:01 upstream 5189dafa4cf9 6f4edef4 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/08/01 17:35 upstream 183d46ff422e 1e9c4cf3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/08/01 15:35 upstream 21b136cc63d2 1e9c4cf3 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/07/13 05:40 upstream 528dd46d0fc3 eaeb5c15 .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
2024/07/06 06:51 upstream d270dd21bee0 2a40360c .config console log report info [disk image] [vmlinux] [kernel image] ci2-upstream-kcsan-gce KCSAN: data-race in __d_rehash / fast_dput
* Struck through repros no longer work on HEAD.