diff options
| author | Jordan Rife <[email protected]> | 2025-07-14 18:09:09 +0000 |
|---|---|---|
| committer | Martin KaFai Lau <[email protected]> | 2025-07-14 19:09:09 +0000 |
| commit | f5080f612a1c587bf636bb23d2a2f4de276d60e4 (patch) | |
| tree | 73ace996945ed66273de2da6070bc43553e1cfff /drivers/fpga/fpga-region.c | |
| parent | bpf: tcp: Use bpf_tcp_iter_batch_item for bpf_tcp_iter_state batch items (diff) | |
| download | kernel-f5080f612a1c587bf636bb23d2a2f4de276d60e4.tar.gz kernel-f5080f612a1c587bf636bb23d2a2f4de276d60e4.zip | |
bpf: tcp: Avoid socket skips and repeats during iteration
Replace the offset-based approach for tracking progress through a bucket
in the TCP table with one based on socket cookies. Remember the cookies
of unprocessed sockets from the last batch and use this list to
pick up where we left off or, in the case that the next socket
disappears between reads, find the first socket after that point that
still exists in the bucket and resume from there.
This approach guarantees that all sockets that existed when iteration
began and continue to exist throughout will be visited exactly once.
Sockets that are added to the table during iteration may or may not be
seen, but if they are they will be seen exactly once.
Signed-off-by: Jordan Rife <[email protected]>
Signed-off-by: Martin KaFai Lau <[email protected]>
Acked-by: Stanislav Fomichev <[email protected]>
Diffstat (limited to 'drivers/fpga/fpga-region.c')
0 files changed, 0 insertions, 0 deletions
