]> git.hungrycats.org Git - linux/commit
cifs: avoid potential races when handling multiple dfs tcons
authorPaulo Alcantara <pc@manguebit.com>
Thu, 27 Apr 2023 07:40:08 +0000 (04:40 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 May 2023 11:58:56 +0000 (13:58 +0200)
commita9e3d4ad71a3ca8e4e576e36afab38426a26d31a
tree773ea0aa208065eb356b8d40c838a55dadeb36df
parentf184f153b1e0c7e14b574cc2e3ac59e809aa789b
cifs: avoid potential races when handling multiple dfs tcons

[ Upstream commit 6be2ea33a4093402252724a00c4af8033725184c ]

Now that a DFS tcon manages its own list of DFS referrals and
sessions, there is no point in having a single worker to refresh
referrals of all DFS tcons.  Make it faster and less prone to race
conditions when having several mounts by queueing a worker per DFS
tcon that will take care of refreshing only the DFS referrals related
to it.

Cc: stable@vger.kernel.org # v6.2+
Signed-off-by: Paulo Alcantara (SUSE) <pc@manguebit.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/cifs/cifsglob.h
fs/cifs/connect.c
fs/cifs/dfs.c
fs/cifs/dfs_cache.c
fs/cifs/dfs_cache.h