android_kernel_samsung_a7y1.../fs/cifs
Ronnie Sahlberg 3bc27761f7 cifs: don't leak -EAGAIN for stat() during reconnect
commit fc513fac56e1b626ae48a74d7551d9c35c50129e upstream.

If from cifs_revalidate_dentry_attr() the SMB2/QUERY_INFO call fails with an
error, such as STATUS_SESSION_EXPIRED, causing the session to be reconnected
it is possible we will leak -EAGAIN back to the application even for
system calls such as stat() where this is not a valid error.

Fix this by re-trying the operation from within cifs_revalidate_dentry_attr()
if cifs_get_inode_info*() returns -EAGAIN.

This fixes stat() and possibly also other system calls that uses
cifs_revalidate_dentry*().

Signed-off-by: Ronnie Sahlberg <lsahlber@redhat.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Reviewed-by: Pavel Shilovsky <pshilov@microsoft.com>
Reviewed-by: Aurelien Aptel <aaptel@suse.com>
CC: Stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-04-07 14:10:10 +02:00
..
asn1.c
cache.c
cifs_debug.c
cifs_debug.h
cifs_dfs_ref.c
cifs_fs_sb.h
cifs_ioctl.h
cifs_spnego.c
cifs_spnego.h
cifs_unicode.c
cifs_unicode.h
cifs_uniupr.h
cifsacl.c cifs: Fix mode output in debugging statements 2020-04-07 14:04:20 +02:00
cifsacl.h
cifsencrypt.c
cifsfs.c
cifsfs.h
cifsglob.h cifs: Fix cifsInodeInfo lock_sem deadlock when reconnect occurs 2020-04-07 09:29:13 +02:00
cifspdu.h
cifsproto.h cifs: Fix cifsInodeInfo lock_sem deadlock when reconnect occurs 2020-04-07 09:29:13 +02:00
cifssmb.c
connect.c cifs: Fix mode output in debugging statements 2020-04-07 14:04:20 +02:00
dir.c CIFS: Force reval dentry if LOOKUP_REVAL flag is set 2020-04-07 08:09:52 +02:00
dns_resolve.c
dns_resolve.h
export.c
file.c CIFS: Respect O_SYNC and O_DIRECT flags during reconnect 2020-04-07 13:12:47 +02:00
fscache.c
fscache.h
inode.c cifs: don't leak -EAGAIN for stat() during reconnect 2020-04-07 14:10:10 +02:00
ioctl.c
Kconfig
link.c
Makefile
misc.c
netmisc.c fs: cifs: mute -Wunused-const-variable message 2020-04-07 09:27:39 +02:00
nterr.c
nterr.h
ntlmssp.h
readdir.c
rfc1002pdu.h
sess.c
smb1ops.c CIFS: avoid using MID 0xFFFF 2020-04-07 09:26:58 +02:00
smb2file.c cifs: Adjust indentation in smb2_open_file 2020-04-07 13:36:50 +02:00
smb2glob.h
smb2inode.c
smb2maperror.c SMB3: retry on STATUS_INSUFFICIENT_RESOURCES instead of failing write 2020-04-06 19:16:56 +02:00
smb2misc.c CIFS: Fix SMB2 oplock break processing 2020-04-07 12:45:47 +02:00
smb2ops.c CIFS: Fix oplock handling for SMB 2.1+ protocols 2020-04-07 07:41:09 +02:00
smb2pdu.c cifs: fail i/o on soft mounts if sessionsetup errors out 2020-04-07 13:51:35 +02:00
smb2pdu.h
smb2proto.h
smb2status.h
smb2transport.c
smbencrypt.c
smberr.h
smbfsctl.h
transport.c
winucase.c
xattr.c