Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e559e91c authored by Sebastian Siewior's avatar Sebastian Siewior Committed by Herbert Xu
Browse files

[CRYPTO] api: Allow ablkcipher with no queues



Evgeniy's hifn driver and probably mine don't use ablkcipher->queue at all. 
The show method of ablkcipher will access this field without checking if it 
is valid.

Signed-off-by: default avatarSebastian Siewior <linux-crypto@ml.breakpoint.cc>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent e69ff734
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -91,9 +91,11 @@ static void crypto_ablkcipher_show(struct seq_file *m, struct crypto_alg *alg)
	seq_printf(m, "min keysize  : %u\n", ablkcipher->min_keysize);
	seq_printf(m, "max keysize  : %u\n", ablkcipher->max_keysize);
	seq_printf(m, "ivsize       : %u\n", ablkcipher->ivsize);
	if (ablkcipher->queue) {
		seq_printf(m, "qlen         : %u\n", ablkcipher->queue->qlen);
		seq_printf(m, "max qlen     : %u\n", ablkcipher->queue->max_qlen);
	}
}

const struct crypto_type crypto_ablkcipher_type = {
	.ctxsize = crypto_ablkcipher_ctxsize,