86dc27ee36
[ Upstream commit aec7961916f3f9e88766e2688992da6980f11b8d ]
The submitting thread (one which called recvmsg/sendmsg)
may exit as soon as the async crypto handler calls complete()
so any code past that point risks touching already freed data.
Try to avoid the locking and extra flags altogether.
Have the main thread hold an extra reference, this way
we can depend solely on the atomic ref counter for
synchronization.
Don't futz with reiniting the completion, either, we are now
tightly controlling when completion fires.
Reported-by: valis <sec@valis.email>
Fixes:
|
||
---|---|---|
.. | ||
Kconfig | ||
Makefile | ||
tls.h | ||
tls_device.c | ||
tls_device_fallback.c | ||
tls_main.c | ||
tls_proc.c | ||
tls_strp.c | ||
tls_sw.c | ||
tls_toe.c | ||
trace.c | ||
trace.h |