aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2008-05-16 13:14:57 -0400
committerChris Mason <chris.mason@oracle.com>2008-09-25 11:04:03 -0400
commit6af5ac3c1aede574acde5fc477f1a1c876fb568e (patch)
tree16d49ecd1044e9e301c6f5ed170743d74df4259d /fs/btrfs
parent1c8cfcc1590d378c82ec75888f71e87fd26551e3 (diff)
Btrfs: Handle transid == 0 while opening devices
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r--fs/btrfs/volumes.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
index 501d23d3ebfd..3fbf0834e884 100644
--- a/fs/btrfs/volumes.c
+++ b/fs/btrfs/volumes.c
@@ -262,7 +262,7 @@ int btrfs_open_devices(struct btrfs_fs_devices *fs_devices,
262 goto error_brelse; 262 goto error_brelse;
263 263
264 transid = btrfs_super_generation(disk_super); 264 transid = btrfs_super_generation(disk_super);
265 if (transid > latest_transid) { 265 if (!latest_transid || transid > latest_transid) {
266 latest_devid = devid; 266 latest_devid = devid;
267 latest_transid = transid; 267 latest_transid = transid;
268 latest_bdev = bdev; 268 latest_bdev = bdev;