mirror of
https://git.FreeBSD.org/src.git
synced 2024-12-28 11:57:28 +00:00
Fix uninitialized crp_retw_id when using asynchronous crypto drivers
with defered callbacks. Submitted by: emeric.poupon@stormshield.eu Reported by: mav@ Reviewed by: fabient@
This commit is contained in:
parent
dde4c2fc9d
commit
de2b2c908a
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=327696
@ -896,11 +896,12 @@ crypto_dispatch(struct cryptop *crp)
|
||||
binuptime(&crp->crp_tstamp);
|
||||
#endif
|
||||
|
||||
crp->crp_retw_id = crp->crp_sid % crypto_workers_num;
|
||||
|
||||
if (CRYPTOP_ASYNC(crp)) {
|
||||
if (crp->crp_flags & CRYPTO_F_ASYNC_KEEPORDER) {
|
||||
struct crypto_ret_worker *ret_worker;
|
||||
|
||||
crp->crp_retw_id = crp->crp_sid % crypto_workers_num;
|
||||
ret_worker = CRYPTO_RETW(crp->crp_retw_id);
|
||||
|
||||
CRYPTO_RETW_LOCK(ret_worker);
|
||||
|
Loading…
Reference in New Issue
Block a user