aboutsummaryrefslogtreecommitdiffstats
path: root/fs/btrfs/inode-map.c
diff options
context:
space:
mode:
authorChris Mason <chris.mason@oracle.com>2007-03-22 12:13:20 -0400
committerDavid Woodhouse <dwmw2@hera.kernel.org>2007-03-22 12:13:20 -0400
commite20d96d64f9cf9288ffecc9ad4714e91c3b97ca8 (patch)
treefbe07d48bc7997226075169118ffa2a2e63f5d51 /fs/btrfs/inode-map.c
parent2e635a278354a1a7951e16cfea4c247d6d0e7c99 (diff)
Mountable btrfs, with readdir
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/inode-map.c')
-rw-r--r--fs/btrfs/inode-map.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/fs/btrfs/inode-map.c b/fs/btrfs/inode-map.c
index c7fda3bf7b21..c45aec258bd5 100644
--- a/fs/btrfs/inode-map.c
+++ b/fs/btrfs/inode-map.c
@@ -15,7 +15,7 @@ int btrfs_find_free_objectid(struct btrfs_trans_handle *trans,
15 int ret; 15 int ret;
16 u64 hole_size = 0; 16 u64 hole_size = 0;
17 int slot = 0; 17 int slot = 0;
18 u64 last_ino; 18 u64 last_ino = 0;
19 int start_found; 19 int start_found;
20 struct btrfs_leaf *l; 20 struct btrfs_leaf *l;
21 struct btrfs_root *root = fs_root->fs_info->inode_root; 21 struct btrfs_root *root = fs_root->fs_info->inode_root;
@@ -40,7 +40,7 @@ int btrfs_find_free_objectid(struct btrfs_trans_handle *trans,
40 path.slots[0]--; 40 path.slots[0]--;
41 41
42 while (1) { 42 while (1) {
43 l = &path.nodes[0]->leaf; 43 l = btrfs_buffer_leaf(path.nodes[0]);
44 slot = path.slots[0]; 44 slot = path.slots[0];
45 if (slot >= btrfs_header_nritems(&l->header)) { 45 if (slot >= btrfs_header_nritems(&l->header)) {
46 ret = btrfs_next_leaf(root, &path); 46 ret = btrfs_next_leaf(root, &path);
@@ -105,8 +105,8 @@ int btrfs_insert_inode_map(struct btrfs_trans_handle *trans,
105 if (ret) 105 if (ret)
106 goto out; 106 goto out;
107 107
108 inode_item = btrfs_item_ptr(&path.nodes[0]->leaf, path.slots[0], 108 inode_item = btrfs_item_ptr(btrfs_buffer_leaf(path.nodes[0]),
109 struct btrfs_inode_map_item); 109 path.slots[0], struct btrfs_inode_map_item);
110 btrfs_cpu_key_to_disk(&inode_item->key, location); 110 btrfs_cpu_key_to_disk(&inode_item->key, location);
111out: 111out:
112 btrfs_release_path(inode_root, &path); 112 btrfs_release_path(inode_root, &path);