From patchwork Mon Sep 21 00:48:42 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Trond Myklebust X-Patchwork-Id: 7226861 Return-Path: X-Original-To: patchwork-linux-nfs@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 771E69F372 for ; Mon, 21 Sep 2015 00:49:12 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 84F7B206DF for ; Mon, 21 Sep 2015 00:49:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9C98D20688 for ; Mon, 21 Sep 2015 00:49:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755601AbbIUAtF (ORCPT ); Sun, 20 Sep 2015 20:49:05 -0400 Received: from mail-yk0-f176.google.com ([209.85.160.176]:35701 "EHLO mail-yk0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755662AbbIUAsu (ORCPT ); Sun, 20 Sep 2015 20:48:50 -0400 Received: by ykdz138 with SMTP id z138so9218336ykd.2 for ; Sun, 20 Sep 2015 17:48:49 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=++hkT62tMd1i3W0PAU9L+gNavnb1J548bQFrg/GtGEk=; b=B3yFcMifnpxGKJ4fj8XgW2gt0rkbMTOmbHcnZD7EQ8wOlr6ZtJPadEj5sn49yMsjWf ALGOQHFu+8xb/rJWXwC2MiRR7BxDC2YTTfUXdQN0/8CG16NK1oodDv48r/b1OnPuJ4H5 Y5lpzvM0eOXYWaoxd52tIieFH7m/EnTVHg7gbYEhevLbHx1RYG+QHUmeBnTtDSbepmZ+ CD00PRrrJm0xv7l/g10t2ttOfkRHnPnKxHb6GXuEQOcQ+GEuvEs0U7venxRVXd1o+Ydn R/eMuJJ72592fnDHTl/hQ990/7T2LTS+O2IkUro1Rseap6+FdRJXyQ9mZXHeF1uOvU6E Tcsw== X-Gm-Message-State: ALoCoQmAqwivh4RAi+V2NxoFNzLjk9T9vnb7WNcsK3EyUNlK7/t7pCsZfRBxd/kNLEaHbcIiZ6x7 X-Received: by 10.170.96.196 with SMTP id n187mr14515568yka.54.1442796529316; Sun, 20 Sep 2015 17:48:49 -0700 (PDT) Received: from leira.trondhjem.org.localdomain (97-83-36-41.dhcp.trcy.mi.charter.com. [97.83.36.41]) by smtp.gmail.com with ESMTPSA id o3sm13848310ywc.14.2015.09.20.17.48.48 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 20 Sep 2015 17:48:48 -0700 (PDT) From: Trond Myklebust To: linux-nfs@vger.kernel.org Subject: [PATCH v2 3/5] NFSv4: nfs4_async_handle_error should take a non-const nfs_server Date: Sun, 20 Sep 2015 20:48:42 -0400 Message-Id: <1442796524-89165-3-git-send-email-trond.myklebust@primarydata.com> X-Mailer: git-send-email 2.4.3 In-Reply-To: <1442796524-89165-2-git-send-email-trond.myklebust@primarydata.com> References: <1442796524-89165-1-git-send-email-trond.myklebust@primarydata.com> <1442796524-89165-2-git-send-email-trond.myklebust@primarydata.com> Sender: linux-nfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-nfs@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP For symmetry with the synchronous handler, and so that we can potentially handle errors such as NFS4ERR_BADNAME. Signed-off-by: Trond Myklebust --- fs/nfs/nfs4proc.c | 6 +++--- include/linux/nfs_xdr.h | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 9ab48308f195..b6bf246b9b6c 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -78,7 +78,7 @@ struct nfs4_opendata; static int _nfs4_proc_open(struct nfs4_opendata *data); static int _nfs4_recover_proc_open(struct nfs4_opendata *data); static int nfs4_do_fsinfo(struct nfs_server *, struct nfs_fh *, struct nfs_fsinfo *); -static int nfs4_async_handle_error(struct rpc_task *, const struct nfs_server *, struct nfs4_state *, long *); +static int nfs4_async_handle_error(struct rpc_task *, struct nfs_server *, struct nfs4_state *, long *); static void nfs_fixup_referral_attributes(struct nfs_fattr *fattr); static int nfs4_proc_getattr(struct nfs_server *, struct nfs_fh *, struct nfs_fattr *, struct nfs4_label *label); static int _nfs4_proc_getattr(struct nfs_server *server, struct nfs_fh *fhandle, struct nfs_fattr *fattr, struct nfs4_label *label); @@ -4956,7 +4956,7 @@ out: static int -nfs4_async_handle_error(struct rpc_task *task, const struct nfs_server *server, +nfs4_async_handle_error(struct rpc_task *task, struct nfs_server *server, struct nfs4_state *state, long *timeout) { struct nfs_client *clp = server->nfs_client; @@ -5530,7 +5530,7 @@ struct nfs4_unlockdata { struct nfs4_lock_state *lsp; struct nfs_open_context *ctx; struct file_lock fl; - const struct nfs_server *server; + struct nfs_server *server; unsigned long timestamp; }; diff --git a/include/linux/nfs_xdr.h b/include/linux/nfs_xdr.h index 52faf7e96c65..53f2acc68baf 100644 --- a/include/linux/nfs_xdr.h +++ b/include/linux/nfs_xdr.h @@ -528,7 +528,7 @@ struct nfs4_delegreturnargs { struct nfs4_delegreturnres { struct nfs4_sequence_res seq_res; struct nfs_fattr * fattr; - const struct nfs_server *server; + struct nfs_server *server; }; /* @@ -601,7 +601,7 @@ struct nfs_removeargs { struct nfs_removeres { struct nfs4_sequence_res seq_res; - const struct nfs_server *server; + struct nfs_server *server; struct nfs_fattr *dir_attr; struct nfs4_change_info cinfo; }; @@ -619,7 +619,7 @@ struct nfs_renameargs { struct nfs_renameres { struct nfs4_sequence_res seq_res; - const struct nfs_server *server; + struct nfs_server *server; struct nfs4_change_info old_cinfo; struct nfs_fattr *old_fattr; struct nfs4_change_info new_cinfo;