pNFS/filelayout: Remove the whole file layout requirement
authorAnna Schumaker <Anna.Schumaker@Netapp.com>
Wed, 20 Mar 2024 21:11:19 +0000 (17:11 -0400)
committerTrond Myklebust <trond.myklebust@hammerspace.com>
Mon, 20 May 2024 15:06:04 +0000 (11:06 -0400)
Layout segments have been supported in pNFS for years, so remove the
requirement that the server always sends whole file layouts.

Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
fs/nfs/filelayout/filelayout.c

index ce8f8934bca517c0ea9a3ab21d0a3721fa075fac..3fb18b16a5b4e3077b098c8fa78b0f7ee7351699 100644 (file)
@@ -605,14 +605,6 @@ filelayout_check_layout(struct pnfs_layout_hdr *lo,
 
        dprintk("--> %s\n", __func__);
 
-       /* FIXME: remove this check when layout segment support is added */
-       if (lgr->range.offset != 0 ||
-           lgr->range.length != NFS4_MAX_UINT64) {
-               dprintk("%s Only whole file layouts supported. Use MDS i/o\n",
-                       __func__);
-               goto out;
-       }
-
        if (fl->pattern_offset > lgr->range.offset) {
                dprintk("%s pattern_offset %lld too large\n",
                                __func__, fl->pattern_offset);