Btrfs: btrfs_add_ordered_operation: Fix last modified transaction comparison.
authorchandan <chandan@linux.vnet.ibm.com>
Mon, 14 Oct 2013 13:14:39 +0000 (18:44 +0530)
committerChris Mason <chris.mason@fusionio.com>
Tue, 12 Nov 2013 03:01:37 +0000 (22:01 -0500)
Comparison of an inode's last modified transaction with the last committed
transaction is incorrect. Fix it.

Signed-off-by: chandan <chandan@linux.vnet.ibm.com>
Signed-off-by: Josef Bacik <jbacik@fusionio.com>
Signed-off-by: Chris Mason <chris.mason@fusionio.com>
fs/btrfs/ordered-data.c

index c702cb62f78a310c8d430fe0d98cfb1173479a0f..1a36a0c3ee27724d78646b60d3f44f722f78c07b 100644 (file)
@@ -1076,7 +1076,7 @@ void btrfs_add_ordered_operation(struct btrfs_trans_handle *trans,
         * if this file hasn't been changed since the last transaction
         * commit, we can safely return without doing anything
         */
-       if (last_mod < root->fs_info->last_trans_committed)
+       if (last_mod <= root->fs_info->last_trans_committed)
                return;
 
        spin_lock(&root->fs_info->ordered_root_lock);