From cb4b0e34fd71db0b8cb286c83004bfc9a499f3dc Mon Sep 17 00:00:00 2001 From: Eric Sesterhenn Date: Sun, 2 Apr 2006 13:34:29 +0200 Subject: [PATCH] --- yaml --- r: 25214 b: refs/heads/master c: b6385483840e903d99cb753593faea215ae8d324 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/drivers/md/raid10.c | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/[refs] b/[refs] index d8cdf04353e1..a9b181192532 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 43dab9bbe9fda735589f2749004f639349966b20 +refs/heads/master: b6385483840e903d99cb753593faea215ae8d324 diff --git a/trunk/drivers/md/raid10.c b/trunk/drivers/md/raid10.c index ab90a6d12020..617012bc107a 100644 --- a/trunk/drivers/md/raid10.c +++ b/trunk/drivers/md/raid10.c @@ -1117,8 +1117,7 @@ static int end_sync_read(struct bio *bio, unsigned int bytes_done, int error) for (i=0; icopies; i++) if (r10_bio->devs[i].bio == bio) break; - if (i == conf->copies) - BUG(); + BUG_ON(i == conf->copies); update_head_pos(i, r10_bio); d = r10_bio->devs[i].devnum; @@ -1518,8 +1517,7 @@ static int init_resync(conf_t *conf) int buffs; buffs = RESYNC_WINDOW / RESYNC_BLOCK_SIZE; - if (conf->r10buf_pool) - BUG(); + BUG_ON(conf->r10buf_pool); conf->r10buf_pool = mempool_create(buffs, r10buf_pool_alloc, r10buf_pool_free, conf); if (!conf->r10buf_pool) return -ENOMEM;