]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ksmbd: separately allocate ci per dentry
authorNamjae Jeon <linkinjeon@kernel.org>
Sun, 31 Dec 2023 07:13:21 +0000 (16:13 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 5 Jan 2024 14:18:35 +0000 (15:18 +0100)
commit20dd92c237566627da03e0614545fbaf90d1cee6
treecbcc3ded9427efad9fea1ef8fb4a5fa828371376
parentd5651972e5c5e32c718a6c01ca57bef038dbb0a9
ksmbd: separately allocate ci per dentry

[ Upstream commit 4274a9dc6aeb9fea66bffba15697a35ae8983b6a ]

xfstests generic/002 test fail when enabling smb2 leases feature.
This test create hard link file, but removeal failed.
ci has a file open count to count file open through the smb client,
but in the case of hard link files, The allocation of ci per inode
cause incorrectly open count for file deletion. This patch allocate
ci per dentry to counts open counts for hard link.

Signed-off-by: Namjae Jeon <linkinjeon@kernel.org>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/smb/server/smb2pdu.c
fs/smb/server/vfs.c
fs/smb/server/vfs_cache.c
fs/smb/server/vfs_cache.h