search for: test_gen

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

Did you mean: test2_gen
2013 Jan 10
0
[PATCH 02/11] Btrfs: use atomic for fs_info->last_trans_committed
...diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c index 83186c7..e6c8eb2 100644 --- a/fs/btrfs/tree-log.c +++ b/fs/btrfs/tree-log.c @@ -3392,7 +3392,7 @@ static int btrfs_log_changed_extents(struct btrfs_trans_handle *trans, INIT_LIST_HEAD(&extents); write_lock(&tree->lock); - test_gen = root->fs_info->last_trans_committed; + test_gen = atomic64_read(&root->fs_info->last_trans_committed); list_for_each_entry_safe(em, n, &tree->modified_extents, list) { list_del_init(&em->list); @@ -3496,7 +3496,8 @@ static int btrfs_log_inode(struct btrfs_tran...
2012 Sep 17
0
[PATCH] Btrfs: do not hold the write_lock on the extent tree while logging V2
...e; diff --git a/fs/btrfs/tree-log.c b/fs/btrfs/tree-log.c index 038a522..a3e88cf 100644 --- a/fs/btrfs/tree-log.c +++ b/fs/btrfs/tree-log.c @@ -2945,6 +2945,9 @@ static int btrfs_log_changed_extents(struct btrfs_trans_handle *trans, list_del_init(&em->list); if (em->generation <= test_gen) continue; + /* Need a ref to keep it from getting evicted from cache */ + atomic_inc(&em->refs); + set_bit(EXTENT_FLAG_LOGGING, &em->flags); list_add_tail(&em->list, &extents); } @@ -2954,13 +2957,18 @@ static int btrfs_log_changed_extents(struct btrfs_trans_...