diff options
author | Alexander Bluhm <bluhm@cvs.openbsd.org> | 2023-11-10 15:51:25 +0000 |
---|---|---|
committer | Alexander Bluhm <bluhm@cvs.openbsd.org> | 2023-11-10 15:51:25 +0000 |
commit | 67680ffa08ea8739b777a8b57ac3ac62eb1b1c2f (patch) | |
tree | 28d84f0566badb4b35cd162f9bb53a93e96e75d0 /gnu | |
parent | 69fb630aba24c73ac8c8c98da1b02370f5cc9489 (diff) |
Make ifq and ifiq interface MP safe.
Rename ifq_set_maxlen() to ifq_init_maxlen(). This function neither
uses WRITE_ONCE() nor a mutex and is called before the ifq mutex
is initialized. The new name expresses that it should be used only
during interface attach when there is no concurrency.
Protect ifq_len(), ifq_empty(), ifiq_len(), and ifiq_empty() with
READ_ONCE(). They can be used without lock as they only read a
single integer.
OK dlg@
Diffstat (limited to 'gnu')
0 files changed, 0 insertions, 0 deletions