cifs: smbd: Return -EINVAL when the number of iovs exceeds SMBDIRECT_MAX_SGE
authorLong Li <longli@microsoft.com>
Wed, 16 Oct 2019 20:51:52 +0000 (13:51 -0700)
committerSteve French <stfrench@microsoft.com>
Mon, 25 Nov 2019 07:14:15 +0000 (01:14 -0600)
commit37941ea17d3f8eb2f5ac2f59346fab9e8439271a
tree51831f91d6fd58890750e41e41621a2ac504221d
parentb7a55bbd6d5402bfbadcfb3904e3c75b38ab5ba4
cifs: smbd: Return -EINVAL when the number of iovs exceeds SMBDIRECT_MAX_SGE

While it's not friendly to fail user processes that issue more iovs
than we support, at least we should return the correct error code so the
user process gets a chance to retry with smaller number of iovs.

Signed-off-by: Long Li <longli@microsoft.com>
Cc: stable@vger.kernel.org
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/cifs/smbdirect.c