Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 298547
b: refs/heads/master
c: 5220ea1
h: refs/heads/master
i:
  298545: e5c33ed
  298543: a474db0
v: v3
  • Loading branch information
majianpeng authored and NeilBrown committed Apr 1, 2012
1 parent 8ca6a24 commit acb8aad
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 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: 0366ef847581d692e197b88825867ca9ee00e358
refs/heads/master: 5220ea1e640869e70f894837678315c878c651fd
8 changes: 7 additions & 1 deletion trunk/drivers/md/raid1.c
Original file line number Diff line number Diff line change
Expand Up @@ -2636,11 +2636,13 @@ static struct r1conf *setup_conf(struct mddev *mddev)
return ERR_PTR(err);
}

static int stop(struct mddev *mddev);
static int run(struct mddev *mddev)
{
struct r1conf *conf;
int i;
struct md_rdev *rdev;
int ret;

if (mddev->level != 1) {
printk(KERN_ERR "md/raid1:%s: raid level not set to mirroring (%d)\n",
Expand Down Expand Up @@ -2705,7 +2707,11 @@ static int run(struct mddev *mddev)
mddev->queue->backing_dev_info.congested_data = mddev;
blk_queue_merge_bvec(mddev->queue, raid1_mergeable_bvec);
}
return md_integrity_register(mddev);

ret = md_integrity_register(mddev);
if (ret)
stop(mddev);
return ret;
}

static int stop(struct mddev *mddev)
Expand Down

0 comments on commit acb8aad

Please sign in to comment.