diff mbox series

[1/2] CIFS: Propagate min offload along with other parameters from primary to secondary channels.

Message ID 20250328061312.3043039-1-aman1cifs@gmail.com (mailing list archive)
State New
Headers show
Series [1/2] CIFS: Propagate min offload along with other parameters from primary to secondary channels. | expand

Commit Message

aman March 28, 2025, 6:13 a.m. UTC
From: Aman <aman1@microsoft.com>

In a multichannel setup, it was observed that a few fields were not being
copied over to the secondary channels, which impacted performance in cases
where these options were relevant but not properly synchronized. To address
this, this patch introduces copying the following parameters from the
primary channel to the secondary channels:

- min_offload
- retrans

By copying these parameters, we ensure consistency across channels and
prevent performance degradation due to missing or outdated settings.

Signed-off-by: Aman <aman1@microsoft.com>
---
 fs/smb/client/sess.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Shyam Prasad N March 28, 2025, 7:19 a.m. UTC | #1
On Fri, Mar 28, 2025 at 11:43 AM <aman1cifs@gmail.com> wrote:
>
> From: Aman <aman1@microsoft.com>
>
> In a multichannel setup, it was observed that a few fields were not being
> copied over to the secondary channels, which impacted performance in cases
> where these options were relevant but not properly synchronized. To address
> this, this patch introduces copying the following parameters from the
> primary channel to the secondary channels:
>
> - min_offload
> - retrans
>
> By copying these parameters, we ensure consistency across channels and
> prevent performance degradation due to missing or outdated settings.
>
> Signed-off-by: Aman <aman1@microsoft.com>
> ---
>  fs/smb/client/sess.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/fs/smb/client/sess.c b/fs/smb/client/sess.c
> index 91d4d409c..35ae7ad3b 100644
> --- a/fs/smb/client/sess.c
> +++ b/fs/smb/client/sess.c
> @@ -522,6 +522,8 @@ cifs_ses_add_channel(struct cifs_ses *ses,
>         ctx->sockopt_tcp_nodelay = ses->server->tcp_nodelay;
>         ctx->echo_interval = ses->server->echo_interval / HZ;
>         ctx->max_credits = ses->server->max_credits;
> +       ctx->min_offload = ses->server->min_offload;
> +       ctx->retrans = ses->server->retrans;
>
>         /*
>          * This will be used for encoding/decoding user/domain/pw
> --
> 2.43.0
>
>

Looks good to me. These are low risk and I've validated that this
change works as a part of my multichannel test runs.
Steve French March 30, 2025, 3:58 a.m. UTC | #2
I have also verified that ignore_signature is not properly propagated
across channels (the original patch , so am looking at the original
patch to verify the remaining five fields (that are propagated across
channels in the original patch).

On Fri, Mar 28, 2025 at 1:13 AM <aman1cifs@gmail.com> wrote:
>
> From: Aman <aman1@microsoft.com>
>
> In a multichannel setup, it was observed that a few fields were not being
> copied over to the secondary channels, which impacted performance in cases
> where these options were relevant but not properly synchronized. To address
> this, this patch introduces copying the following parameters from the
> primary channel to the secondary channels:
>
> - min_offload
> - retrans
>
> By copying these parameters, we ensure consistency across channels and
> prevent performance degradation due to missing or outdated settings.
>
> Signed-off-by: Aman <aman1@microsoft.com>
> ---
>  fs/smb/client/sess.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/fs/smb/client/sess.c b/fs/smb/client/sess.c
> index 91d4d409c..35ae7ad3b 100644
> --- a/fs/smb/client/sess.c
> +++ b/fs/smb/client/sess.c
> @@ -522,6 +522,8 @@ cifs_ses_add_channel(struct cifs_ses *ses,
>         ctx->sockopt_tcp_nodelay = ses->server->tcp_nodelay;
>         ctx->echo_interval = ses->server->echo_interval / HZ;
>         ctx->max_credits = ses->server->max_credits;
> +       ctx->min_offload = ses->server->min_offload;
> +       ctx->retrans = ses->server->retrans;
>
>         /*
>          * This will be used for encoding/decoding user/domain/pw
> --
> 2.43.0
>
>
diff mbox series

Patch

diff --git a/fs/smb/client/sess.c b/fs/smb/client/sess.c
index 91d4d409c..35ae7ad3b 100644
--- a/fs/smb/client/sess.c
+++ b/fs/smb/client/sess.c
@@ -522,6 +522,8 @@  cifs_ses_add_channel(struct cifs_ses *ses,
 	ctx->sockopt_tcp_nodelay = ses->server->tcp_nodelay;
 	ctx->echo_interval = ses->server->echo_interval / HZ;
 	ctx->max_credits = ses->server->max_credits;
+	ctx->min_offload = ses->server->min_offload;
+	ctx->retrans = ses->server->retrans;
 
 	/*
 	 * This will be used for encoding/decoding user/domain/pw