]> git.baikalelectronics.ru Git - kernel.git/commit
bpftool: Move out sections to separate functions
authorMichal Rostecki <mrostecki@opensuse.org>
Wed, 26 Feb 2020 16:59:35 +0000 (17:59 +0100)
committerDaniel Borkmann <daniel@iogearbox.net>
Wed, 26 Feb 2020 17:34:34 +0000 (18:34 +0100)
commit4c00f5f1a3544b6909c8951e9a1882da5ce93de8
tree62ed3f4f1c03147954ee4574768e8d7a6a7bff3f
parentafe4152105bd70758127a98305e78ae55970560e
bpftool: Move out sections to separate functions

Remove all calls of print_end_then_start_section function and for loops
out from the do_probe function. Instead, provide separate functions for
each section (like i.e. section_helpers) which are called in do_probe.
This change is motivated by better readability.

Signed-off-by: Michal Rostecki <mrostecki@opensuse.org>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
Reviewed-by: Quentin Monnet <quentin@isovalent.com>
Link: https://lore.kernel.org/bpf/20200226165941.6379-2-mrostecki@opensuse.org
tools/bpf/bpftool/feature.c