aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/testmgr.c
diff options
context:
space:
mode:
authorWolfram Sang <wsa@the-dreams.de>2013-11-14 17:32:02 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2013-11-14 19:32:21 -0500
commit16735d022f72b20ddbb2274b8e109f69575e9b2b (patch)
treef567c7dfff06ae18899feab7cd8a79a7a0f7be40 /crypto/testmgr.c
parentc32f74ab2872994bc8336ed367313da3139350ca (diff)
tree-wide: use reinit_completion instead of INIT_COMPLETION
Use this new function to make code more comprehensible, since we are reinitialzing the completion, not initializing. [akpm@linux-foundation.org: linux-next resyncs] Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Acked-by: Linus Walleij <linus.walleij@linaro.org> (personally at LCE13) Cc: Ingo Molnar <mingo@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'crypto/testmgr.c')
-rw-r--r--crypto/testmgr.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/crypto/testmgr.c b/crypto/testmgr.c
index e091ef6e1791..432afc03e7c3 100644
--- a/crypto/testmgr.c
+++ b/crypto/testmgr.c
@@ -179,7 +179,7 @@ static int do_one_async_hash_op(struct ahash_request *req,
179 ret = wait_for_completion_interruptible(&tr->completion); 179 ret = wait_for_completion_interruptible(&tr->completion);
180 if (!ret) 180 if (!ret)
181 ret = tr->err; 181 ret = tr->err;
182 INIT_COMPLETION(tr->completion); 182 reinit_completion(&tr->completion);
183 } 183 }
184 return ret; 184 return ret;
185} 185}
@@ -336,7 +336,7 @@ static int __test_hash(struct crypto_ahash *tfm, struct hash_testvec *template,
336 ret = wait_for_completion_interruptible( 336 ret = wait_for_completion_interruptible(
337 &tresult.completion); 337 &tresult.completion);
338 if (!ret && !(ret = tresult.err)) { 338 if (!ret && !(ret = tresult.err)) {
339 INIT_COMPLETION(tresult.completion); 339 reinit_completion(&tresult.completion);
340 break; 340 break;
341 } 341 }
342 /* fall through */ 342 /* fall through */
@@ -543,7 +543,7 @@ static int __test_aead(struct crypto_aead *tfm, int enc,
543 ret = wait_for_completion_interruptible( 543 ret = wait_for_completion_interruptible(
544 &result.completion); 544 &result.completion);
545 if (!ret && !(ret = result.err)) { 545 if (!ret && !(ret = result.err)) {
546 INIT_COMPLETION(result.completion); 546 reinit_completion(&result.completion);
547 break; 547 break;
548 } 548 }
549 case -EBADMSG: 549 case -EBADMSG:
@@ -697,7 +697,7 @@ static int __test_aead(struct crypto_aead *tfm, int enc,
697 ret = wait_for_completion_interruptible( 697 ret = wait_for_completion_interruptible(
698 &result.completion); 698 &result.completion);
699 if (!ret && !(ret = result.err)) { 699 if (!ret && !(ret = result.err)) {
700 INIT_COMPLETION(result.completion); 700 reinit_completion(&result.completion);
701 break; 701 break;
702 } 702 }
703 case -EBADMSG: 703 case -EBADMSG:
@@ -983,7 +983,7 @@ static int __test_skcipher(struct crypto_ablkcipher *tfm, int enc,
983 ret = wait_for_completion_interruptible( 983 ret = wait_for_completion_interruptible(
984 &result.completion); 984 &result.completion);
985 if (!ret && !((ret = result.err))) { 985 if (!ret && !((ret = result.err))) {
986 INIT_COMPLETION(result.completion); 986 reinit_completion(&result.completion);
987 break; 987 break;
988 } 988 }
989 /* fall through */ 989 /* fall through */
@@ -1086,7 +1086,7 @@ static int __test_skcipher(struct crypto_ablkcipher *tfm, int enc,
1086 ret = wait_for_completion_interruptible( 1086 ret = wait_for_completion_interruptible(
1087 &result.completion); 1087 &result.completion);
1088 if (!ret && !((ret = result.err))) { 1088 if (!ret && !((ret = result.err))) {
1089 INIT_COMPLETION(result.completion); 1089 reinit_completion(&result.completion);
1090 break; 1090 break;
1091 } 1091 }
1092 /* fall through */ 1092 /* fall through */