]> git.ipfire.org Git - thirdparty/wireguard-go.git/commit
device: do atomic 64-bit add outside of vector loop
authorJason A. Donenfeld <Jason@zx2c4.com>
Mon, 11 Dec 2023 15:35:57 +0000 (16:35 +0100)
committerJason A. Donenfeld <Jason@zx2c4.com>
Mon, 11 Dec 2023 15:35:57 +0000 (16:35 +0100)
commit542e565baa776ed4c5c55b73ef9aa38d33d55197
tree58c5ab624d1174ae333104d9e9e81b408ed4e119
parent7c20311b3d30b96576a95fec31f58e4d5e0d3234
device: do atomic 64-bit add outside of vector loop

Only bother updating the rxBytes counter once we've processed a whole
vector, since additions are atomic.

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
device/receive.go