diff options
author | Chris Mason <chris.mason@oracle.com> | 2007-03-14 14:14:43 -0400 |
---|---|---|
committer | David Woodhouse <dwmw2@hera.kernel.org> | 2007-03-14 14:14:43 -0400 |
commit | 123abc88c9087b9c5605566ee3491aaef17fd837 (patch) | |
tree | 3a8e83ac7a095d2b875664ee54cf7e24e977999b /fs/btrfs/root-tree.c | |
parent | 4beb1b8b75a86373f6020103ab840448d14c8880 (diff) |
Btrfs: variable block size support
Signed-off-by: Chris Mason <chris.mason@oracle.com>
Diffstat (limited to 'fs/btrfs/root-tree.c')
-rw-r--r-- | fs/btrfs/root-tree.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/btrfs/root-tree.c b/fs/btrfs/root-tree.c index 0ab90cfea98f..03aa7c2c6336 100644 --- a/fs/btrfs/root-tree.c +++ b/fs/btrfs/root-tree.c | |||
@@ -31,7 +31,7 @@ int btrfs_find_last_root(struct btrfs_root *root, u64 objectid, | |||
31 | ret = 1; | 31 | ret = 1; |
32 | goto out; | 32 | goto out; |
33 | } | 33 | } |
34 | memcpy(item, l->data + btrfs_item_offset(l->items + slot), | 34 | memcpy(item, btrfs_item_ptr(l, slot, struct btrfs_root_item), |
35 | sizeof(*item)); | 35 | sizeof(*item)); |
36 | btrfs_disk_key_to_cpu(key, &l->items[slot].key); | 36 | btrfs_disk_key_to_cpu(key, &l->items[slot].key); |
37 | btrfs_release_path(root, &path); | 37 | btrfs_release_path(root, &path); |
@@ -55,7 +55,7 @@ int btrfs_update_root(struct btrfs_root *root, struct btrfs_key *key, | |||
55 | BUG_ON(ret != 0); | 55 | BUG_ON(ret != 0); |
56 | l = &path.nodes[0]->leaf; | 56 | l = &path.nodes[0]->leaf; |
57 | slot = path.slots[0]; | 57 | slot = path.slots[0]; |
58 | memcpy(l->data + btrfs_item_offset(l->items + slot), item, | 58 | memcpy(btrfs_item_ptr(l, slot, struct btrfs_root_item), item, |
59 | sizeof(*item)); | 59 | sizeof(*item)); |
60 | out: | 60 | out: |
61 | btrfs_release_path(root, &path); | 61 | btrfs_release_path(root, &path); |