perf: Comment /proc/sys/kernel/perf_event_paranoid to be part of user ABI
authorVince Weaver <[email protected]>
Fri, 3 Jun 2011 21:54:40 +0000 (17:54 -0400)
committerIngo Molnar <[email protected]>
Sat, 4 Jun 2011 10:22:04 +0000 (12:22 +0200)
Turns out that distro packages use this file as an indicator of
the perf event subsystem - this is easier to check for from scripts
than the existence of the system call.

This is easy enough to keep around for the kernel, so add a
comment to make sure it stays so.

Signed-off-by: Vince Weaver <[email protected]>
Cc: David Ahern <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: Linus Torvalds <[email protected]>
Cc: Andrew Morton <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Signed-off-by: Ingo Molnar <[email protected]>
kernel/sysctl.c

index 4fc92445a29c920405935176b473485af8140f17..f175d98bd3557c912e15f65fcd98be713f400f29 100644 (file)
@@ -938,6 +938,12 @@ static struct ctl_table kern_table[] = {
        },
 #endif
 #ifdef CONFIG_PERF_EVENTS
+       /*
+        * User-space scripts rely on the existence of this file
+        * as a feature check for perf_events being enabled.
+        *
+        * So it's an ABI, do not remove!
+        */
        {
                .procname       = "perf_event_paranoid",
                .data           = &sysctl_perf_event_paranoid,