All of lore.kernel.org
 help / color / mirror / Atom feed
From: Brian Foster <bfoster@redhat.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: linux-xfs@vger.kernel.org, Dave Chinner <david@fromorbit.com>
Subject: Re: [PATCH v2 1/3] xfs: add bmapi nodiscard flag
Date: Wed, 9 May 2018 08:47:56 -0400	[thread overview]
Message-ID: <20180509124756.GB65322@bfoster.bfoster> (raw)
In-Reply-To: <20180509120738.GA1050@infradead.org>

On Wed, May 09, 2018 at 05:07:38AM -0700, Christoph Hellwig wrote:
> On Wed, May 09, 2018 at 08:01:51AM -0400, Brian Foster wrote:
> > > self-documenting, very much unlike a 'true' or 'false' argument.
> > 
> > I'm fine with replacing the bool argument(s) with flags where applicable
> > if we do eliminate the wrappers. I'm just hesitant to change it given
> > the previous feedback to move away from something very close..
> > 
> > Dave, care to chime in here? As mentioned, I'll do a refactored v3 if
> > there's some kind of consensus/agreement on a final approach.
> 
> I've read the thread on the original patch now.  While not my preference
> I'm fine with doing an xfs_itruncate_extents_flags with a single
> xfs_itruncate_extents wrapper and the same for bmapi, as long as we pass
> flags instead of the bool, and don't add pointless wrappers for the
> nodiscard case - those are just trickle down flags in general, so we
> should keep things as simple as possible.

Ok, do you mean to include xfs_free_extent() in that as well? E.g.,
xfs_free_extent_flags(..., XFS_EXTENT_BUSY_SKIP_DISCARD) vs. a single
wrapper without _flags()? Note that that flag is still sourced from a
boolean unless we also change the xfs_extent_free_item field, which I'm
not sure makes sense. Alternatively, I could just kill the
xfs_free_extent_nodiscard() wrapper and call the internal variant from
the one place that wants to toggle discard behavior.

Brian

> --
> To unsubscribe from this list: send the line "unsubscribe linux-xfs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2018-05-09 12:47 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-05-08 17:22 [PATCH v2 0/3] xfs: skip unnecessary discards Brian Foster
2018-05-08 17:22 ` [PATCH v2 1/3] xfs: add bmapi nodiscard flag Brian Foster
2018-05-08 18:12   ` Darrick J. Wong
2018-05-09  1:28     ` Darrick J. Wong
2018-05-09 10:56       ` Brian Foster
2018-05-09  7:46   ` Christoph Hellwig
2018-05-09 10:58     ` Brian Foster
2018-05-09 11:39       ` Christoph Hellwig
2018-05-09 12:01         ` Brian Foster
2018-05-09 12:07           ` Christoph Hellwig
2018-05-09 12:47             ` Brian Foster [this message]
2018-05-10  8:25               ` Christoph Hellwig
2018-05-08 17:22 ` [PATCH v2 2/3] xfs: skip online discard during eofblocks trims Brian Foster
2018-05-08 18:14   ` Darrick J. Wong
2018-05-09  7:40   ` Christoph Hellwig
2018-05-08 17:22 ` [PATCH v2 3/3] xfs: don't discard on free of unwritten extents Brian Foster
2018-05-08 18:14   ` Darrick J. Wong
2018-05-09  7:40   ` Christoph Hellwig

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=20180509124756.GB65322@bfoster.bfoster \
    --to=bfoster@redhat.com \
    --cc=david@fromorbit.com \
    --cc=hch@infradead.org \
    --cc=linux-xfs@vger.kernel.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.