]> git.hungrycats.org Git - linux/commit
cifs: check only tcon status on tcon related functions
authorShyam Prasad N <sprasad@microsoft.com>
Thu, 16 Mar 2023 10:45:12 +0000 (10:45 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 May 2023 11:58:55 +0000 (13:58 +0200)
commitf184f153b1e0c7e14b574cc2e3ac59e809aa789b
treed7798fb9fd2c9e32d0f9946836da1f9d164ea70c
parent26a4022ca2af51d930f6c4e249bd50f910ea5491
cifs: check only tcon status on tcon related functions

[ Upstream commit 2f0e4f0342201fe2228fcc2301cc2b42ae04b8e3 ]

We had a couple of checks for session in cifs_tree_connect
and cifs_mark_open_files_invalid, which were unnecessary.
And that was done with ses_lock. Changed that to tc_lock too.

Signed-off-by: Shyam Prasad N <sprasad@microsoft.com>
Reviewed-by: Paulo Alcantara (SUSE) <pc@manguebit.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Stable-dep-of: 6be2ea33a409 ("cifs: avoid potential races when handling multiple dfs tcons")
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/cifs/connect.c
fs/cifs/dfs.c
fs/cifs/dfs_cache.c
fs/cifs/file.c