diff options
| author | Paulo Alcantara <[email protected]> | 2025-05-12 17:58:36 +0000 |
|---|---|---|
| committer | Steve French <[email protected]> | 2025-05-15 00:26:38 +0000 |
| commit | 3965c23773e81c476f6de30ccc5d201c59ff9714 (patch) | |
| tree | f94b1ede623677d9638d64fb1be4af71caa4179a /rust/helpers/mutex.c | |
| parent | smb: client: fix memory leak during error handling for POSIX mkdir (diff) | |
| download | kernel-3965c23773e81c476f6de30ccc5d201c59ff9714.tar.gz kernel-3965c23773e81c476f6de30ccc5d201c59ff9714.zip | |
smb: client: fix zero rsize error messages
cifs_prepare_read() might be called with a disconnected channel, where
TCP_Server_Info::max_read is set to zero due to reconnect, so calling
->negotiate_rize() will set @rsize to default min IO size (64KiB) and
then logging
CIFS: VFS: SMB: Zero rsize calculated, using minimum value
65536
If the reconnect happens in cifsd thread, cifs_renegotiate_iosize()
will end up being called and then @rsize set to the expected value.
Since we can't rely on the value of @server->max_read by the time we
call cifs_prepare_read(), try to ->negotiate_rize() only if
@cifs_sb->ctx->rsize is zero.
Reported-by: Steve French <[email protected]>
Fixes: c59f7c9661b9 ("smb: client: ensure aligned IO sizes")
Signed-off-by: Paulo Alcantara (Red Hat) <[email protected]>
Signed-off-by: Steve French <[email protected]>
Diffstat (limited to 'rust/helpers/mutex.c')
0 files changed, 0 insertions, 0 deletions
