cifs: Call close synchronously during unlink/rename/lease break.
authorRohith Surabattula <rohiths@microsoft.com>
Mon, 9 Aug 2021 09:32:46 +0000 (09:32 +0000)
committerSteve French <stfrench@microsoft.com>
Thu, 12 Aug 2021 16:29:58 +0000 (11:29 -0500)
commit9e992755be8f2d458a0bcbefd19e493483c1dba2
treef2d011d7355544948986ce55a2797ec494526906
parent41535701da3324b80029cabb501e86c4fafe339d
cifs: Call close synchronously during unlink/rename/lease break.

During unlink/rename/lease break, deferred work for close is
scheduled immediately but in an asynchronous manner which might
lead to race with actual(unlink/rename) commands.

This change will schedule close synchronously which will avoid
the race conditions with other commands.

Signed-off-by: Rohith Surabattula <rohiths@microsoft.com>
Reviewed-by: Shyam Prasad N <sprasad@microsoft.com>
Cc: stable@vger.kernel.org # 5.13
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/cifs/cifsglob.h
fs/cifs/file.c
fs/cifs/misc.c