diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-04-05 16:21:15 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-04-05 16:21:15 -0400 |
commit | 795d580baec0d5386b83a8b557df47c20810e86b (patch) | |
tree | d0387c37562e9e27a4f43cf7ae425319cbdad359 /fs/btrfs/disk-io.c | |
parent | 449cedf099b23a250e7d61982e35555ccb871182 (diff) | |
parent | 109f6aef5fc436f355ad027f4d97bd696df2049a (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable
* git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable:
Btrfs: add check for changed leaves in setup_leaf_for_split
Btrfs: create snapshot references in same commit as snapshot
Btrfs: fix small race with delalloc flushing waitqueue's
Btrfs: use add_to_page_cache_lru, use __page_cache_alloc
Btrfs: fix chunk allocate size calculation
Btrfs: kill max_extent mount option
Btrfs: fail to mount if we have problems reading the block groups
Btrfs: check btrfs_get_extent return for IS_ERR()
Btrfs: handle kmalloc() failure in inode lookup ioctl
Btrfs: dereferencing freed memory
Btrfs: Simplify num_stripes's calculation logical for __btrfs_alloc_chunk()
Btrfs: Add error handle for btrfs_search_slot() in btrfs_read_chunk_tree()
Btrfs: Remove unnecessary finish_wait() in wait_current_trans()
Btrfs: add NULL check for do_walk_down()
Btrfs: remove duplicate include in ioctl.c
Fix trivial conflict in fs/btrfs/compression.c due to slab.h include
cleanups.
Diffstat (limited to 'fs/btrfs/disk-io.c')
-rw-r--r-- | fs/btrfs/disk-io.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/fs/btrfs/disk-io.c b/fs/btrfs/disk-io.c index e57ded75d910..e7b8f2c89ccb 100644 --- a/fs/btrfs/disk-io.c +++ b/fs/btrfs/disk-io.c | |||
@@ -1635,7 +1635,6 @@ struct btrfs_root *open_ctree(struct super_block *sb, | |||
1635 | atomic_set(&fs_info->async_submit_draining, 0); | 1635 | atomic_set(&fs_info->async_submit_draining, 0); |
1636 | atomic_set(&fs_info->nr_async_bios, 0); | 1636 | atomic_set(&fs_info->nr_async_bios, 0); |
1637 | fs_info->sb = sb; | 1637 | fs_info->sb = sb; |
1638 | fs_info->max_extent = (u64)-1; | ||
1639 | fs_info->max_inline = 8192 * 1024; | 1638 | fs_info->max_inline = 8192 * 1024; |
1640 | fs_info->metadata_ratio = 0; | 1639 | fs_info->metadata_ratio = 0; |
1641 | 1640 | ||
@@ -1923,7 +1922,11 @@ struct btrfs_root *open_ctree(struct super_block *sb, | |||
1923 | 1922 | ||
1924 | csum_root->track_dirty = 1; | 1923 | csum_root->track_dirty = 1; |
1925 | 1924 | ||
1926 | btrfs_read_block_groups(extent_root); | 1925 | ret = btrfs_read_block_groups(extent_root); |
1926 | if (ret) { | ||
1927 | printk(KERN_ERR "Failed to read block groups: %d\n", ret); | ||
1928 | goto fail_block_groups; | ||
1929 | } | ||
1927 | 1930 | ||
1928 | fs_info->generation = generation; | 1931 | fs_info->generation = generation; |
1929 | fs_info->last_trans_committed = generation; | 1932 | fs_info->last_trans_committed = generation; |
@@ -1933,7 +1936,7 @@ struct btrfs_root *open_ctree(struct super_block *sb, | |||
1933 | fs_info->cleaner_kthread = kthread_run(cleaner_kthread, tree_root, | 1936 | fs_info->cleaner_kthread = kthread_run(cleaner_kthread, tree_root, |
1934 | "btrfs-cleaner"); | 1937 | "btrfs-cleaner"); |
1935 | if (IS_ERR(fs_info->cleaner_kthread)) | 1938 | if (IS_ERR(fs_info->cleaner_kthread)) |
1936 | goto fail_csum_root; | 1939 | goto fail_block_groups; |
1937 | 1940 | ||
1938 | fs_info->transaction_kthread = kthread_run(transaction_kthread, | 1941 | fs_info->transaction_kthread = kthread_run(transaction_kthread, |
1939 | tree_root, | 1942 | tree_root, |
@@ -2021,7 +2024,8 @@ fail_cleaner: | |||
2021 | filemap_write_and_wait(fs_info->btree_inode->i_mapping); | 2024 | filemap_write_and_wait(fs_info->btree_inode->i_mapping); |
2022 | invalidate_inode_pages2(fs_info->btree_inode->i_mapping); | 2025 | invalidate_inode_pages2(fs_info->btree_inode->i_mapping); |
2023 | 2026 | ||
2024 | fail_csum_root: | 2027 | fail_block_groups: |
2028 | btrfs_free_block_groups(fs_info); | ||
2025 | free_extent_buffer(csum_root->node); | 2029 | free_extent_buffer(csum_root->node); |
2026 | free_extent_buffer(csum_root->commit_root); | 2030 | free_extent_buffer(csum_root->commit_root); |
2027 | fail_dev_root: | 2031 | fail_dev_root: |