mirror of
https://github.com/torvalds/linux.git
synced 2025-12-07 20:06:24 +00:00
Btrfs: two stage dirty block group writeout
Block group cache writeout is currently waiting on the pages for each block group cache before moving on to writing the next one. This commit switches things around to send down all the caches and then wait on them in batches. The end result is much faster, since we're keeping the disk pipeline full. Signed-off-by: Chris Mason <clm@fb.com>
This commit is contained in:
@@ -1261,9 +1261,12 @@ struct btrfs_io_ctl {
|
||||
struct page *page;
|
||||
struct page **pages;
|
||||
struct btrfs_root *root;
|
||||
struct inode *inode;
|
||||
unsigned long size;
|
||||
int index;
|
||||
int num_pages;
|
||||
int entries;
|
||||
int bitmaps;
|
||||
unsigned check_crcs:1;
|
||||
};
|
||||
|
||||
@@ -1332,6 +1335,9 @@ struct btrfs_block_group_cache {
|
||||
|
||||
/* For dirty block groups */
|
||||
struct list_head dirty_list;
|
||||
struct list_head io_list;
|
||||
|
||||
struct btrfs_io_ctl io_ctl;
|
||||
};
|
||||
|
||||
/* delayed seq elem */
|
||||
|
||||
Reference in New Issue
Block a user