Message ID | CAH2r5mtB05z7j45H4LRYGE8LUcyTL-17bacB=zm9LO5nZcvPgQ@mail.gmail.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | smb3: fix snapshot mount option | expand |
Acked-by me On Sat, Feb 12, 2022 at 6:06 PM Steve French <smfrench@gmail.com> wrote: > > The conversion to the new API broke the snapshot mount option > due to 32 vs. 64 bit type mismatch > > Fixes: 24e0a1eff9e2 ("cifs: switch to new mount api") > Cc: stable@vger.kernel.org # 5.11+ > Reported-by: <ruckajan10@gmail.com> > Signed-off-by: Steve French <stfrench@microsoft.com> > > diff --git a/fs/cifs/fs_context.c b/fs/cifs/fs_context.c > index 7ec35f3f0a5f..a92e9eec521f 100644 > --- a/fs/cifs/fs_context.c > +++ b/fs/cifs/fs_context.c > @@ -149,7 +149,7 @@ const struct fs_parameter_spec smb3_fs_parameters[] = { > fsparam_u32("echo_interval", Opt_echo_interval), > fsparam_u32("max_credits", Opt_max_credits), > fsparam_u32("handletimeout", Opt_handletimeout), > - fsparam_u32("snapshot", Opt_snapshot), > + fsparam_u64("snapshot", Opt_snapshot), > fsparam_u32("max_channels", Opt_max_channels), > > /* Mount options which take string value */ > @@ -1078,7 +1078,7 @@ static int smb3_fs_context_parse_param(struct > fs_context *fc, > ctx->echo_interval = result.uint_32; > break; > case Opt_snapshot: > - ctx->snapshot_time = result.uint_32; > + ctx->snapshot_time = result.uint_64; > break; > case Opt_max_credits: > if (result.uint_32 < 20 || result.uint_32 > 60000) { > cifs > > -- > Thanks, > > Steve
From b2a8dcf0fe76047c482bc962a6a32922f758eb7a Mon Sep 17 00:00:00 2001 From: Steve French <stfrench@microsoft.com> Date: Sat, 12 Feb 2022 01:54:14 -0600 Subject: [PATCH] smb3: fix snapshot mount option The conversion to the new API broke the snapshot mount option due to 32 vs. 64 bit type mismatch Fixes: 24e0a1eff9e2 ("cifs: switch to new mount api") Cc: stable@vger.kernel.org # 5.11+ Reported-by: <ruckajan10@gmail.com> Signed-off-by: Steve French <stfrench@microsoft.com> --- fs/cifs/fs_context.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/cifs/fs_context.c b/fs/cifs/fs_context.c index 7ec35f3f0a5f..a92e9eec521f 100644 --- a/fs/cifs/fs_context.c +++ b/fs/cifs/fs_context.c @@ -149,7 +149,7 @@ const struct fs_parameter_spec smb3_fs_parameters[] = { fsparam_u32("echo_interval", Opt_echo_interval), fsparam_u32("max_credits", Opt_max_credits), fsparam_u32("handletimeout", Opt_handletimeout), - fsparam_u32("snapshot", Opt_snapshot), + fsparam_u64("snapshot", Opt_snapshot), fsparam_u32("max_channels", Opt_max_channels), /* Mount options which take string value */ @@ -1078,7 +1078,7 @@ static int smb3_fs_context_parse_param(struct fs_context *fc, ctx->echo_interval = result.uint_32; break; case Opt_snapshot: - ctx->snapshot_time = result.uint_32; + ctx->snapshot_time = result.uint_64; break; case Opt_max_credits: if (result.uint_32 < 20 || result.uint_32 > 60000) { -- 2.32.0
The conversion to the new API broke the snapshot mount option due to 32 vs. 64 bit type mismatch Fixes: 24e0a1eff9e2 ("cifs: switch to new mount api") Cc: stable@vger.kernel.org # 5.11+ Reported-by: <ruckajan10@gmail.com> Signed-off-by: Steve French <stfrench@microsoft.com> if (result.uint_32 < 20 || result.uint_32 > 60000) { cifs