Update the status of an async COPY operation when it has been
stopped. OFFLOAD_STATUS needs to indicate that the COPY is no longer
running.
Reviewed-by: Jeff Layton <jlayton@kernel.org>
Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
 static void nfsd4_stop_copy(struct nfsd4_copy *copy)
 {
        trace_nfsd_copy_async_cancel(copy);
-       if (!test_and_set_bit(NFSD4_COPY_F_STOPPED, ©->cp_flags))
+       if (!test_and_set_bit(NFSD4_COPY_F_STOPPED, ©->cp_flags)) {
                kthread_stop(copy->copy_task);
+               copy->nfserr = nfs_ok;
+               set_bit(NFSD4_COPY_F_COMPLETED, ©->cp_flags);
+       }
        nfs4_put_copy(copy);
 }