diff options
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/algapi.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/crypto/algapi.c b/crypto/algapi.c index 08c57c8aec95..6149a6e09643 100644 --- a/crypto/algapi.c +++ b/crypto/algapi.c | |||
@@ -447,7 +447,7 @@ EXPORT_SYMBOL_GPL(crypto_register_template); | |||
447 | void crypto_unregister_template(struct crypto_template *tmpl) | 447 | void crypto_unregister_template(struct crypto_template *tmpl) |
448 | { | 448 | { |
449 | struct crypto_instance *inst; | 449 | struct crypto_instance *inst; |
450 | struct hlist_node *p, *n; | 450 | struct hlist_node *n; |
451 | struct hlist_head *list; | 451 | struct hlist_head *list; |
452 | LIST_HEAD(users); | 452 | LIST_HEAD(users); |
453 | 453 | ||
@@ -457,7 +457,7 @@ void crypto_unregister_template(struct crypto_template *tmpl) | |||
457 | list_del_init(&tmpl->list); | 457 | list_del_init(&tmpl->list); |
458 | 458 | ||
459 | list = &tmpl->instances; | 459 | list = &tmpl->instances; |
460 | hlist_for_each_entry(inst, p, list, list) { | 460 | hlist_for_each_entry(inst, list, list) { |
461 | int err = crypto_remove_alg(&inst->alg, &users); | 461 | int err = crypto_remove_alg(&inst->alg, &users); |
462 | BUG_ON(err); | 462 | BUG_ON(err); |
463 | } | 463 | } |
@@ -466,7 +466,7 @@ void crypto_unregister_template(struct crypto_template *tmpl) | |||
466 | 466 | ||
467 | up_write(&crypto_alg_sem); | 467 | up_write(&crypto_alg_sem); |
468 | 468 | ||
469 | hlist_for_each_entry_safe(inst, p, n, list, list) { | 469 | hlist_for_each_entry_safe(inst, n, list, list) { |
470 | BUG_ON(atomic_read(&inst->alg.cra_refcnt) != 1); | 470 | BUG_ON(atomic_read(&inst->alg.cra_refcnt) != 1); |
471 | tmpl->free(inst); | 471 | tmpl->free(inst); |
472 | } | 472 | } |