From: Jesper Dangaard Brouer <brouer@redhat•com>
To: Sebastiano Miano <sebastiano.miano@polito•it>
Cc: netdev@vger•kernel.org, ast@kernel•org, daniel@iogearbox•net,
mingo@redhat•com, rostedt@goodmis•org, fulvio.risso@polito•it,
brouer@redhat•com
Subject: Re: [bpf-next PATCH 3/3] bpf: add sample program to trace map events
Date: Thu, 19 Apr 2018 11:20:04 +0200 [thread overview]
Message-ID: <20180419112004.5eb67a84@redhat.com> (raw)
In-Reply-To: <152406545918.3465.14253635905960610284.stgit@localhost.localdomain>
On Wed, 18 Apr 2018 17:30:59 +0200
Sebastiano Miano <sebastiano.miano@polito•it> wrote:
> This patch adds a sample program, called trace_map_events,
> that shows how to capture map events and filter them based on
> the map id.
>
> The program accepts a list of map IDs, via the -i command line
> option, and filters all the map events related to those IDs (i.e.,
> map_create/update/lookup/next_key).
> If no IDs are specified, all map events are listed and no filtering
> is performed.
>
> Sample usage:
>
> # trace_map_events -i <map_id1> -i <map_id2> -i <map_id3> ...
>
> Signed-off-by: Sebastiano Miano <sebastiano.miano@polito•it>
Acked-by: Jesper Dangaard Brouer <brouer@redhat•com>
I have tested it works:
$ sudo ./trace_map_events -i 2
Init bpf_perf_event for cpu:0
Init bpf_perf_event for cpu:1
Init bpf_perf_event for cpu:2
Init bpf_perf_event for cpu:3
Init bpf_perf_event for cpu:4
Init bpf_perf_event for cpu:5
Waiting for map events...
LOOKUP event for map id: 2 and type: 6
Waiting for map events...
LOOKUP event for map id: 2 and type: 6
Waiting for map events...
LOOKUP event for map id: 2 and type: 6
Waiting for map events...
LOOKUP event for map id: 2 and type: 6
Waiting for map events...
LOOKUP event for map id: 2 and type: 6
Waiting for map events...
LOOKUP event for map id: 2 and type: 6
Waiting for map events...
LOOKUP event for map id: 2 and type: 6
Waiting for map events...
--
Best regards,
Jesper Dangaard Brouer
MSc.CS, Principal Kernel Engineer at Red Hat
LinkedIn: http://www.linkedin.com/in/brouer
next prev parent reply other threads:[~2018-04-19 9:20 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-18 15:30 [bpf-next PATCH 0/3] Add ID to bpf_map/prog tracepoints Sebastiano Miano
2018-04-18 15:30 ` [bpf-next PATCH 1/3] bpf: add id to map tracepoint Sebastiano Miano
2018-04-19 9:08 ` Jesper Dangaard Brouer
2018-04-18 15:30 ` [bpf-next PATCH 2/3] bpf: add id to prog tracepoint Sebastiano Miano
2018-04-19 9:10 ` Jesper Dangaard Brouer
2018-04-18 15:30 ` [bpf-next PATCH 3/3] bpf: add sample program to trace map events Sebastiano Miano
2018-04-19 9:20 ` Jesper Dangaard Brouer [this message]
2018-04-20 0:27 ` Alexei Starovoitov
2018-04-20 9:47 ` Jesper Dangaard Brouer
2018-04-23 14:08 ` Sebastiano Miano
2018-04-23 20:08 ` Alexei Starovoitov
2018-04-23 20:22 ` Jesper Dangaard Brouer
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=20180419112004.5eb67a84@redhat.com \
--to=brouer@redhat$(echo .)com \
--cc=ast@kernel$(echo .)org \
--cc=daniel@iogearbox$(echo .)net \
--cc=fulvio.risso@polito$(echo .)it \
--cc=mingo@redhat$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
--cc=rostedt@goodmis$(echo .)org \
--cc=sebastiano.miano@polito$(echo .)it \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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