OSDN Git Service

CIFS: Close open handle after interrupted close
authorPavel Shilovsky <pshilov@microsoft.com>
Thu, 21 Nov 2019 19:35:12 +0000 (11:35 -0800)
committerSteve French <stfrench@microsoft.com>
Mon, 25 Nov 2019 07:14:53 +0000 (01:14 -0600)
commit9150c3adbf24d77cfba37f03639d4a908ca4ac25
treeb9fa0904f0d98d78aab1818c966a273bc67c462c
parent44805b0e62f15e90d233485420e1847133716bdc
CIFS: Close open handle after interrupted close

If Close command is interrupted before sending a request
to the server the client ends up leaking an open file
handle. This wastes server resources and can potentially
block applications that try to remove the file or any
directory containing this file.

Fix this by putting the close command into a worker queue,
so another thread retries it later.

Cc: Stable <stable@vger.kernel.org>
Tested-by: Frank Sorenson <sorenson@redhat.com>
Reviewed-by: Ronnie Sahlberg <lsahlber@redhat.com>
Signed-off-by: Pavel Shilovsky <pshilov@microsoft.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/cifs/smb2misc.c
fs/cifs/smb2pdu.c
fs/cifs/smb2proto.h