Re: Drop dcache entry after creating snapshot and subvolume

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, May 28, 2008 at 12:41:24AM +0200, Sven Wegener wrote:
> I have a patch (see below) that does an explicit d_drop() on the dentry 
> after looking it up via d_find_alias() and d_lookup(), starting at the root 
> inode. Currently it's for snapshot creation only, subvolume creation needs 
> the same. There doesn't seem to be a kernel function for this case and 
> using the normal d_revalidate method is inefficient as snapshot and 
> subvolume creation is the only place where we need this and the creation is 
> a rare case. Is this the right way to go?

I don't like this manual dropping very much.  Rather the snapshot should
be created using vfs_mkdir or equivalent opencoded bits that actually
turn the negative dentry into the real instanciated one.

Then again it might actually be better to have a separate superblock
for the snapshot to not get a too messy dentry tree, but before
commenting on that I need to actually dig into that area of btrfs again.
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux