btrfs: move fiemap code into its own file
authorFilipe Manana <fdmanana@suse.com>
Wed, 22 May 2024 14:29:05 +0000 (15:29 +0100)
committerDavid Sterba <dsterba@suse.com>
Thu, 11 Jul 2024 13:33:20 +0000 (15:33 +0200)
commit8996f61ab9ff06a1433a58dd67ea0bf6f91ba499
tree871130df1c5f9dba86bf11d8b82f0bf4d4587cfc
parentf9763e4d150f22b18e79f1ef7ad2bee0059d02ff
btrfs: move fiemap code into its own file

Currently the core of the fiemap code lives in extent_io.c, which does
not make any sense because it's not related to extent IO at all (and it
was not as well before the big rewrite of fiemap I did some time ago).
The entry point for fiemap, btrfs_fiemap(), lives in inode.c since it's
an inode operation.

Since there's a significant amount of fiemap code, move all of it into a
dedicated file, including its entry point inode.c:btrfs_fiemap().

Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com>
Signed-off-by: Filipe Manana <fdmanana@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/Makefile
fs/btrfs/extent_io.c
fs/btrfs/extent_io.h
fs/btrfs/fiemap.c [new file with mode: 0644]
fs/btrfs/fiemap.h [new file with mode: 0644]
fs/btrfs/inode.c