diff options
author | David Sterba <dsterba@suse.com> | 2017-03-28 08:35:42 -0400 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2017-04-18 08:07:26 -0400 |
commit | bcc8e07f9ef1cb3a302bed1d41d27ca72eaacc33 (patch) | |
tree | 09bc61b5d4593ab3e54e55448ab76152853362f2 /fs/btrfs/ctree.c | |
parent | 176ef8f5e662a79471f437839cd9a0c5b95b1e8d (diff) |
btrfs: sink GFP flags parameter to tree_mod_log_insert_root
All (1) callers pass the same value.
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/ctree.c')
-rw-r--r-- | fs/btrfs/ctree.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/btrfs/ctree.c b/fs/btrfs/ctree.c index d034d47c5470..165e7ec12af7 100644 --- a/fs/btrfs/ctree.c +++ b/fs/btrfs/ctree.c | |||
@@ -663,7 +663,7 @@ __tree_mod_log_free_eb(struct btrfs_fs_info *fs_info, | |||
663 | static noinline int | 663 | static noinline int |
664 | tree_mod_log_insert_root(struct btrfs_fs_info *fs_info, | 664 | tree_mod_log_insert_root(struct btrfs_fs_info *fs_info, |
665 | struct extent_buffer *old_root, | 665 | struct extent_buffer *old_root, |
666 | struct extent_buffer *new_root, gfp_t flags, | 666 | struct extent_buffer *new_root, |
667 | int log_removal) | 667 | int log_removal) |
668 | { | 668 | { |
669 | struct tree_mod_elem *tm = NULL; | 669 | struct tree_mod_elem *tm = NULL; |
@@ -678,14 +678,14 @@ tree_mod_log_insert_root(struct btrfs_fs_info *fs_info, | |||
678 | if (log_removal && btrfs_header_level(old_root) > 0) { | 678 | if (log_removal && btrfs_header_level(old_root) > 0) { |
679 | nritems = btrfs_header_nritems(old_root); | 679 | nritems = btrfs_header_nritems(old_root); |
680 | tm_list = kcalloc(nritems, sizeof(struct tree_mod_elem *), | 680 | tm_list = kcalloc(nritems, sizeof(struct tree_mod_elem *), |
681 | flags); | 681 | GFP_NOFS); |
682 | if (!tm_list) { | 682 | if (!tm_list) { |
683 | ret = -ENOMEM; | 683 | ret = -ENOMEM; |
684 | goto free_tms; | 684 | goto free_tms; |
685 | } | 685 | } |
686 | for (i = 0; i < nritems; i++) { | 686 | for (i = 0; i < nritems; i++) { |
687 | tm_list[i] = alloc_tree_mod_elem(old_root, i, | 687 | tm_list[i] = alloc_tree_mod_elem(old_root, i, |
688 | MOD_LOG_KEY_REMOVE_WHILE_FREEING, flags); | 688 | MOD_LOG_KEY_REMOVE_WHILE_FREEING, GFP_NOFS); |
689 | if (!tm_list[i]) { | 689 | if (!tm_list[i]) { |
690 | ret = -ENOMEM; | 690 | ret = -ENOMEM; |
691 | goto free_tms; | 691 | goto free_tms; |
@@ -693,7 +693,7 @@ tree_mod_log_insert_root(struct btrfs_fs_info *fs_info, | |||
693 | } | 693 | } |
694 | } | 694 | } |
695 | 695 | ||
696 | tm = kzalloc(sizeof(*tm), flags); | 696 | tm = kzalloc(sizeof(*tm), GFP_NOFS); |
697 | if (!tm) { | 697 | if (!tm) { |
698 | ret = -ENOMEM; | 698 | ret = -ENOMEM; |
699 | goto free_tms; | 699 | goto free_tms; |
@@ -943,7 +943,7 @@ tree_mod_log_set_root_pointer(struct btrfs_root *root, | |||
943 | { | 943 | { |
944 | int ret; | 944 | int ret; |
945 | ret = tree_mod_log_insert_root(root->fs_info, root->node, | 945 | ret = tree_mod_log_insert_root(root->fs_info, root->node, |
946 | new_root_node, GFP_NOFS, log_removal); | 946 | new_root_node, log_removal); |
947 | BUG_ON(ret < 0); | 947 | BUG_ON(ret < 0); |
948 | } | 948 | } |
949 | 949 | ||