diff options
author | Ronnie Sahlberg <lsahlber@redhat.com> | 2022-08-10 22:00:08 -0500 |
---|---|---|
committer | Steve French <stfrench@microsoft.com> | 2022-08-11 10:33:18 -0500 |
commit | 05b98fd2da6bdf241d3b9ba40582d60a84a89d70 (patch) | |
tree | 8d32c6b3ed80270c9c81574fc9449e9b783ee2e2 /fs/cifs/file.c | |
parent | cd04345598b7c191d41574bc9da3fe435dc65605 (diff) | |
download | linux-stable-05b98fd2da6bdf241d3b9ba40582d60a84a89d70.tar.gz linux-stable-05b98fd2da6bdf241d3b9ba40582d60a84a89d70.tar.bz2 linux-stable-05b98fd2da6bdf241d3b9ba40582d60a84a89d70.zip |
cifs: Move cached-dir functions into a separate file
Also rename crfid to cfid to have consistent naming for this variable.
This commit does not change any logic.
Signed-off-by: Ronnie Sahlberg <lsahlber@redhat.com>
Reviewed-by: Paulo Alcantara (SUSE) <pc@cjr.nz>
Signed-off-by: Steve French <stfrench@microsoft.com>
Diffstat (limited to 'fs/cifs/file.c')
-rw-r--r-- | fs/cifs/file.c | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/fs/cifs/file.c b/fs/cifs/file.c index 09975bd7d860..42f2639a1a66 100644 --- a/fs/cifs/file.c +++ b/fs/cifs/file.c @@ -34,6 +34,7 @@ #include "smbdirect.h" #include "fs_context.h" #include "cifs_ioctl.h" +#include "cached_dir.h" /* * Mark as invalid, all open files on tree connections since they @@ -64,13 +65,7 @@ cifs_mark_open_files_invalid(struct cifs_tcon *tcon) } spin_unlock(&tcon->open_file_lock); - mutex_lock(&tcon->crfid.fid_mutex); - tcon->crfid.is_valid = false; - /* cached handle is not valid, so SMB2_CLOSE won't be sent below */ - close_cached_dir_lease_locked(&tcon->crfid); - memset(tcon->crfid.fid, 0, sizeof(struct cifs_fid)); - mutex_unlock(&tcon->crfid.fid_mutex); - + invalidate_all_cached_dirs(tcon); spin_lock(&tcon->tc_lock); if (tcon->status == TID_IN_FILES_INVALIDATE) tcon->status = TID_NEED_TCON; |