search for: clean_orphan

Displaying 2 results from an estimated 2 matches for "clean_orphan".

Did you mean: clean_orphans
2009 Nov 12
0
[PATCH 05/12] Btrfs: Avoid orphan inodes cleanup during replaying log
...extent_commit_sem; - struct rw_semaphore subvol_sem; + struct rw_semaphore cleanup_work_sem; + struct rw_semaphore subvol_sem; struct srcu_struct subvol_srcu; struct list_head trans_list; @@ -1034,12 +1035,12 @@ struct btrfs_root { int ref_cows; int track_dirty; int in_radix; + int clean_orphans; u64 defrag_trans_start; struct btrfs_key defrag_progress; struct btrfs_key defrag_max; int defrag_running; - int defrag_level; char *name; int in_sysfs; diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c index 0cf1781..e2ebc47 100644 --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-...
2010 Jan 15
0
[PATCH] Btrfs: fix regression in orphan cleanup
...440bab..f5d9384 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -3796,6 +3796,12 @@ struct inode *btrfs_lookup_dentry(struct inode *dir, struct dentry *dentry) if (location.type == BTRFS_INODE_ITEM_KEY) { inode = btrfs_iget(dir->i_sb, &location, root); + if (unlikely(root->clean_orphans) && + !(inode->i_sb->s_flags & MS_RDONLY)) { + down_read(&root->fs_info->cleanup_work_sem); + btrfs_orphan_cleanup(root); + up_read(&root->fs_info->cleanup_work_sem); + } return inode; } -- 1.5.4.3 -- To unsubscribe from this list: send th...