-
- Downloads
net: replace sockbuf::sb_rwlock with a waitqueue
sb_rwlock is used to serialize concurrent writers (or readers) to the same socket buffer, but is quite expensive as it requires 4 atomic operations per transaction, even if there is no contention. Replace it with a waitqueue, and use the sockbuf::sb_mtx for serialization. This still has exactly the same cost, but we can later move sblock() and sbunlock() into contexts where the sockbuf::sb_mtx is already acquired. Signed-off-by:Avi Kivity <avi@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
Loading
Please register or sign in to comment