Loading fs/btrfs/disk-io.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -154,7 +154,7 @@ static struct extent_map *btree_get_extent(struct inode *inode, } } read_unlock(&em_tree->lock); read_unlock(&em_tree->lock); em = alloc_extent_map(GFP_NOFS); em = alloc_extent_map(); if (!em) { if (!em) { em = ERR_PTR(-ENOMEM); em = ERR_PTR(-ENOMEM); goto out; goto out; Loading fs/btrfs/extent-tree.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -6694,7 +6694,7 @@ static noinline int relocate_data_extent(struct inode *reloc_inode, u64 start = extent_key->objectid - offset; u64 start = extent_key->objectid - offset; u64 end = start + extent_key->offset - 1; u64 end = start + extent_key->offset - 1; em = alloc_extent_map(GFP_NOFS); em = alloc_extent_map(); BUG_ON(!em); BUG_ON(!em); em->start = start; em->start = start; Loading fs/btrfs/extent_map.c +2 −3 Original line number Original line Diff line number Diff line Loading @@ -40,16 +40,15 @@ void extent_map_tree_init(struct extent_map_tree *tree) /** /** * alloc_extent_map - allocate new extent map structure * alloc_extent_map - allocate new extent map structure * @mask: memory allocation flags * * * Allocate a new extent_map structure. The new structure is * Allocate a new extent_map structure. The new structure is * returned with a reference count of one and needs to be * returned with a reference count of one and needs to be * freed using free_extent_map() * freed using free_extent_map() */ */ struct extent_map *alloc_extent_map(gfp_t mask) struct extent_map *alloc_extent_map(void) { { struct extent_map *em; struct extent_map *em; em = kmem_cache_alloc(extent_map_cache, mask); em = kmem_cache_alloc(extent_map_cache, GFP_NOFS); if (!em) if (!em) return NULL; return NULL; em->in_tree = 0; em->in_tree = 0; Loading fs/btrfs/extent_map.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -56,7 +56,7 @@ int add_extent_mapping(struct extent_map_tree *tree, struct extent_map *em); struct extent_map *em); int remove_extent_mapping(struct extent_map_tree *tree, struct extent_map *em); int remove_extent_mapping(struct extent_map_tree *tree, struct extent_map *em); struct extent_map *alloc_extent_map(gfp_t mask); struct extent_map *alloc_extent_map(void); void free_extent_map(struct extent_map *em); void free_extent_map(struct extent_map *em); int __init extent_map_init(void); int __init extent_map_init(void); void extent_map_exit(void); void extent_map_exit(void); Loading fs/btrfs/file.c +2 −2 Original line number Original line Diff line number Diff line Loading @@ -191,9 +191,9 @@ int btrfs_drop_extent_cache(struct inode *inode, u64 start, u64 end, } } while (1) { while (1) { if (!split) if (!split) split = alloc_extent_map(GFP_NOFS); split = alloc_extent_map(); if (!split2) if (!split2) split2 = alloc_extent_map(GFP_NOFS); split2 = alloc_extent_map(); BUG_ON(!split || !split2); BUG_ON(!split || !split2); write_lock(&em_tree->lock); write_lock(&em_tree->lock); Loading Loading
fs/btrfs/disk-io.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -154,7 +154,7 @@ static struct extent_map *btree_get_extent(struct inode *inode, } } read_unlock(&em_tree->lock); read_unlock(&em_tree->lock); em = alloc_extent_map(GFP_NOFS); em = alloc_extent_map(); if (!em) { if (!em) { em = ERR_PTR(-ENOMEM); em = ERR_PTR(-ENOMEM); goto out; goto out; Loading
fs/btrfs/extent-tree.c +1 −1 Original line number Original line Diff line number Diff line Loading @@ -6694,7 +6694,7 @@ static noinline int relocate_data_extent(struct inode *reloc_inode, u64 start = extent_key->objectid - offset; u64 start = extent_key->objectid - offset; u64 end = start + extent_key->offset - 1; u64 end = start + extent_key->offset - 1; em = alloc_extent_map(GFP_NOFS); em = alloc_extent_map(); BUG_ON(!em); BUG_ON(!em); em->start = start; em->start = start; Loading
fs/btrfs/extent_map.c +2 −3 Original line number Original line Diff line number Diff line Loading @@ -40,16 +40,15 @@ void extent_map_tree_init(struct extent_map_tree *tree) /** /** * alloc_extent_map - allocate new extent map structure * alloc_extent_map - allocate new extent map structure * @mask: memory allocation flags * * * Allocate a new extent_map structure. The new structure is * Allocate a new extent_map structure. The new structure is * returned with a reference count of one and needs to be * returned with a reference count of one and needs to be * freed using free_extent_map() * freed using free_extent_map() */ */ struct extent_map *alloc_extent_map(gfp_t mask) struct extent_map *alloc_extent_map(void) { { struct extent_map *em; struct extent_map *em; em = kmem_cache_alloc(extent_map_cache, mask); em = kmem_cache_alloc(extent_map_cache, GFP_NOFS); if (!em) if (!em) return NULL; return NULL; em->in_tree = 0; em->in_tree = 0; Loading
fs/btrfs/extent_map.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -56,7 +56,7 @@ int add_extent_mapping(struct extent_map_tree *tree, struct extent_map *em); struct extent_map *em); int remove_extent_mapping(struct extent_map_tree *tree, struct extent_map *em); int remove_extent_mapping(struct extent_map_tree *tree, struct extent_map *em); struct extent_map *alloc_extent_map(gfp_t mask); struct extent_map *alloc_extent_map(void); void free_extent_map(struct extent_map *em); void free_extent_map(struct extent_map *em); int __init extent_map_init(void); int __init extent_map_init(void); void extent_map_exit(void); void extent_map_exit(void); Loading
fs/btrfs/file.c +2 −2 Original line number Original line Diff line number Diff line Loading @@ -191,9 +191,9 @@ int btrfs_drop_extent_cache(struct inode *inode, u64 start, u64 end, } } while (1) { while (1) { if (!split) if (!split) split = alloc_extent_map(GFP_NOFS); split = alloc_extent_map(); if (!split2) if (!split2) split2 = alloc_extent_map(GFP_NOFS); split2 = alloc_extent_map(); BUG_ON(!split || !split2); BUG_ON(!split || !split2); write_lock(&em_tree->lock); write_lock(&em_tree->lock); Loading