]> git.baikalelectronics.ru Git - kernel.git/commit
bpf: af_unix: Implement BPF iterator for UNIX domain socket.
authorKuniyuki Iwashima <kuniyu@amazon.co.jp>
Sat, 14 Aug 2021 01:57:15 +0000 (10:57 +0900)
committerAndrii Nakryiko <andrii@kernel.org>
Sun, 15 Aug 2021 07:13:32 +0000 (00:13 -0700)
commit5cfa3773d026f512f27b80e92aeb4c30f5e6238f
tree86ef0c1115eda01220a5ffa8053e48a1394a43fc
parent9916df010c63b1f4a1ebec7c2bb93a33f9e4dc58
bpf: af_unix: Implement BPF iterator for UNIX domain socket.

This patch implements the BPF iterator for the UNIX domain socket.

Currently, the batch optimisation introduced for the TCP iterator in the
commit 863342a9a38f ("bpf: tcp: Bpf iter batching and lock_sock") is not
used for the UNIX domain socket.  It will require replacing the big lock
for the hash table with small locks for each hash list not to block other
processes.

Signed-off-by: Kuniyuki Iwashima <kuniyu@amazon.co.jp>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Acked-by: Yonghong Song <yhs@fb.com>
Link: https://lore.kernel.org/bpf/20210814015718.42704-2-kuniyu@amazon.co.jp
include/linux/btf_ids.h
net/unix/af_unix.c