From patchwork Thu Jun 19 14:50:40 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jeff Layton X-Patchwork-Id: 4384491 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.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id BD69F9F390 for ; Thu, 19 Jun 2014 14:53:29 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id CAA0B20394 for ; Thu, 19 Jun 2014 14:53:28 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 0074220396 for ; Thu, 19 Jun 2014 14:53:27 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932760AbaFSOxV (ORCPT ); Thu, 19 Jun 2014 10:53:21 -0400 Received: from mail-qc0-f173.google.com ([209.85.216.173]:51096 "EHLO mail-qc0-f173.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932710AbaFSOxM (ORCPT ); Thu, 19 Jun 2014 10:53:12 -0400 Received: by mail-qc0-f173.google.com with SMTP id l6so2244857qcy.18 for ; Thu, 19 Jun 2014 07:53:11 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references; bh=1h5FuZcQoZxBr1nlxarC78GtkXTVAL4+ItXfhi/XhI4=; b=X5QFyle9Tc4LVjwMqdKNbrA0wTv86yP/Y8/eV39N5r39cDNCpGJ5X63b+pzFxMC8CW Z6ps0qPrq4VnU15+0R2R+InB3VUndDmr6YoI1jh2Qdik/qOpOqS6RjeqgKk2iDPKPXGC 0cp8aaws8QSh6n3l96cXlRAFKOqqhWNl0vwkvwLorEOW+lvMCfB4E6Lihx1nOfKpbSNu Njnm0aHf6NuEUwMxcSrHeC6v47yzPtK4mOr/mPqIQTMMnlmJESPNQMDS4PkWFwqKdmHV u4vyYPwl1aY2ZitCKAK4BhejUNQn1+nCgvz6/RJc4mi8DewUWQgFb1RQx3tDqJ0sTNuG ZjtQ== X-Gm-Message-State: ALoCoQnFBzXmiEjJ6w5GMim9RXcrlyVSe731VlGjb1JeHtCcRp8tIGg9KBt+aSbq+xHisbzjJgGE X-Received: by 10.224.68.2 with SMTP id t2mr7623513qai.71.1403189591920; Thu, 19 Jun 2014 07:53:11 -0700 (PDT) Received: from tlielax.poochiereds.net (cpe-107-015-124-230.nc.res.rr.com. [107.15.124.230]) by mx.google.com with ESMTPSA id r60sm3364044qgd.26.2014.06.19.07.53.10 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 19 Jun 2014 07:53:11 -0700 (PDT) From: Jeff Layton To: bfields@fieldses.org Cc: linux-nfs@vger.kernel.org Subject: [PATCH v1 094/104] NFSd: Remove nfs4_lock_state(): nfsd4_lock/locku/lockt() Date: Thu, 19 Jun 2014 10:50:40 -0400 Message-Id: <1403189450-18729-95-git-send-email-jlayton@primarydata.com> X-Mailer: git-send-email 1.9.3 In-Reply-To: <1403189450-18729-1-git-send-email-jlayton@primarydata.com> References: <1403189450-18729-1-git-send-email-jlayton@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 From: Trond Myklebust Signed-off-by: Trond Myklebust --- fs/nfsd/nfs4state.c | 9 --------- 1 file changed, 9 deletions(-) diff --git a/fs/nfsd/nfs4state.c b/fs/nfsd/nfs4state.c index 254ae3e7f8b6..ecb0623d33a6 100644 --- a/fs/nfsd/nfs4state.c +++ b/fs/nfsd/nfs4state.c @@ -5065,8 +5065,6 @@ nfsd4_lock(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, return status; } - nfs4_lock_state(); - if (lock->lk_is_new) { if (nfsd4_has_session(cstate)) /* See rfc 5661 18.10.3: given clientid is ignored: */ @@ -5204,7 +5202,6 @@ out: if (open_stp) put_generic_stateid(open_stp); nfsd4_bump_seqid(cstate, status); - nfs4_unlock_state(); if (file_lock) locks_free_lock(file_lock); if (conflock) @@ -5247,8 +5244,6 @@ nfsd4_lockt(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, if (check_lock_length(lockt->lt_offset, lockt->lt_length)) return nfserr_inval; - nfs4_lock_state(); - if (!nfsd4_has_session(cstate)) { status = lookup_clientid(&lockt->lt_clientid, cstate, nn); if (status) @@ -5302,7 +5297,6 @@ nfsd4_lockt(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, out: if (lo) nfs4_put_stateowner(&lo->lo_owner); - nfs4_unlock_state(); if (file_lock) locks_free_lock(file_lock); return status; @@ -5326,8 +5320,6 @@ nfsd4_locku(struct svc_rqst *rqstp, struct nfsd4_compound_state *cstate, if (check_lock_length(locku->lu_offset, locku->lu_length)) return nfserr_inval; - nfs4_lock_state(); - status = nfs4_preprocess_seqid_op(cstate, locku->lu_seqid, &locku->lu_stateid, NFS4_LOCK_STID, &stp, nn); @@ -5370,7 +5362,6 @@ put_stateid: put_generic_stateid(stp); out: nfsd4_bump_seqid(cstate, status); - nfs4_unlock_state(); if (file_lock) locks_free_lock(file_lock); return status;