* Patch "nfsd: Fix up the "supattr_exclcreat" attributes" has been added to the 4.9-stable tree
@ 2017-05-23 18:38 gregkh
2017-05-23 19:26 ` Greg KH
0 siblings, 1 reply; 3+ messages in thread
From: gregkh @ 2017-05-23 18:38 UTC (permalink / raw)
To: trond.myklebust, bfields, gregkh; +Cc: stable, stable-commits
This is a note to let you know that I've just added the patch titled
nfsd: Fix up the "supattr_exclcreat" attributes
to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
nfsd-fix-up-the-supattr_exclcreat-attributes.patch
and it can be found in the queue-4.9 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
>From b26b78cb726007533d81fdf90a62e915002ef5c8 Mon Sep 17 00:00:00 2001
From: Trond Myklebust <trond.myklebust@primarydata.com>
Date: Tue, 9 May 2017 16:24:59 -0400
Subject: nfsd: Fix up the "supattr_exclcreat" attributes
From: Trond Myklebust <trond.myklebust@primarydata.com>
commit b26b78cb726007533d81fdf90a62e915002ef5c8 upstream.
If an NFSv4 client asks us for the supattr_exclcreat, then we must
not return attributes that are unsupported by this minor version.
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Fixes: 75976de6556f ("NFSD: Return word2 bitmask if setting security..,")
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
fs/nfsd/nfs4xdr.c | 11 ++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)
--- a/fs/nfsd/nfs4xdr.c
+++ b/fs/nfsd/nfs4xdr.c
@@ -2793,9 +2793,14 @@ out_acl:
}
#endif /* CONFIG_NFSD_PNFS */
if (bmval2 & FATTR4_WORD2_SUPPATTR_EXCLCREAT) {
- status = nfsd4_encode_bitmap(xdr, NFSD_SUPPATTR_EXCLCREAT_WORD0,
- NFSD_SUPPATTR_EXCLCREAT_WORD1,
- NFSD_SUPPATTR_EXCLCREAT_WORD2);
+ u32 supp[3];
+
+ memcpy(supp, nfsd_suppattrs[minorversion], sizeof(supp));
+ supp[0] &= NFSD_SUPPATTR_EXCLCREAT_WORD0;
+ supp[1] &= NFSD_SUPPATTR_EXCLCREAT_WORD1;
+ supp[2] &= NFSD_SUPPATTR_EXCLCREAT_WORD2;
+
+ status = nfsd4_encode_bitmap(xdr, supp[0], supp[1], supp[2]);
if (status)
goto out;
}
Patches currently in stable-queue which might be from trond.myklebust@primarydata.com are
queue-4.9/nfs-use-gfp_noio-for-two-allocations-in-writeback.patch
queue-4.9/nfsv4-fix-a-hang-in-open-related-to-server-reboot.patch
queue-4.9/nfsd-fix-up-the-supattr_exclcreat-attributes.patch
queue-4.9/nfs-fix-use-after-free-in-write-error-path.patch
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: Patch "nfsd: Fix up the "supattr_exclcreat" attributes" has been added to the 4.9-stable tree
2017-05-23 18:38 Patch "nfsd: Fix up the "supattr_exclcreat" attributes" has been added to the 4.9-stable tree gregkh
@ 2017-05-23 19:26 ` Greg KH
0 siblings, 0 replies; 3+ messages in thread
From: Greg KH @ 2017-05-23 19:26 UTC (permalink / raw)
To: trond.myklebust, bfields; +Cc: stable, stable-commits
Same problem here on 4.9, it breaks this tree too...
greg k-h
On Tue, May 23, 2017 at 08:38:11PM +0200, gregkh@linuxfoundation.org wrote:
>
> This is a note to let you know that I've just added the patch titled
>
> nfsd: Fix up the "supattr_exclcreat" attributes
>
> to the 4.9-stable tree which can be found at:
> http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
>
> The filename of the patch is:
> nfsd-fix-up-the-supattr_exclcreat-attributes.patch
> and it can be found in the queue-4.9 subdirectory.
>
> If you, or anyone else, feels it should not be added to the stable tree,
> please let <stable@vger.kernel.org> know about it.
>
>
> >From b26b78cb726007533d81fdf90a62e915002ef5c8 Mon Sep 17 00:00:00 2001
> From: Trond Myklebust <trond.myklebust@primarydata.com>
> Date: Tue, 9 May 2017 16:24:59 -0400
> Subject: nfsd: Fix up the "supattr_exclcreat" attributes
>
> From: Trond Myklebust <trond.myklebust@primarydata.com>
>
> commit b26b78cb726007533d81fdf90a62e915002ef5c8 upstream.
>
> If an NFSv4 client asks us for the supattr_exclcreat, then we must
> not return attributes that are unsupported by this minor version.
>
> Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
> Fixes: 75976de6556f ("NFSD: Return word2 bitmask if setting security..,")
> Signed-off-by: J. Bruce Fields <bfields@redhat.com>
> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
>
> ---
> fs/nfsd/nfs4xdr.c | 11 ++++++++---
> 1 file changed, 8 insertions(+), 3 deletions(-)
>
> --- a/fs/nfsd/nfs4xdr.c
> +++ b/fs/nfsd/nfs4xdr.c
> @@ -2793,9 +2793,14 @@ out_acl:
> }
> #endif /* CONFIG_NFSD_PNFS */
> if (bmval2 & FATTR4_WORD2_SUPPATTR_EXCLCREAT) {
> - status = nfsd4_encode_bitmap(xdr, NFSD_SUPPATTR_EXCLCREAT_WORD0,
> - NFSD_SUPPATTR_EXCLCREAT_WORD1,
> - NFSD_SUPPATTR_EXCLCREAT_WORD2);
> + u32 supp[3];
> +
> + memcpy(supp, nfsd_suppattrs[minorversion], sizeof(supp));
> + supp[0] &= NFSD_SUPPATTR_EXCLCREAT_WORD0;
> + supp[1] &= NFSD_SUPPATTR_EXCLCREAT_WORD1;
> + supp[2] &= NFSD_SUPPATTR_EXCLCREAT_WORD2;
> +
> + status = nfsd4_encode_bitmap(xdr, supp[0], supp[1], supp[2]);
> if (status)
> goto out;
> }
>
>
> Patches currently in stable-queue which might be from trond.myklebust@primarydata.com are
>
> queue-4.9/nfs-use-gfp_noio-for-two-allocations-in-writeback.patch
> queue-4.9/nfsv4-fix-a-hang-in-open-related-to-server-reboot.patch
> queue-4.9/nfsd-fix-up-the-supattr_exclcreat-attributes.patch
> queue-4.9/nfs-fix-use-after-free-in-write-error-path.patch
^ permalink raw reply [flat|nested] 3+ messages in thread
* Patch "nfsd: Fix up the "supattr_exclcreat" attributes" has been added to the 4.9-stable tree
@ 2017-06-12 7:55 gregkh
0 siblings, 0 replies; 3+ messages in thread
From: gregkh @ 2017-06-12 7:55 UTC (permalink / raw)
To: trond.myklebust, bfields, gregkh; +Cc: stable, stable-commits
This is a note to let you know that I've just added the patch titled
nfsd: Fix up the "supattr_exclcreat" attributes
to the 4.9-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
nfsd-fix-up-the-supattr_exclcreat-attributes.patch
and it can be found in the queue-4.9 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
>From b26b78cb726007533d81fdf90a62e915002ef5c8 Mon Sep 17 00:00:00 2001
From: Trond Myklebust <trond.myklebust@primarydata.com>
Date: Tue, 9 May 2017 16:24:59 -0400
Subject: nfsd: Fix up the "supattr_exclcreat" attributes
From: Trond Myklebust <trond.myklebust@primarydata.com>
commit b26b78cb726007533d81fdf90a62e915002ef5c8 upstream.
If an NFSv4 client asks us for the supattr_exclcreat, then we must
not return attributes that are unsupported by this minor version.
Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Fixes: 75976de6556f ("NFSD: Return word2 bitmask if setting security..,")
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
fs/nfsd/nfs4xdr.c | 13 ++++++++++---
1 file changed, 10 insertions(+), 3 deletions(-)
--- a/fs/nfsd/nfs4xdr.c
+++ b/fs/nfsd/nfs4xdr.c
@@ -2793,9 +2793,16 @@ out_acl:
}
#endif /* CONFIG_NFSD_PNFS */
if (bmval2 & FATTR4_WORD2_SUPPATTR_EXCLCREAT) {
- status = nfsd4_encode_bitmap(xdr, NFSD_SUPPATTR_EXCLCREAT_WORD0,
- NFSD_SUPPATTR_EXCLCREAT_WORD1,
- NFSD_SUPPATTR_EXCLCREAT_WORD2);
+ u32 supp[3];
+
+ supp[0] = nfsd_suppattrs0(minorversion);
+ supp[1] = nfsd_suppattrs1(minorversion);
+ supp[2] = nfsd_suppattrs2(minorversion);
+ supp[0] &= NFSD_SUPPATTR_EXCLCREAT_WORD0;
+ supp[1] &= NFSD_SUPPATTR_EXCLCREAT_WORD1;
+ supp[2] &= NFSD_SUPPATTR_EXCLCREAT_WORD2;
+
+ status = nfsd4_encode_bitmap(xdr, supp[0], supp[1], supp[2]);
if (status)
goto out;
}
Patches currently in stable-queue which might be from trond.myklebust@primarydata.com are
queue-4.9/nfsd-fix-up-the-supattr_exclcreat-attributes.patch
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-06-12 7:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-05-23 18:38 Patch "nfsd: Fix up the "supattr_exclcreat" attributes" has been added to the 4.9-stable tree gregkh
2017-05-23 19:26 ` Greg KH
-- strict thread matches above, loose matches on Subject: below --
2017-06-12 7:55 gregkh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).