public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Jeff Layton <jlayton@kernel.org>
Cc: Christoph Hellwig <hch@infradead.org>,
	"Darrick J. Wong" <darrick.wong@oracle.com>,
	linux-xfs@vger.kernel.org, Al Viro <viro@zeniv.linux.org.uk>
Subject: Re: [PATCH] xfs: Do not free xfs_extent_busy from inside a spinlock
Date: Tue, 23 Jul 2019 10:41:52 -0700	[thread overview]
Message-ID: <20190723174152.GA19405@infradead.org> (raw)
In-Reply-To: <70ea7252bc0cbfc99da7fde1ce58ddb92550885a.camel@kernel.org>

On Tue, Jul 23, 2019 at 01:38:08PM -0400, Jeff Layton wrote:
> Ahh ok, I get it now. You're using it as a generic "free this, no matter
> what it is" wrapper, and relying on the caller to ensure that it will
> never try to free a vmalloc'ed addr from an atomic context.
> 
> I wonder how many other places are doing that? I count 858 call sites
> for kvfree. If significant portion of those are doing this, then we may
> have to re-think my patch. It seems like the right thing to do, but we
> there may be more fallout than I expected.

For xfs we only have 4 direct callers of kmem_alloc_large, and 8 callers
of kmem_zalloc_large, so it they aren't too many, even assuming that due
to error handling we usually have a few more sites that free the
buffers.

  reply	other threads:[~2019-07-23 17:41 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-23 15:00 [PATCH] xfs: Do not free xfs_extent_busy from inside a spinlock Carlos Maiolino
2019-07-23 15:11 ` Darrick J. Wong
2019-07-23 15:31   ` Carlos Maiolino
2019-07-23 15:51     ` Christoph Hellwig
2019-07-23 17:07       ` Jeff Layton
2019-07-23 17:08         ` Christoph Hellwig
2019-07-23 17:38           ` Jeff Layton
2019-07-23 17:41             ` Christoph Hellwig [this message]
2019-07-23 15:13 ` Carlos Maiolino

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=20190723174152.GA19405@infradead.org \
    --to=hch@infradead.org \
    --cc=darrick.wong@oracle.com \
    --cc=jlayton@kernel.org \
    --cc=linux-xfs@vger.kernel.org \
    --cc=viro@zeniv.linux.org.uk \
    /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