From d316f794dd9aa1b84aac8ddbd44602325b25cebc Mon Sep 17 00:00:00 2001 From: pjd Date: Mon, 22 May 2006 09:37:28 +0000 Subject: Don't set cc_kqblocked twice and don't increment cryptostats.cs_kblocks twice if we call crypto_kinvoke() from crypto_proc thread. This change also removes unprotected access to cc_kqblocked field (CRYPTO_Q_LOCK() should be used for protection). --- sys/opencrypto/crypto.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'sys/opencrypto') diff --git a/sys/opencrypto/crypto.c b/sys/opencrypto/crypto.c index 38d285c..36e32a7 100644 --- a/sys/opencrypto/crypto.c +++ b/sys/opencrypto/crypto.c @@ -773,9 +773,7 @@ crypto_kinvoke(struct cryptkop *krp) CRYPTO_DRIVER_LOCK(); if (error == ERESTART) { cap->cc_koperations--; - cap->cc_kqblocked = 1; CRYPTO_DRIVER_UNLOCK(); - cryptostats.cs_kblocks++; return (error); } } else { -- cgit v1.1