]> git.dujemihanovic.xyz Git - u-boot.git/commit
fs: btrfs: Implement btrfs_file_read()
authorQu Wenruo <wqu@suse.com>
Wed, 24 Jun 2020 16:03:11 +0000 (18:03 +0200)
committerTom Rini <trini@konsulko.com>
Tue, 8 Sep 2020 01:00:36 +0000 (21:00 -0400)
commite3427184f38a3a5d2ac9a3c200a5c3fc17592ec6
treeaa3021bacba25f9a905ad668ef8ad2136bdd7687
parent01347f64d5f86ae467141550f84ed0f97415a9ff
fs: btrfs: Implement btrfs_file_read()

This version of btrfs_file_read() has the following new features:
- Tries all mirrors
- More handling on unaligned size
- Better compressed extent handling
  The old implementation doesn't handle compressed extent with offset
  properly: we need to read out the whole compressed extent, then
  decompress the whole extent, and only then copy the requested part.

Signed-off-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: Marek BehĂșn <marek.behun@nic.cz>
fs/btrfs/btrfs.c
fs/btrfs/btrfs.h
fs/btrfs/inode.c