public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: "Darrick J. Wong" <darrick.wong@oracle.com>
Cc: Carlos Maiolino <cmaiolino@redhat.com>, linux-xfs@vger.kernel.org
Subject: Re: [PATCH 0/4] Buffer's log item refactoring
Date: Sat, 20 Jan 2018 15:54:37 +1100	[thread overview]
Message-ID: <20180120045437.GN6304@dastard> (raw)
In-Reply-To: <20180119214341.GK25805@magnolia>

On Fri, Jan 19, 2018 at 01:43:41PM -0800, Darrick J. Wong wrote:
> On Fri, Jan 19, 2018 at 03:08:43PM +0100, Carlos Maiolino wrote:
> > Hi,
> > 
> > A few time ago Christoph suggested to use list_head API to handle buffer's
> > log_item_list.
> > 
> > This patchset aims to split the current bp->b_fspriv field into a specific field
> > to hold the xfs_buf_log_item, and another to hold the list of log items attached
> > to the buffer (3rd patch), and finally replace the singly linked list
> > implementation by the list_head infra-structure (4th patch).
> > 
> > The first two patches are just a typedef removal of xfs_buf_log_item_t and
> > xfs_buf_t, I did while studying how all the buffer I/O mechanism works, I
> > thought since we plan to get rid of the typedefs in future, this might be
> > useful.
> > 
> > I can rebase the 3rd and 4th patch on top of current xfs tree if the typedef
> > removal patches are useless, you guys call.
> 
> Typedef removal seems useful... is this series based atop current for-next?

The reason we haven't done this sort of thing in the past is that it
causes problems for people with work under development that touches
the same code. Changes like this have knock-on effects, and they are
not necessary for the changes to the li_bio_list that the last two
patches provide.

e.g. This is going to cause me pain, because I've got lots of
modifications to xfs_buf related code pending in my dev tree. A
quick glance shows a >50% hunk conflict rate across all the changes
in my tree, and that's just the kernel side.  It's hard enough to
rebase deep patch stacks correctly without having to deal with the
noise introduced by this sort of tree-wide code cleanup....

The historic process is that we remove typedefs as we go, and when
there are relatively few of them left we can do a sweep. The
xfs_buf_log_item_t is at that threshold (only about 10 uses left).

However, there's ~150 xfs_buf_t references across the kernel code
base, and there's another 175 across the xfsprogs code base of which
only 40 are in the shared libxfs code (i.e. ~300 unique xfs_buf_t
references). IMO it's still used in far to much code to do a sweep
like this without making a lot of otherwise unnecessary work for
others...

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

  reply	other threads:[~2018-01-20  4:54 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-19 14:08 [PATCH 0/4] Buffer's log item refactoring Carlos Maiolino
2018-01-19 14:08 ` [PATCH 1/4] Get rid of xfs_buf_log_item_t typedef Carlos Maiolino
2018-01-20  3:33   ` Darrick J. Wong
2018-01-19 14:08 ` [PATCH 2/4] Get rid of xfs_buf_t typedef Carlos Maiolino
2018-01-20  3:35   ` Darrick J. Wong
2018-01-19 14:08 ` [PATCH 3/4] Split buffer's b_fspriv field Carlos Maiolino
2018-01-19 14:08 ` [PATCH 4/4] Use list_head infra-structure for buffer's log items list Carlos Maiolino
2018-01-19 18:21   ` Darrick J. Wong
2018-01-19 18:50     ` Carlos Maiolino
2018-01-23 10:19   ` Nikolay Borisov
2018-01-23 13:05     ` Carlos Maiolino
2018-01-23 14:55       ` Nikolay Borisov
2018-01-23 18:10         ` Darrick J. Wong
2018-01-24  8:44           ` Carlos Maiolino
2018-01-19 21:43 ` [PATCH 0/4] Buffer's log item refactoring Darrick J. Wong
2018-01-20  4:54   ` Dave Chinner [this message]
2018-01-22 11:39     ` Carlos Maiolino
2018-01-22 21:42       ` Darrick J. Wong
2018-01-23  8:39         ` 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=20180120045437.GN6304@dastard \
    --to=david@fromorbit.com \
    --cc=cmaiolino@redhat.com \
    --cc=darrick.wong@oracle.com \
    --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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox