]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
smb: client: make use of smbdirect_socket.send_io.bcredits
authorStefan Metzmacher <metze@samba.org>
Thu, 22 Jan 2026 17:16:57 +0000 (18:16 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 16 Feb 2026 09:19:43 +0000 (10:19 +0100)
commitcca0526ef2344cab6944d7f441fc24e152da031b
tree4ff5407262735b38a31ae36ab31f08bd0193a536
parent9eff83600edf6957302816d6932389c8d1b6aa76
smb: client: make use of smbdirect_socket.send_io.bcredits

commit 21538121efe6c8c5b51c742fa02cbe820bc48714 upstream.

It turns out that our code will corrupt the stream of
reassabled data transfer messages when we trigger an
immendiate (empty) send.

In order to fix this we'll have a single 'batch' credit per
connection. And code getting that credit is free to use
as much messages until remaining_length reaches 0, then
the batch credit it given back and the next logical send can
happen.

Cc: <stable@vger.kernel.org> # 6.18.x
Cc: Steve French <smfrench@gmail.com>
Cc: Tom Talpey <tom@talpey.com>
Cc: Long Li <longli@microsoft.com>
Cc: Namjae Jeon <linkinjeon@kernel.org>
Cc: linux-cifs@vger.kernel.org
Cc: samba-technical@lists.samba.org
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/smb/client/smbdirect.c