Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 8325
b: refs/heads/master
c: ab904d6
h: refs/heads/master
i:
  8323: 5452ea2
v: v3
  • Loading branch information
NeilBrown authored and Linus Torvalds committed Sep 9, 2005
1 parent 5e5a11b commit c4db107
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 10 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 71c0805cb48462c99fbe0e5fcc6c12d7b9929c09
refs/heads/master: ab904d634625ef8dc590240b7ee06c7b724e636b
19 changes: 10 additions & 9 deletions trunk/drivers/md/bitmap.c
Original file line number Diff line number Diff line change
Expand Up @@ -270,19 +270,20 @@ static struct page *read_sb_page(mddev_t *mddev, long offset, unsigned long inde

if (!page)
return ERR_PTR(-ENOMEM);
do {
ITERATE_RDEV(mddev, rdev, tmp)
if (rdev->in_sync && !rdev->faulty)
goto found;
return ERR_PTR(-EIO);

found:
ITERATE_RDEV(mddev, rdev, tmp) {
if (! rdev->in_sync || rdev->faulty)
continue;

target = (rdev->sb_offset << 1) + offset + index * (PAGE_SIZE/512);

} while (!sync_page_io(rdev->bdev, target, PAGE_SIZE, page, READ));
if (sync_page_io(rdev->bdev, target, PAGE_SIZE, page, READ)) {
page->index = index;
return page;
}
}
return ERR_PTR(-EIO);

page->index = index;
return page;
}

static int write_sb_page(mddev_t *mddev, long offset, struct page *page, int wait)
Expand Down

0 comments on commit c4db107

Please sign in to comment.