diff options
author | Anand Jain <anand.jain@oracle.com> | 2023-04-15 17:51:23 +0800 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2023-06-19 13:59:23 +0200 |
commit | 29e70be261d92829af26fda16769784710f45503 (patch) | |
tree | 2fc9eccf7c573d2eabf3a931219718fe55999ed8 /fs/btrfs/raid56.c | |
parent | eee3b811784e52f06ccb3e1c4518a9907627d4fe (diff) |
btrfs: use SECTOR_SHIFT to convert physical offset to LBA
Use SECTOR_SHIFT while converting a physical address to an LBA, makes
it more readable.
Signed-off-by: Anand Jain <anand.jain@oracle.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/raid56.c')
-rw-r--r-- | fs/btrfs/raid56.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/btrfs/raid56.c b/fs/btrfs/raid56.c index 2fab37f062de..d271c6e04dcc 100644 --- a/fs/btrfs/raid56.c +++ b/fs/btrfs/raid56.c @@ -1099,7 +1099,7 @@ static int rbio_add_io_sector(struct btrfs_raid_bio *rbio, bio = bio_alloc(stripe->dev->bdev, max(BTRFS_STRIPE_LEN >> PAGE_SHIFT, 1), op, GFP_NOFS); - bio->bi_iter.bi_sector = disk_start >> 9; + bio->bi_iter.bi_sector = disk_start >> SECTOR_SHIFT; bio->bi_private = rbio; __bio_add_page(bio, sector->page, sectorsize, sector->pgoff); |