From: Olga Kornievskaia <kolga@netapp.com>
To: <Trond.Myklebust@primarydata.com>
Cc: <linux-nfs@vger.kernel.org>
Subject: [RFC v2 10/12] NFS handle COPY ERR_OFFLOAD_NO_REQS
Date: Fri, 17 Mar 2017 17:03:55 -0400 [thread overview]
Message-ID: <20170317210357.48079-11-kolga@netapp.com> (raw)
In-Reply-To: <20170317210357.48079-1-kolga@netapp.com>
If client sent async COPY and server replied with
ERR_OFFLOAD_NO_REQS, client should retry with a synchronous copy.
Signed-off-by: Olga Kornievskaia <kolga@netapp.com>
---
fs/nfs/nfs42proc.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/fs/nfs/nfs42proc.c b/fs/nfs/nfs42proc.c
index 32b08ea..850fa10 100644
--- a/fs/nfs/nfs42proc.c
+++ b/fs/nfs/nfs42proc.c
@@ -225,10 +225,17 @@ static ssize_t _nfs42_proc_copy(struct file *src,
if (status)
return status;
+retry:
args->sync = sync;
status = nfs4_call_sync(server->client, server, &msg,
&args->seq_args, &res->seq_res, 0);
switch (status) {
+ case -NFS4ERR_OFFLOAD_NO_REQS:
+ if (!sync) {
+ sync = true;
+ goto retry;
+ }
+ break;
case -ENOTSUPP:
server->caps &= ~NFS_CAP_COPY;
break;
--
1.8.3.1
next prev parent reply other threads:[~2017-03-17 21:05 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-03-17 21:03 [RFC v2 00/12] NFS (just) async support for COPY Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 01/12] NFS CB_OFFLOAD xdr Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 02/12] NFS OFFLOAD_STATUS xdr Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 03/12] NFS OFFLOAD_STATUS op Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 04/12] NFS OFFLOAD_CANCEL xdr Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 05/12] NFS COPY xdr handle async reply Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 06/12] NFS add support for asynchronous COPY Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 07/12] NFS handle COPY reply CB_OFFLOAD call race Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 08/12] NFS send OFFLOAD_CANCEL when COPY killed Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 09/12] NFS make COPY synchronous xdr configurable Olga Kornievskaia
2017-03-17 21:03 ` Olga Kornievskaia [this message]
2017-03-17 21:03 ` [RFC v2 11/12] NFS if we got partial copy ignore errors Olga Kornievskaia
2017-03-17 21:03 ` [RFC v2 12/12] NFS recover from destination server reboot for copies Olga Kornievskaia
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170317210357.48079-11-kolga@netapp.com \
--to=kolga@netapp.com \
--cc=Trond.Myklebust@primarydata.com \
--cc=linux-nfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.