lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20190918143235.kpclo45eo7qye7fs@ast-mbp.dhcp.thefacebook.com>
Date:   Wed, 18 Sep 2019 07:32:37 -0700
From:   Alexei Starovoitov <alexei.starovoitov@...il.com>
To:     Yonghong Song <yhs@...com>
Cc:     "jinshan.xiong@...il.com" <jinshan.xiong@...il.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "rostedt@...dmis.org" <rostedt@...dmis.org>,
        "mingo@...hat.com" <mingo@...hat.com>,
        "jinshan.xiong@...r.com" <jinshan.xiong@...r.com>,
        "bpf@...r.kernel.org" <bpf@...r.kernel.org>
Subject: Re: [PATCH] staging: tracing/kprobe: filter kprobe based perf event

On Wed, Sep 18, 2019 at 05:51:10AM +0000, Yonghong Song wrote:
> 
> Adding cc to bpf@...r.kernel.org mailing list since this is really
> bpf related.
> 
> On 9/17/19 10:24 PM, jinshan.xiong@...il.com wrote:
> > From: Jinshan Xiong <jinshan.xiong@...il.com>
> > 
> > Invoking bpf program only if kprobe based perf_event has been added into
> > the percpu list. This is essential to make event tracing for cgroup to work
> > properly.
> 
> The issue actually exists for bpf programs with kprobe, uprobe, 
> tracepoint and trace_syscall_enter/exit.
> 
> In all these places, bpf program is called regardless of
> whether there are perf events or not on this cpu.
> This provides bpf programs more opportunities to see
> the events. I guess this is by design.
> Alexei/Daniel, could you clarify?

Yes. It is by design.
When bpf is attached to kprobe it will fire on all cpus.
Per-cpu or per-task or per-cgroup filtering is already done
inside bpf programs.
We cannot make this change now it will break all users.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ