commit | 85a86cb9085cbb0f48585c44837724d173084a2a | [log] [tgz] |
---|---|---|
author | Patrick Rohr <prohr@google.com> | Thu May 18 13:54:36 2023 -0700 |
committer | Patrick Rohr <prohr@google.com> | Thu May 18 14:08:37 2023 -0700 |
tree | c5ef5e9c8d05796479cb11850a4724b699076964 | |
parent | 52954ff5050c83af36f6de76f6834c2068825699 [diff] |
BpfRingbuf: Clean up memory access Consumer pos is only written to by userspace (except for initialization), so reading from it does not require a memory barrier. This change also moves producer pos to be acquired before anything else and marks start_ptr as volatile, so it is only read once. Test: atest BpfRingbufTest Change-Id: I228578ef4b42c1732646f0ae928b9a0aa2445304