Skip to content

Commit

Permalink
bcache: Set ra_pages based on backing device's ra_pages
Browse files Browse the repository at this point in the history
Signed-off-by: Kent Overstreet <koverstreet@google.com>
  • Loading branch information
Kent Overstreet committed Apr 21, 2013
1 parent 2903381 commit 4f0fd95
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions drivers/md/bcache/super.c
Original file line number Diff line number Diff line change
Expand Up @@ -1067,6 +1067,10 @@ static const char *register_bdev(struct cache_sb *sb, struct page *sb_page,

set_capacity(g, dc->bdev->bd_part->nr_sects - dc->sb.data_offset);

g->queue->backing_dev_info.ra_pages =
max(g->queue->backing_dev_info.ra_pages,
bdev->bd_queue->backing_dev_info.ra_pages);

bch_cached_dev_request_init(dc);

err = "error creating kobject";
Expand Down

0 comments on commit 4f0fd95

Please sign in to comment.