From: Quentin Monnet <quentin.monnet@netronome.com>
To: Alexei Starovoitov <ast@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>
Cc: bpf@vger.kernel.org, netdev@vger.kernel.org,
oss-drivers@netronome.com,
Quentin Monnet <quentin.monnet@netronome.com>
Subject: [RFC bpf-next 2/3] tools: bpftool: make comment more explicit for count of dumped entries
Date: Tue, 13 Aug 2019 14:09:20 +0100 [thread overview]
Message-ID: <20190813130921.10704-3-quentin.monnet@netronome.com> (raw)
In-Reply-To: <20190813130921.10704-1-quentin.monnet@netronome.com>
The counter printed at the end of plain map dump does not reflect the
exact number of entries in the map, but the number of entries bpftool
managed to dump (some of them could not be read, or made no sense to
dump (map-in-map...)).
Edit slightly the message to make this more explicit.
Signed-off-by: Quentin Monnet <quentin.monnet@netronome.com>
Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com>
---
tools/bpf/bpftool/map.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/bpf/bpftool/map.c b/tools/bpf/bpftool/map.c
index 206ee46189d9..cead639b3ab1 100644
--- a/tools/bpf/bpftool/map.c
+++ b/tools/bpf/bpftool/map.c
@@ -809,7 +809,7 @@ static int do_dump(int argc, char **argv)
jsonw_end_array(btf_wtr);
jsonw_destroy(&btf_wtr);
} else {
- printf("Found %u element%s\n", num_elems,
+ printf("Found %u element%s to dump\n", num_elems,
num_elems != 1 ? "s" : "");
}
--
2.17.1
next prev parent reply other threads:[~2019-08-13 13:09 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-13 13:09 [RFC bpf-next 0/3] tools: bpftool: add subcommand to count map entries Quentin Monnet
2019-08-13 13:09 ` [RFC bpf-next 1/3] tools: bpftool: clean up dump_map_elem() return value Quentin Monnet
2019-08-13 13:09 ` Quentin Monnet [this message]
2019-08-13 13:09 ` [RFC bpf-next 3/3] tools: bpftool: add "bpftool map count" to count entries in map Quentin Monnet
2019-08-14 1:51 ` [RFC bpf-next 0/3] tools: bpftool: add subcommand to count map entries Alexei Starovoitov
2019-08-14 9:42 ` Quentin Monnet
2019-08-14 16:45 ` Edward Cree
2019-08-14 16:58 ` Alexei Starovoitov
2019-08-14 17:12 ` Quentin Monnet
2019-08-14 20:18 ` Andrii Nakryiko
2019-08-15 14:02 ` Quentin Monnet
2019-08-14 16:58 ` Quentin Monnet
2019-08-14 17:14 ` Edward Cree
2019-08-15 14:15 ` Quentin Monnet
2019-08-16 18:13 ` Edward Cree
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190813130921.10704-3-quentin.monnet@netronome.com \
--to=quentin.monnet@netronome.com \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=daniel@iogearbox.net \
--cc=netdev@vger.kernel.org \
--cc=oss-drivers@netronome.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox