CIFS: Fix STATUS_CANNOT_DELETE error mapping for SMB2
authorPavel Shilovsky <pshilovsky@samba.org>
Fri, 18 Jul 2014 14:25:52 +0000 (18:25 +0400)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Sep 2014 16:04:01 +0000 (09:04 -0700)
commit9b1eceeba2e3aeefa4725f51ca617fe683ddfa65
tree8a94fed8a991a6b43e2128cd871f2bb5e4479db4
parent9c38ff707bbe0635121f8fb6f108ee376cff90fe
CIFS: Fix STATUS_CANNOT_DELETE error mapping for SMB2

commit 21496687a79424572f46a84c690d331055f4866f upstream.

The existing mapping causes unlink() call to return error after delete
operation. Changing the mapping to -EACCES makes the client process
the call like CIFS protocol does - reset dos attributes with ATTR_READONLY
flag masked off and retry the operation.

Signed-off-by: Pavel Shilovsky <pshilovsky@samba.org>
Signed-off-by: Steve French <smfrench@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/cifs/smb2maperror.c