mirror of
https://github.com/rd-stuffs/msm-4.14.git
synced 2025-02-20 11:45:48 +08:00
flexfiles: enforce per-mirror stateid only for v4 DSes
commit 320f35b7bf8cccf1997ca3126843535e1b95e9c4 upstream. Since commit bb21ce0ad227 we always enforce per-mirror stateid. However, this makes sense only for v4+ servers. Signed-off-by: Tigran Mkrtchyan <tigran.mkrtchyan@desy.de> Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
891e5a89f0
commit
5d2cc520d1
@ -1725,7 +1725,8 @@ ff_layout_read_pagelist(struct nfs_pgio_header *hdr)
|
||||
if (fh)
|
||||
hdr->args.fh = fh;
|
||||
|
||||
if (!nfs4_ff_layout_select_ds_stateid(lseg, idx, &hdr->args.stateid))
|
||||
if (vers == 4 &&
|
||||
!nfs4_ff_layout_select_ds_stateid(lseg, idx, &hdr->args.stateid))
|
||||
goto out_failed;
|
||||
|
||||
/*
|
||||
@ -1790,7 +1791,8 @@ ff_layout_write_pagelist(struct nfs_pgio_header *hdr, int sync)
|
||||
if (fh)
|
||||
hdr->args.fh = fh;
|
||||
|
||||
if (!nfs4_ff_layout_select_ds_stateid(lseg, idx, &hdr->args.stateid))
|
||||
if (vers == 4 &&
|
||||
!nfs4_ff_layout_select_ds_stateid(lseg, idx, &hdr->args.stateid))
|
||||
goto out_failed;
|
||||
|
||||
/*
|
||||
|
Loading…
x
Reference in New Issue
Block a user