diff options
author | Qu Wenruo <wqu@suse.com> | 2020-06-24 18:02:47 +0200 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2020-09-07 20:57:27 -0400 |
commit | 3b4b40c0d6c02c9a4adc684cf125f628651caf4c (patch) | |
tree | 5667bde25b859eb2dbea7568fac3a869e2d0e604 /fs/btrfs/inode.c | |
parent | 314b9b4a38befd120ce1c566d9eea8e0ec9d8336 (diff) |
fs: btrfs: Sync btrfs_btree.h from kernel
This version includes all needed on-disk format from kernel.
Only need to modify the include headers for U-Boot, everything else is
untouched.
Also, since U-Boot btrfs is using a different endian convert timing (at
tree block read time), it needs some forced type conversion before
proper crossport.
Signed-off-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: Marek BehĂșn <marek.behun@nic.cz>
Diffstat (limited to 'fs/btrfs/inode.c')
-rw-r--r-- | fs/btrfs/inode.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/fs/btrfs/inode.c b/fs/btrfs/inode.c index 991c2f68c3b..d88ae67217b 100644 --- a/fs/btrfs/inode.c +++ b/fs/btrfs/inode.c @@ -29,7 +29,7 @@ u64 btrfs_lookup_inode_ref(struct btrfs_root *root, u64 inr, *refp = *ref; if (name) { - if (ref->name_len > BTRFS_NAME_MAX) { + if (ref->name_len > BTRFS_NAME_LEN) { printf("%s: inode name too long: %u\n", __func__, ref->name_len); goto out; @@ -255,7 +255,8 @@ u64 btrfs_lookup_path(struct btrfs_root *root, u64 inr, const char *path, type = item.type; have_inode = 1; - if (btrfs_lookup_inode(root, &item.location, &inode_item, root)) + if (btrfs_lookup_inode(root, (struct btrfs_key *)&item.location, + &inode_item, root)) return -1ULL; if (item.type == BTRFS_FT_SYMLINK && symlink_limit >= 0) { |