From: Tigran Mkrtchyan Date: Mon, 20 Aug 2018 06:56:08 +0000 (+0200) Subject: nfs4: flex_file: ignore synthetic uid/gid for tightly coupled DSes X-Git-Tag: v4.20-rc1~2^2~23 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=10ec57e4c500007fb54b7030f1194121794d48eb;p=thirdparty%2Fkernel%2Flinux.git nfs4: flex_file: ignore synthetic uid/gid for tightly coupled DSes for tightly coupled DSes client must ignore provided synthetic uid and gid as stated in draft-ietf-nfsv4-flex-files-19#section-5.1. Signed-off-by: Tigran Mkrtchyan Signed-off-by: Trond Myklebust --- diff --git a/fs/nfs/flexfilelayout/flexfilelayoutdev.c b/fs/nfs/flexfilelayout/flexfilelayoutdev.c index 59aa04976331b..74d8d53524382 100644 --- a/fs/nfs/flexfilelayout/flexfilelayoutdev.c +++ b/fs/nfs/flexfilelayout/flexfilelayoutdev.c @@ -453,7 +453,7 @@ ff_layout_get_ds_cred(struct pnfs_layout_segment *lseg, u32 ds_idx, struct nfs4_ff_layout_mirror *mirror = FF_LAYOUT_COMP(lseg, ds_idx); struct rpc_cred *cred; - if (mirror) { + if (mirror && !mirror->mirror_ds->ds_versions[0].tightly_coupled) { cred = ff_layout_get_mirror_cred(mirror, lseg->pls_range.iomode); if (!cred) cred = get_rpccred(mdscred);