]> git.baikalelectronics.ru Git - kernel.git/commit
bpftool: Extract helpers for showing link attach type
authorJakub Sitnicki <jakub@cloudflare.com>
Sun, 31 May 2020 08:28:41 +0000 (10:28 +0200)
committerAlexei Starovoitov <ast@kernel.org>
Mon, 1 Jun 2020 22:21:03 +0000 (15:21 -0700)
commit97fcf13435ea72c3c453c8d8d6b2765863bcab71
treedd45dc2eeff5cc6fd1893064d7f46f39413a9018
parent62377709ab35eb3be728dae92bf5e0be6ce86764
bpftool: Extract helpers for showing link attach type

Code for printing link attach_type is duplicated in a couple of places, and
likely will be duplicated for future link types as well. Create helpers to
prevent duplication.

Suggested-by: Andrii Nakryiko <andriin@fb.com>
Signed-off-by: Jakub Sitnicki <jakub@cloudflare.com>
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Link: https://lore.kernel.org/bpf/20200531082846.2117903-8-jakub@cloudflare.com
tools/bpf/bpftool/link.c