summaryrefslogtreecommitdiff
path: root/fs/btrfs/props.c
diff options
context:
space:
mode:
authorQu Wenruo <wqu@suse.com>2023-03-23 12:01:20 +0300
committerDavid Sterba <dsterba@suse.com>2023-04-17 19:01:23 +0300
commit4317ff0056bedfc472202bf4ccf72d51094d6ade (patch)
tree20c0a72fddd86d452145fc913a763c2370747779 /fs/btrfs/props.c
parent2a2dc22f7e9df6daa9ab56e9b97855b3a0fbfc20 (diff)
downloadlinux-4317ff0056bedfc472202bf4ccf72d51094d6ade.tar.xz
btrfs: introduce btrfs_bio::fs_info member
Currently we're doing a lot of work for btrfs_bio: - Checksum verification for data read bios - Bio splits if it crosses stripe boundary - Read repair for data read bios However for the incoming scrub patches, we don't want this extra functionality at all, just plain logical + mirror -> physical mapping ability. Thus here we do the following changes: - Introduce btrfs_bio::fs_info This is for the new scrub specific btrfs_bio, which would not populate btrfs_bio::inode. Thus we need such new member to grab a fs_info This new member will always be populated. - Replace @inode argument with @fs_info for btrfs_bio_init() and its caller Since @inode is no longer a mandatory member, replace it with @fs_info, and let involved users populate @inode. - Skip checksum verification and generation if @bbio->inode is NULL - Add extra ASSERT()s To make sure: * bbio->inode is properly set for involved read repair path * if @file_offset is set, bbio->inode is also populated - Grab @fs_info from @bbio directly We can no longer go @bbio->inode->root->fs_info, as bbio->inode can be NULL. This involves: * btrfs_simple_end_io() * should_async_write() * btrfs_wq_submit_bio() * btrfs_use_zone_append() Signed-off-by: Qu Wenruo <wqu@suse.com> Reviewed-by: David Sterba <dsterba@suse.com> Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/props.c')
0 files changed, 0 insertions, 0 deletions