]> git.ipfire.org Git - thirdparty/openssl.git/commit
Do some more cleanup in the RCU code
authorBernd Edlinger <bernd.edlinger@hotmail.de>
Sun, 9 Mar 2025 10:20:43 +0000 (11:20 +0100)
committerTomas Mraz <tomas@openssl.org>
Tue, 18 Mar 2025 17:52:29 +0000 (18:52 +0100)
commita532f2302d9eac7a2ba52b9929b790c20347c9ba
tree896b4040efec86e9175ad502d5985062cd341c81
parent4a1a7fe5ce088964010779e1f5a90560903ecc76
Do some more cleanup in the RCU code

Only a minimum of 2 qp's are necessary: one for the readers,
and at least one that writers can wait on for retirement.
There is no need for one additional qp that is always unused.
Also only one ACQUIRE barrier is necessary in get_hold_current_qp,
so the ATOMIC_LOAD of the reader_idx can be changed to RELAXED.
And finally clarify some comments.

Reviewed-by: Paul Dale <ppzgs1@gmail.com>
Reviewed-by: Tomas Mraz <tomas@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/27012)
crypto/threads_pthread.c
crypto/threads_win.c