]> www.infradead.org Git - users/jedix/linux-maple.git/commit
btrfs: introduce RAID1 round-robin read balancing
authorAnand Jain <anand.jain@oracle.com>
Wed, 1 Jan 2025 18:06:35 +0000 (02:06 +0800)
committerDavid Sterba <dsterba@suse.com>
Mon, 13 Jan 2025 13:53:21 +0000 (14:53 +0100)
commit6d7a9154955e50c0b991063c65f86ab24796754e
treef9f5ccb0b13579644925944905aa0ed7884bc4e1
parent22fb0d99c90583e5b32a2a54e614bce221d31a8a
btrfs: introduce RAID1 round-robin read balancing

Add round-robin read policy that balances reads over available devices
(all RAID1 block group profiles). Switch to the next devices is done
after a number of blocks is read, which is 256K by default and is
configurable in sysfs.

The format is "round-robin:<min-contig-read>" and can be set in file

  /sys/fs/btrfs/FSID/read_policy

Signed-off-by: Anand Jain <anand.jain@oracle.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/sysfs.c
fs/btrfs/volumes.c
fs/btrfs/volumes.h