Skip to content

Commit

Permalink
crypto: drbg - Fixes panic in wait_for_completion call
Browse files Browse the repository at this point in the history
Initialise ctr_completion variable before use.

Signed-off-by: Harsh Jain <[email protected]>
Signed-off-by: Stephan Mueller <[email protected]>
Signed-off-by: Herbert Xu <[email protected]>
  • Loading branch information
smuellerDD authored and herbertx committed Jun 10, 2017
1 parent 543de10 commit a18ccc3
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions crypto/drbg.c
Original file line number Diff line number Diff line change
Expand Up @@ -1691,6 +1691,7 @@ static int drbg_init_sym_kernel(struct drbg_state *drbg)
return PTR_ERR(sk_tfm);
}
drbg->ctr_handle = sk_tfm;
init_completion(&drbg->ctr_completion);

req = skcipher_request_alloc(sk_tfm, GFP_KERNEL);
if (!req) {
Expand Down

0 comments on commit a18ccc3

Please sign in to comment.