linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Al Viro <viro-3bDd1+5oDREiFSDQTTA3OLVCufUGDwFn@public.gmane.org>
To: Ryusuke Konishi <ryusuke-sG5X7nlA6pw@public.gmane.org>
Cc: hch-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org,
	npiggin-tSWWG44O7X1aa/9Udqfwiw@public.gmane.org,
	konishi.ryusuke-Zyj7fXuS5i5L9jVzuh4AOg@public.gmane.org,
	linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-nilfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 0/6] nilfs2: remove own inode hash table
Date: Tue, 24 Aug 2010 17:42:16 +0100	[thread overview]
Message-ID: <20100824164216.GV31363@ZenIV.linux.org.uk> (raw)
In-Reply-To: <20100825.012012.179486471.ryusuke-sG5X7nlA6pw@public.gmane.org>

On Wed, Aug 25, 2010 at 01:20:12AM +0900, Ryusuke Konishi wrote:
> On Tue, 24 Aug 2010 11:32:14 -0400, Christoph Hellwig wrote:
> > On Tue, Aug 24, 2010 at 09:58:23PM +0900, Ryusuke Konishi wrote:
> > > Actually, I recently wrote a patchset to unify all super block
> > > instances on one device into one sb, which makes the inodes outlive
> > > superblock eliminable.
> > 
> > Yes, that's how we handle things everywhere, including btrfs with
> > it's subvolumes and snapshots.
> > 
> > > But the patchset has a problem that it cannot shrink a number of
> > > versions of namespace when unmounting all snapshots and a current time
> > > instance.
> > 
> > Can you explain the issue in more detail?
> 
> Ok, I'll try.
> 
> The current nilfs attaches each snapshot on a mountpoint, instead of
> making a sub directory like ".snap/xxx/" in a namespace.
> 
> In the patchset, I binded
> 
>  a) The root directory of the current filesystem onto sb->s_root and
>     mnt->mnt_root.
> 
>  b) The root directory of each snapshot onto its mnt->mnt_root.
> 
> Then,
> 
> When I unmounted all snapshots and current filesystem,
> nilfs_put_super() was called, but
> 
> generic_shutdown_super() only shrunk the dentry tree of sb->s_root and
> didn't shrink dentry trees of snapshots.
> 
> Thus their inodes and dentries were left in memory despite my
> intention.
> 
> So, my implementation issue here is how to free dentries and inodes of
> snapshots like shrink_dcache_for_umount(sb) does for a single
> namespace.

Use d_obtain_alias() to allocate roots of unattached subtrees.
--
To unsubscribe from this list: send the line "unsubscribe linux-nilfs" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2010-08-24 16:42 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-22 10:05 [PATCH 0/6] nilfs2: remove own inode hash table Ryusuke Konishi
     [not found] ` <1282471506-29618-1-git-send-email-konishi.ryusuke-Zyj7fXuS5i5L9jVzuh4AOg@public.gmane.org>
2010-08-22 10:05   ` [PATCH 1/6] nilfs2: allow nilfs_destroy_inode to destroy metadata file inodes Ryusuke Konishi
2010-08-22 10:05   ` [PATCH 2/6] nilfs2: allow nilfs_dirty_inode to mark metadata file inodes dirty Ryusuke Konishi
2010-08-22 10:05   ` [PATCH 4/6] nilfs2: use iget5_locked to get inode Ryusuke Konishi
2010-08-22 10:05   ` [PATCH 6/6] nilfs2: remove own inode hash used for GC Ryusuke Konishi
2010-08-22 10:05 ` [PATCH 3/6] nilfs2: keep zero value in i_cno except for gc-inodes Ryusuke Konishi
2010-08-22 10:05 ` [PATCH 5/6] nilfs2: separate initializer of metadata file inode Ryusuke Konishi
2010-08-24  7:48 ` [PATCH 0/6] nilfs2: remove own inode hash table Nick Piggin
2010-08-24  8:30   ` Christoph Hellwig
     [not found]     ` <20100824083027.GA27594-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>
2010-08-24 12:58       ` Ryusuke Konishi
     [not found]         ` <20100824.215823.121933465.ryusuke-sG5X7nlA6pw@public.gmane.org>
2010-08-24 15:32           ` Christoph Hellwig
     [not found]             ` <20100824153214.GA25897-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>
2010-08-24 16:20               ` Ryusuke Konishi
     [not found]                 ` <20100825.012012.179486471.ryusuke-sG5X7nlA6pw@public.gmane.org>
2010-08-24 16:42                   ` Al Viro [this message]
2010-08-24 17:00                     ` Ryusuke Konishi
2010-08-24 12:19   ` Ryusuke Konishi
2010-08-24 12:58     ` Nick Piggin
2010-08-24 13:24     ` Al Viro
     [not found]       ` <20100824132453.GU31363-3bDd1+5oDREiFSDQTTA3OLVCufUGDwFn@public.gmane.org>
2010-08-24 15:39         ` Ryusuke Konishi

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=20100824164216.GV31363@ZenIV.linux.org.uk \
    --to=viro-3bdd1+5odreifsdqtta3olvcufugdwfn@public.gmane.org \
    --cc=hch-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org \
    --cc=konishi.ryusuke-Zyj7fXuS5i5L9jVzuh4AOg@public.gmane.org \
    --cc=linux-fsdevel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linux-nilfs-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=npiggin-tSWWG44O7X1aa/9Udqfwiw@public.gmane.org \
    --cc=ryusuke-sG5X7nlA6pw@public.gmane.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;
as well as URLs for NNTP newsgroup(s).