cifs: fix max_credits implementation
authorShyam Prasad N <sprasad@microsoft.com>
Fri, 9 Jun 2023 17:46:58 +0000 (17:46 +0000)
committerSteve French <stfrench@microsoft.com>
Mon, 12 Jun 2023 01:52:49 +0000 (20:52 -0500)
commit5e90aa21eb1372736e08cee0c0bf47735c5c4b95
tree0a7c1b8733baf9534e469fb152c6adb41e92a16e
parent2991b77409891e14a10b96899755c004b0c07edb
cifs: fix max_credits implementation

The current implementation of max_credits on the client does
not work because the CreditRequest logic for several commands
does not take max_credits into account.

Still, we can end up asking the server for more credits, depending
on the number of credits in flight. For this, we need to
limit the credits while parsing the responses too.

Signed-off-by: Shyam Prasad N <sprasad@microsoft.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/smb/client/smb2ops.c
fs/smb/client/smb2pdu.c