Received: by 2002:a05:7412:5112:b0:fa:6e18:a558 with SMTP id fm18csp1672240rdb; Thu, 25 Jan 2024 02:47:07 -0800 (PST) X-Google-Smtp-Source: AGHT+IGvg8MqbnFr3p2TzMr66Y8hxxfj50rKn3BgzvvJJmqHNU8dXfK2vhRBzrogXsbIgtlCzYWk X-Received: by 2002:a05:6a20:c744:b0:19a:3785:24f4 with SMTP id hj4-20020a056a20c74400b0019a378524f4mr479599pzb.111.1706179627043; Thu, 25 Jan 2024 02:47:07 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706179627; cv=pass; d=google.com; s=arc-20160816; b=Mwv4yIggO6ljwGAIbkK/wxfgAZNxWdSlbiQJsQRhtYggXmPEbjLjRRztrhtKwTQeo4 fBw82o9VDeea0ZQB56VRcNUJz47DrEJteruzAk5w2Rj1qJ0tfnQtNW1CKD0k3KHhn/+i VNtw+zq5gXoI5FWA8IipUUKNLjyXYHVNAPdsNpNoKGebYcZkCO2a+YpWjkmfDkZ3tb/v G4A8X2ynvRAPXOGYtmK2cNL+rao/P1m6V/qsYUFhARZ7FnjZdTYDhqVS3R5L7+WHJTqm tMt+E9POBCvE3WnRYjg7yHV1r+LhypnV1VyC+to/bK1IsJYvWnFv52Cy++Qme/kBF3dC wWbA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :subject:date:from:dkim-signature; bh=d9xTg3TILl1gpqVRgTxgJq5s4q96cwn/rLICCU82tf4=; fh=AED2lrIQZhdppGHbaRrNz6/BI48B+mbutB2egpFPmJc=; b=qHRgE2MMnCpDG1IaxlHijHuMWX3Zr0bQX+7n+wIgvvak3uvatLiCmehiSliskeBWsW J05arP4tTxH4b8qCTXMlCIIeJTSXqJB/PM0s0z47hM0b32+1oFvBhAfGpV9hgie9V1KK 4q3oN5Q4jwHxCL2t1jCS4tb0fqHGk00B1Jq4MtRqkDwLF1I9YYr3/bBqPj1dujCydOOg SqVlPbN9q3NVQ3nb42t3+8CgzIlAp4vWdrfYr04xGj2vsVim5Oru8/dUp34nDxYV1Ihc icX5QO2HZCCUHT0B8hEyG4FTqpVD69n6aC5fOYHsmoXSdMwzL+zz1F0TKLVhz9MqLNPk wqsw== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Z/x7+F75"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-nfs+bounces-1337-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-nfs+bounces-1337-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id w12-20020a17090a528c00b002903c13222fsi1076802pjh.189.2024.01.25.02.47.06 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Jan 2024 02:47:07 -0800 (PST) Received-SPF: pass (google.com: domain of linux-nfs+bounces-1337-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="Z/x7+F75"; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-nfs+bounces-1337-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-nfs+bounces-1337-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 6941E28BD56 for ; Thu, 25 Jan 2024 10:45:51 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id EFC0145025; Thu, 25 Jan 2024 10:43:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Z/x7+F75" X-Original-To: linux-nfs@vger.kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B629445C0E; Thu, 25 Jan 2024 10:43:30 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706179410; cv=none; b=IEQLJIuDBXLAbgHu0ynt7DAB1SC9/S4k9UgaJX2+Fr0nNR8bZJZnc9IMre3D5oVhlTX4VmCTaZKPQl62E04qzdO+OUyGjv0QfVjIfZEtH9k13m9h/Efqv7jiw7vkSXsC0WlRJANQ4Is4itF9uUhvONeW/XyuVm5jer6Joi98VnU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706179410; c=relaxed/simple; bh=/aGGER+GMEO8eWov6bTjUSIOjn2NGEHzheeD4QCJRlw=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=q3oSjrddmZUJn04orRvDgkLIc2ggpLafejVcZwf9BzGWsRLpvcgBxSR5BJWa2ql63GLvfBBrMZO5wpdIdDsoQBN+nyHhyXPAzWBl6Fp+2dRtmOjiwKmAsN21SkALl8ax2P0VoaT1+Uak5tmC35kj+J9ddVeMz6mlfo+dLEEk89w= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Z/x7+F75; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id B93AFC43330; Thu, 25 Jan 2024 10:43:26 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1706179410; bh=/aGGER+GMEO8eWov6bTjUSIOjn2NGEHzheeD4QCJRlw=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=Z/x7+F75frqr1HskUOX1iSsGtFsu18IICx1li/Ml6+hwnX+OnOJuRqrtRR0m7uEGW FGjrtOSSTgH93OMz7mbMmGkIR7DjjziQz1RXI1+zf+Mk8SdPZc+fe9LyYVzCDQr0wf RvdbfaPr5PHcxn/SrtmxSrGc8Q2SM64MWjeVKxi694oE4DDVabklS0uGAb9lV+gW+R YWqdHOPD21DJFlmjiQr5qOFoPG+QkFVl1Aprqfl4njfO9bBvYanQBiUEUCdZSUQ3R+ KzopgzRONHzJFC+vewKADMxxVLWtMT8v/mQjO8Hoa+uiFx56PEQGGFATgOa9bMqtxh vzyh8mhDwJlQw== From: Jeff Layton Date: Thu, 25 Jan 2024 05:42:45 -0500 Subject: [PATCH v2 04/41] nfs: rename fl_flags variable in nfs4_proc_unlck Precedence: bulk X-Mailing-List: linux-nfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240125-flsplit-v2-4-7485322b62c7@kernel.org> References: <20240125-flsplit-v2-0-7485322b62c7@kernel.org> In-Reply-To: <20240125-flsplit-v2-0-7485322b62c7@kernel.org> To: Christian Brauner , Alexander Viro , Eric Van Hensbergen , Latchesar Ionkov , Dominique Martinet , Christian Schoenebeck , David Howells , Marc Dionne , Xiubo Li , Ilya Dryomov , Alexander Aring , David Teigland , Miklos Szeredi , Andreas Gruenbacher , Trond Myklebust , Anna Schumaker , Chuck Lever , Neil Brown , Olga Kornievskaia , Dai Ngo , Tom Talpey , Jan Kara , Mark Fasheh , Joel Becker , Joseph Qi , Steve French , Paulo Alcantara , Shyam Prasad N , Namjae Jeon , Sergey Senozhatsky , Steven Rostedt , Masami Hiramatsu , Mathieu Desnoyers , Ronnie Sahlberg Cc: linux-kernel@vger.kernel.org, v9fs@lists.linux.dev, linux-afs@lists.infradead.org, ceph-devel@vger.kernel.org, gfs2@lists.linux.dev, linux-fsdevel@vger.kernel.org, linux-nfs@vger.kernel.org, ocfs2-devel@lists.linux.dev, linux-cifs@vger.kernel.org, linux-trace-kernel@vger.kernel.org, Jeff Layton X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=openpgp-sha256; l=4748; i=jlayton@kernel.org; h=from:subject:message-id; bh=/aGGER+GMEO8eWov6bTjUSIOjn2NGEHzheeD4QCJRlw=; b=kA0DAAgBAA5oQRlWghUByyZiAGWyOzqi7ZMXzgrKm/N+lZLoocUW4eO/WqZnPLzpRS2Zz2rf1 okCMwQAAQgAHRYhBEvA17JEcbKhhOr10wAOaEEZVoIVBQJlsjs6AAoJEAAOaEEZVoIV48oP/iXj 1O6BrMq4wC8YpWfdssDHR6/P2eubiLQ8EifjuKKGad9TuXe1gp4E/9x3iJwDUDyHbVVNPATxKVB yZmbxHIATN82k2ill85pZc+v4yl4Hz9mOLUBoyrnCo0+5tJDnY+7s+SnweJZCB064oVNGPUhPz4 4Xl7YaipjnItFAW4z8k7nHBTgnUjP9GTjOgzg/bMK8NuUV6Odvrki270Zf+KbJU/1Xlr4F/UcFd 6633uKGY+trZFWiJtRhtQtoJeCcHUuwwEvhGsD8pdX8H0bUYPS/+cBwFqJlra4XxdyQ9J9+EsAz dJe9V/RQXBlo93F+Vbhkr2SToUi5VB59Cc4hPzQZmp+3+LQjHPpuEsCB77sHFix6zhNoDd2WKyw EmDGJK8i4fYmJ085hj2j1Ou9gPW3vS7IoSKkSsYfUSZ3EcXAHsxpxJjqAzmNi3jNlVbKdnBIrOv XKnaGeoKxU0t80t1zLsdXmYlTERUidgZTJrPSjkvWjPk4lzS7REa3Bmi0ZZ2qpjLYuWCwCN77Qd K5P+XWRw8N92gWyHihFwj62Gc/qKHkTp3QZNFASl4G5XiAyBJ+nmlte1jY/lTQ7Ijvnzm0tWEnc ZXoxDYQpmypYUqKtlKG4Gmd1mR3KqVdeuhNJtxn1Rig9Ll8aoWcGWUZPfSgkGNdkQE5AWUyI5w4 8PYPQ X-Developer-Key: i=jlayton@kernel.org; a=openpgp; fpr=4BC0D7B24471B2A184EAF5D3000E684119568215 In later patches we're going to introduce some temporary macros with names that clash with the variable name here. Rename it. Signed-off-by: Jeff Layton --- fs/nfs/nfs4proc.c | 10 +++++----- fs/nfs/nfs4state.c | 16 ++++++++-------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 23819a756508..5dd936a403f9 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c @@ -7045,7 +7045,7 @@ static int nfs4_proc_unlck(struct nfs4_state *state, int cmd, struct file_lock * struct rpc_task *task; struct nfs_seqid *(*alloc_seqid)(struct nfs_seqid_counter *, gfp_t); int status = 0; - unsigned char fl_flags = request->fl_flags; + unsigned char saved_flags = request->fl_flags; status = nfs4_set_lock_state(state, request); /* Unlock _before_ we do the RPC call */ @@ -7080,7 +7080,7 @@ static int nfs4_proc_unlck(struct nfs4_state *state, int cmd, struct file_lock * status = rpc_wait_for_completion_task(task); rpc_put_task(task); out: - request->fl_flags = fl_flags; + request->fl_flags = saved_flags; trace_nfs4_unlock(request, state, F_SETLK, status); return status; } @@ -7398,7 +7398,7 @@ static int _nfs4_proc_setlk(struct nfs4_state *state, int cmd, struct file_lock { struct nfs_inode *nfsi = NFS_I(state->inode); struct nfs4_state_owner *sp = state->owner; - unsigned char fl_flags = request->fl_flags; + unsigned char flags = request->fl_flags; int status; request->fl_flags |= FL_ACCESS; @@ -7410,7 +7410,7 @@ static int _nfs4_proc_setlk(struct nfs4_state *state, int cmd, struct file_lock if (test_bit(NFS_DELEGATED_STATE, &state->flags)) { /* Yes: cache locks! */ /* ...but avoid races with delegation recall... */ - request->fl_flags = fl_flags & ~FL_SLEEP; + request->fl_flags = flags & ~FL_SLEEP; status = locks_lock_inode_wait(state->inode, request); up_read(&nfsi->rwsem); mutex_unlock(&sp->so_delegreturn_mutex); @@ -7420,7 +7420,7 @@ static int _nfs4_proc_setlk(struct nfs4_state *state, int cmd, struct file_lock mutex_unlock(&sp->so_delegreturn_mutex); status = _nfs4_do_setlk(state, cmd, request, NFS_LOCK_NEW); out: - request->fl_flags = fl_flags; + request->fl_flags = flags; return status; } diff --git a/fs/nfs/nfs4state.c b/fs/nfs/nfs4state.c index 9a5d911a7edc..471caf06fa7b 100644 --- a/fs/nfs/nfs4state.c +++ b/fs/nfs/nfs4state.c @@ -847,15 +847,15 @@ void nfs4_close_sync(struct nfs4_state *state, fmode_t fmode) */ static struct nfs4_lock_state * __nfs4_find_lock_state(struct nfs4_state *state, - fl_owner_t fl_owner, fl_owner_t fl_owner2) + fl_owner_t owner, fl_owner_t owner2) { struct nfs4_lock_state *pos, *ret = NULL; list_for_each_entry(pos, &state->lock_states, ls_locks) { - if (pos->ls_owner == fl_owner) { + if (pos->ls_owner == owner) { ret = pos; break; } - if (pos->ls_owner == fl_owner2) + if (pos->ls_owner == owner2) ret = pos; } if (ret) @@ -868,7 +868,7 @@ __nfs4_find_lock_state(struct nfs4_state *state, * exists, return an uninitialized one. * */ -static struct nfs4_lock_state *nfs4_alloc_lock_state(struct nfs4_state *state, fl_owner_t fl_owner) +static struct nfs4_lock_state *nfs4_alloc_lock_state(struct nfs4_state *state, fl_owner_t owner) { struct nfs4_lock_state *lsp; struct nfs_server *server = state->owner->so_server; @@ -879,7 +879,7 @@ static struct nfs4_lock_state *nfs4_alloc_lock_state(struct nfs4_state *state, f nfs4_init_seqid_counter(&lsp->ls_seqid); refcount_set(&lsp->ls_count, 1); lsp->ls_state = state; - lsp->ls_owner = fl_owner; + lsp->ls_owner = owner; lsp->ls_seqid.owner_id = ida_alloc(&server->lockowner_id, GFP_KERNEL_ACCOUNT); if (lsp->ls_seqid.owner_id < 0) goto out_free; @@ -993,7 +993,7 @@ static int nfs4_copy_lock_stateid(nfs4_stateid *dst, const struct nfs_lock_context *l_ctx) { struct nfs4_lock_state *lsp; - fl_owner_t fl_owner, fl_flock_owner; + fl_owner_t owner, fl_flock_owner; int ret = -ENOENT; if (l_ctx == NULL) @@ -1002,11 +1002,11 @@ static int nfs4_copy_lock_stateid(nfs4_stateid *dst, if (test_bit(LK_STATE_IN_USE, &state->flags) == 0) goto out; - fl_owner = l_ctx->lockowner; + owner = l_ctx->lockowner; fl_flock_owner = l_ctx->open_context->flock_owner; spin_lock(&state->state_lock); - lsp = __nfs4_find_lock_state(state, fl_owner, fl_flock_owner); + lsp = __nfs4_find_lock_state(state, owner, fl_flock_owner); if (lsp && test_bit(NFS_LOCK_LOST, &lsp->ls_flags)) ret = -EIO; else if (lsp != NULL && test_bit(NFS_LOCK_INITIALIZED, &lsp->ls_flags) != 0) { -- 2.43.0