From: Trond Myklebust <trondmy@hammerspace.com>
To: "vulab@iscas.ac.cn" <vulab@iscas.ac.cn>,
"linux-nfs@vger.kernel.org" <linux-nfs@vger.kernel.org>,
"anna.schumaker@netapp.com" <anna.schumaker@netapp.com>
Cc: "linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] nfs: pnfs: use GFP_ATOMIC under spin lock
Date: Mon, 29 Jun 2020 12:04:55 +0000 [thread overview]
Message-ID: <fd936b8622a9838070c58bc66e353f90e69347b1.camel@hammerspace.com> (raw)
In-Reply-To: <20200629062139.10364-1-vulab@iscas.ac.cn>
On Mon, 2020-06-29 at 14:21 +0800, Xu Wang wrote:
> A spin lock is taken here so we should use GFP_ATOMIC.
>
> Signed-off-by: Xu Wang <vulab@iscas.ac.cn>
> ---
> fs/nfs/pnfs.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/fs/nfs/pnfs.c b/fs/nfs/pnfs.c
> index dd2e14f5875d..d84c1b7b71d2 100644
> --- a/fs/nfs/pnfs.c
> +++ b/fs/nfs/pnfs.c
> @@ -2170,7 +2170,7 @@ _pnfs_grab_empty_layout(struct inode *ino,
> struct nfs_open_context *ctx)
> struct pnfs_layout_hdr *lo;
>
> spin_lock(&ino->i_lock);
> - lo = pnfs_find_alloc_layout(ino, ctx, GFP_KERNEL);
> + lo = pnfs_find_alloc_layout(ino, ctx, GFP_ATOMIC);
> if (!lo)
> goto out_unlock;
> if (!test_bit(NFS_LAYOUT_INVALID_STID, &lo->plh_flags))
NACK. Please read the code before sending yet another one of these
pointless patches.
--
Trond Myklebust
Linux NFS client maintainer, Hammerspace
trond.myklebust@hammerspace.com
parent reply other threads:[~2020-06-29 21:02 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <20200629062139.10364-1-vulab@iscas.ac.cn>]
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=fd936b8622a9838070c58bc66e353f90e69347b1.camel@hammerspace.com \
--to=trondmy@hammerspace.com \
--cc=anna.schumaker@netapp.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-nfs@vger.kernel.org \
--cc=vulab@iscas.ac.cn \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).