diff options
author | NeilBrown <neilb@suse.de> | 2010-10-27 08:16:40 +0400 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2010-10-28 10:36:11 +0400 |
commit | 2b193363ef68667ad717a6723165e0dccf99470f (patch) | |
tree | bd45d5186f0edf2b546c4503d794b479d126ad1f /drivers/md/md.c | |
parent | 1c4588e9c19cae6209a28c9da2f16a18a610b935 (diff) | |
download | linux-2b193363ef68667ad717a6723165e0dccf99470f.tar.xz |
md: change type of first arg to sync_page_io.
Currently sync_page_io takes a 'bdev'.
Every caller passes 'rdev->bdev'.
We will soon want another field out of the rdev in sync_page_io,
So just pass the rdev instead of the bdev out of it.
Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/md.c')
-rw-r--r-- | drivers/md/md.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/md/md.c b/drivers/md/md.c index 0b6fa2a1882a..3149bf33f1c5 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -721,8 +721,8 @@ static void bi_complete(struct bio *bio, int error) complete((struct completion*)bio->bi_private); } -int sync_page_io(struct block_device *bdev, sector_t sector, int size, - struct page *page, int rw) +int sync_page_io(mdk_rdev_t *rdev, sector_t sector, int size, + struct page *page, int rw) { struct bio *bio = bio_alloc(GFP_NOIO, 1); struct completion event; @@ -730,7 +730,7 @@ int sync_page_io(struct block_device *bdev, sector_t sector, int size, rw |= REQ_SYNC | REQ_UNPLUG; - bio->bi_bdev = bdev; + bio->bi_bdev = rdev->bdev; bio->bi_sector = sector; bio_add_page(bio, page, size, 0); init_completion(&event); @@ -756,7 +756,7 @@ static int read_disk_sb(mdk_rdev_t * rdev, int size) return 0; - if (!sync_page_io(rdev->bdev, rdev->sb_start, size, rdev->sb_page, READ)) + if (!sync_page_io(rdev, rdev->sb_start, size, rdev->sb_page, READ)) goto fail; rdev->sb_loaded = 1; return 0; |