diff options
author | Qu Wenruo <wqu@suse.com> | 2021-10-08 10:29:59 +0300 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2021-10-26 20:08:06 +0300 |
commit | 47926ab535744d3a9156b8cf507edc77d210595f (patch) | |
tree | efe8b6297b3ae27073c54aefdcf0c411a8f96b9f /fs/btrfs/btrfs_inode.h | |
parent | 3dcfbcce1b8749a6e62be11c41a797c98ecc4127 (diff) | |
download | linux-47926ab535744d3a9156b8cf507edc77d210595f.tar.xz |
btrfs: rename btrfs_dio_private::logical_offset to file_offset
The naming of "logical_offset" can be confused with logical bytenr of
the dio range.
In fact it's file offset, and the naming "file_offset" is already widely
used in all other sites.
Just do the rename to avoid confusion.
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/btrfs_inode.h')
-rw-r--r-- | fs/btrfs/btrfs_inode.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/fs/btrfs/btrfs_inode.h b/fs/btrfs/btrfs_inode.h index 602b426c286d..ab2a4a52e0bb 100644 --- a/fs/btrfs/btrfs_inode.h +++ b/fs/btrfs/btrfs_inode.h @@ -356,7 +356,12 @@ static inline bool btrfs_inode_in_log(struct btrfs_inode *inode, u64 generation) struct btrfs_dio_private { struct inode *inode; - u64 logical_offset; + + /* + * Since DIO can use anonymous page, we cannot use page_offset() to + * grab the file offset, thus need a dedicated member for file offset. + */ + u64 file_offset; u64 disk_bytenr; /* Used for bio::bi_size */ u32 bytes; |