Linux Kernels

bpftool: add bash completion for cgroup tree command

This change “bpftool: add bash completion for cgroup tree command” (commit 02000b5) in Linux kernel is authored by Roman Gushchin <guro [at] fb.com> on Fri Jul 6 14:28:16 2018 -0700.

Description of "bpftool: add bash completion for cgroup tree command"

The change “bpftool: add bash completion for cgroup tree command” introduces changes as follows.

bpftool: add bash completion for cgroup tree command

This commit adds a bash completion to the bpftool cgroup tree
command.

Signed-off-by: Roman Gushchin <guro@fb.com>
Cc: Jakub Kicinski <jakub.kicinski@netronome.com>
Cc: Quentin Monnet <quentin.monnet@netronome.com>
Cc: Daniel Borkmann <daniel@iogearbox.net>
Cc: Alexei Starovoitov <ast@kernel.org>
Acked-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>

Linux kernel releases containing commit 02000b5

The Linux kernel releases containing this commit are as follows.

Linux kernel code changes in "bpftool: add bash completion for cgroup tree command"

There are 6 lines of Linux source code added/deleted in this change. Code changes to Linux kernel are as follows.

 tools/bpf/bpftool/bash-completion/bpftool | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
 
diff --git a/tools/bpf/bpftool/bash-completion/bpftool b/tools/bpf/bpftool/bash-completion/bpftool
index fffd76f4998b..ce0bc0cda361 100644
--- a/tools/bpf/bpftool/bash-completion/bpftool
+++ b/tools/bpf/bpftool/bash-completion/bpftool
@@ -414,6 +414,10 @@ _bpftool()
                     _filedir
                     return 0
                     ;;
+		tree)
+		    _filedir
+		    return 0
+		    ;;
                 attach|detach)
                     local ATTACH_TYPES='ingress egress sock_create sock_ops \
                         device bind4 bind6 post_bind4 post_bind6 connect4 \
@@ -455,7 +459,7 @@ _bpftool()
                 *)
                     [[ $prev == $object ]] && \
                         COMPREPLY=( $( compgen -W 'help attach detach \
-                            show list' -- "$cur" ) )
+                            show list tree' -- "$cur" ) )
                     ;;
             esac
             ;;

The commit for this change in Linux stable tree is 02000b5 (patch).

Last modified: 2020/01/11 09:26