]> git.ipfire.org Git - thirdparty/man-pages.git/commit
perf_event_open.2: 4.0 update rdpmc documentation
authorVince Weaver <vincent.weaver@maine.edu>
Thu, 23 Jul 2015 17:16:01 +0000 (13:16 -0400)
committerMichael Kerrisk <mtk.manpages@gmail.com>
Wed, 14 Oct 2015 06:46:32 +0000 (08:46 +0200)
commit562c69f66f1b77198af1ab4f51e8cd26018982c6
treea5773674edc0ae19d72848e0d72bd53c0c75e531
parent6932aac3d28ff686bbc50916a4f7b0274c6bf3a1
perf_event_open.2: 4.0 update rdpmc documentation

The rdpmc instruction allows reading performance counters directly
from usersapce.  Prior to Linux 4.0 any process could use this
instruction when a perf event was running, even if the process itself
did not have any open.  The following changesets changed the default
behavior so that only processes with active events can use rdpmc.

Note this change broke the ABI.  Previously:
/sys/bus/event_source/devices/cpu/rdpmc
Set to "1" meant allow across whole system.

After the change "2" means the whole system, and "1" means per-process.

Probably a better change would have been to add "2" to mean per-process
and make that the default setting.  Probably too late to fix that now.

commit a66734297f78707ce39d756b656bfae861d53f62
Author: Andy Lutomirski <luto@amacapital.net>

perf/x86: Add /sys/devices/cpu/rdpmc=2 to allow rdpmc for all tasks

commit 7911d3f7af14a614617e38245fedf98a724e46a9
Author: Andy Lutomirski <luto@amacapital.net>

perf/x86: Only allow rdpmc if a perf_event is mapped

Signed-off-by: Andy Lutomirski <luto@amacapital.net>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Arnaldo Carvalho de Melo <acme@kernel.org>
Cc: Kees Cook <keescook@chromium.org>
Cc: Andrea Arcangeli <aarcange@redhat.com>
Cc: Vince Weaver <vince@deater.net>
Cc: "hillf.zj" <hillf.zj@alibaba-inc.com>
Cc: Valdis Kletnieks <Valdis.Kletnieks@vt.edu>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Link: http://lkml.kernel.org/r/caac3c1c707dcca48ecbc35f4def21495856f479.1414190806.git.luto@amacapital.net
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Signed-off-by: Vince Weaver <vincent.weaver@maine.edu>
Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
man2/perf_event_open.2