From 540f138c0a2352d3abb3520ac2ba75086933fe9c Mon Sep 17 00:00:00 2001 From: Dan Williams Date: Sat, 28 Jun 2008 08:32:09 +1000 Subject: [PATCH] --- yaml --- r: 104255 b: refs/heads/master c: 7b3a871ed995270268a481404454ceafe1a87478 h: refs/heads/master i: 104253: 24ac891943ee69486ee36b71c7d6940d314290d5 104251: c41ea51f9cc3d68560fc9d89c4b2945f289642b7 104247: f56ce5b46fac59ab46c3d6b57f969c5e206a97d7 104239: 93ea5f1ecfd35ab45b69ee1fed39025b9dc74241 104223: a3b5d74b52e2e4b08b9f7809195d608b096a4f4b 104191: 48eb18563cd8036976572066f7d8429414f03158 v: v3 --- [refs] | 2 +- trunk/drivers/md/raid5.c | 15 +++++++-------- 2 files changed, 8 insertions(+), 9 deletions(-) diff --git a/[refs] b/[refs] index edd0114b4f71..206accb44eb8 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: d8ee0728b5b30d7a6f62c399a95e953616d31f23 +refs/heads/master: 7b3a871ed995270268a481404454ceafe1a87478 diff --git a/trunk/drivers/md/raid5.c b/trunk/drivers/md/raid5.c index c71246061c0e..456c3c2c961d 100644 --- a/trunk/drivers/md/raid5.c +++ b/trunk/drivers/md/raid5.c @@ -574,8 +574,7 @@ static void ops_complete_compute5(void *stripe_head_ref) release_stripe(sh); } -static struct dma_async_tx_descriptor * -ops_run_compute5(struct stripe_head *sh, unsigned long ops_request) +static struct dma_async_tx_descriptor *ops_run_compute5(struct stripe_head *sh) { /* kernel stack size limits the total number of disks */ int disks = sh->disks; @@ -605,10 +604,6 @@ ops_run_compute5(struct stripe_head *sh, unsigned long ops_request) ASYNC_TX_XOR_ZERO_DST, NULL, ops_complete_compute5, sh); - /* ack now if postxor is not set to be run */ - if (tx && !test_bit(STRIPE_OP_POSTXOR, &ops_request)) - async_tx_ack(tx); - return tx; } @@ -813,8 +808,12 @@ static void raid5_run_ops(struct stripe_head *sh, unsigned long ops_request) overlap_clear++; } - if (test_bit(STRIPE_OP_COMPUTE_BLK, &ops_request)) - tx = ops_run_compute5(sh, ops_request); + if (test_bit(STRIPE_OP_COMPUTE_BLK, &ops_request)) { + tx = ops_run_compute5(sh); + /* terminate the chain if postxor is not set to be run */ + if (tx && !test_bit(STRIPE_OP_POSTXOR, &ops_request)) + async_tx_ack(tx); + } if (test_bit(STRIPE_OP_PREXOR, &ops_request)) tx = ops_run_prexor(sh, tx);