From: Peter Zijlstra <peterz@infradead.org>
To: Alexei Starovoitov <ast@kernel.org>
Cc: "David S . Miller" <davem@davemloft.net>,
daniel@iogearbox.net, acme@kernel.org, netdev@vger.kernel.org,
kernel-team@fb.com
Subject: Re: [PATCH bpf-next 2/3] bpf: emit RECORD_MMAP events for bpf prog load/unload
Date: Thu, 20 Sep 2018 10:44:24 +0200 [thread overview]
Message-ID: <20180920084424.GN24124@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <20180919223935.999270-3-ast@kernel.org>
On Wed, Sep 19, 2018 at 03:39:34PM -0700, Alexei Starovoitov wrote:
> void bpf_prog_kallsyms_del(struct bpf_prog *fp)
> {
> + unsigned long symbol_start, symbol_end;
> + /* mmap_record.filename cannot be NULL and has to be u64 aligned */
> + char buf[sizeof(u64)] = {};
> +
> if (!bpf_prog_kallsyms_candidate(fp))
> return;
>
> spin_lock_bh(&bpf_lock);
> bpf_prog_ksym_node_del(fp->aux);
> spin_unlock_bh(&bpf_lock);
> + bpf_get_prog_addr_region(fp, &symbol_start, &symbol_end);
> + perf_event_mmap_bpf_prog(symbol_start, symbol_end - symbol_start,
> + buf, sizeof(buf));
> }
So perf doesn't normally issue unmap events.. We've talked about doing
that, but so far it's never really need needed I think.
I feels a bit weird to start issuing unmap events for this.
next prev parent reply other threads:[~2018-09-20 14:26 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-19 22:39 [PATCH bpf-next 0/3] perf, bpf: reveal invisible bpf programs Alexei Starovoitov
2018-09-19 22:39 ` [PATCH bpf-next 1/3] perf/core: introduce perf_event_mmap_bpf_prog Alexei Starovoitov
2018-09-19 23:30 ` Song Liu
2018-09-20 0:53 ` Alexei Starovoitov
2018-09-19 22:39 ` [PATCH bpf-next 2/3] bpf: emit RECORD_MMAP events for bpf prog load/unload Alexei Starovoitov
2018-09-19 23:44 ` Song Liu
2018-09-20 0:59 ` Alexei Starovoitov
2018-09-20 5:48 ` Song Liu
2018-09-20 8:44 ` Peter Zijlstra [this message]
2018-09-20 13:25 ` Arnaldo Carvalho de Melo
2018-09-20 13:56 ` Peter Zijlstra
2018-09-21 3:14 ` Alexei Starovoitov
2018-09-21 12:25 ` Arnaldo Carvalho de Melo
2018-09-21 13:55 ` Peter Zijlstra
2018-09-21 13:59 ` Peter Zijlstra
2018-09-21 22:13 ` Alexei Starovoitov
2018-10-15 23:33 ` Song Liu
2018-10-16 23:43 ` David Ahern
2018-10-17 6:43 ` Song Liu
2018-10-17 12:11 ` Arnaldo Carvalho de Melo
2018-10-17 12:50 ` Arnaldo Carvalho de Melo
2018-10-17 16:06 ` Song Liu
2018-11-02 1:08 ` Song Liu
2018-10-17 15:09 ` David Ahern
2018-10-17 16:18 ` Song Liu
2018-10-17 16:36 ` Alexei Starovoitov
2018-10-17 18:53 ` Arnaldo Carvalho de Melo
2018-10-17 19:08 ` Alexei Starovoitov
2018-10-17 21:31 ` Arnaldo Carvalho de Melo
2018-10-17 22:01 ` Alexei Starovoitov
2018-09-20 13:36 ` Peter Zijlstra
2018-09-19 22:39 ` [PATCH perf 3/3] tools/perf: recognize and process RECORD_MMAP events for bpf progs Alexei Starovoitov
2018-09-20 13:36 ` Arnaldo Carvalho de Melo
2018-09-20 14:05 ` Arnaldo Carvalho de Melo
2018-09-21 22:57 ` Song Liu
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=20180920084424.GN24124@hirez.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=acme@kernel.org \
--cc=ast@kernel.org \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=kernel-team@fb.com \
--cc=netdev@vger.kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.