All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dave Chinner <david@fromorbit.com>
To: Gao Xiang <hsiangkao@redhat.com>
Cc: linux-xfs@vger.kernel.org
Subject: Re: [PATCH 3/4] xfs: track unlinked inodes in core inode
Date: Thu, 2 Jul 2020 08:06:25 +1000	[thread overview]
Message-ID: <20200701220625.GV2005@dread.disaster.area> (raw)
In-Reply-To: <20200701085904.GB10152@xiangao.remote.csb>

On Wed, Jul 01, 2020 at 04:59:04PM +0800, Gao Xiang wrote:
> On Tue, Jun 23, 2020 at 07:50:14PM +1000, Dave Chinner wrote:
> 
> ...
> 
> > +static struct xfs_inode *
> > +xfs_iunlink_ilookup(
> >  	struct xfs_perag	*pag,
> >  	xfs_agino_t		agino)
> >  {
> > -	struct xfs_iunlink	*iu;
> > +	struct xfs_mount	*mp = pag->pag_mount;
> > +	struct xfs_inode	*ip;
> >  
> > -	iu = rhashtable_lookup_fast(&pag->pagi_unlinked_hash, &agino,
> > -			xfs_iunlink_hash_params);
> 
> Just notice that when working on this patchset. Since pagi_unlinked_hash
> is unused now, let's kill pagi_unlinked_hash in xfs_perag as well.
> 
> typedef struct xfs_perag {
> ...
> struct rhashtable       pagi_unlinked_hash;
> ...
> };

Good catch. I'll remove that for the next iteration.

> Also I noticed xfs_iunlink_insert_inode and xfs_iunlink_remove_inode
> are used once now, maybe folding into the caller would be better...
> (Just my personal thought...)

I used them to make it obvious what operation was being performed on
the unlinked list. In the end they might be simple enough to remove,
but when I first wrote this patch is was necessary to document what
operations were being performed by the code rather than it just
being a big tangle of spagetti...

Cheers,

Dave.
-- 
Dave Chinner
david@fromorbit.com

  reply	other threads:[~2020-07-01 22:06 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-23  9:50 [PATCH 0/4] [RFC] xfs: in memory inode unlink log items Dave Chinner
2020-06-23  9:50 ` [PATCH 1/4] xfs: xfs_iflock is no longer a completion Dave Chinner
2020-06-24 15:36   ` Brian Foster
2020-07-01  5:48     ` Dave Chinner
2020-06-23  9:50 ` [PATCH 2/4] xfs: add log item precommit operation Dave Chinner
2020-06-30 18:06   ` Darrick J. Wong
2020-07-01 14:30   ` Brian Foster
2020-07-01 22:02     ` Dave Chinner
2020-06-23  9:50 ` [PATCH 3/4] xfs: track unlinked inodes in core inode Dave Chinner
2020-07-01  8:59   ` Gao Xiang
2020-07-01 22:06     ` Dave Chinner [this message]
2020-07-01 14:31   ` Brian Foster
2020-07-01 22:18     ` Dave Chinner
2020-07-02 12:24       ` Brian Foster
2020-07-07 14:39   ` Gao Xiang
2020-06-23  9:50 ` [PATCH 4/4] xfs: introduce inode unlink log item Dave Chinner
2020-06-30 18:19   ` Darrick J. Wong
2020-06-30 22:31     ` Gao Xiang
2020-07-01  6:26       ` Dave Chinner
2020-07-01 14:32   ` Brian Foster
2020-07-01 22:24     ` Dave Chinner
2020-07-02 12:25       ` Brian Foster

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=20200701220625.GV2005@dread.disaster.area \
    --to=david@fromorbit.com \
    --cc=hsiangkao@redhat.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 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.