aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/perf_counter.c
diff options
context:
space:
mode:
authorPaul Mackerras <paulus@samba.org>2009-02-26 06:43:46 -0500
committerPaul Mackerras <paulus@samba.org>2009-02-26 06:43:46 -0500
commitf3dfd2656deb81a0addee4f4ceff66b50a387388 (patch)
tree2d43269668b2a468a2bd2988b1937f9a71d458b4 /kernel/perf_counter.c
parent742bd95ba96e19b3f7196c3a0834ebc17c8ba006 (diff)
perfcounters: fix a few minor cleanliness issues
This fixes three issues noticed by Arnd Bergmann: - Add #ifdef __KERNEL__ and move some things around in perf_counter.h to make sure only the bits that userspace needs are exported to userspace. - Use __u64, __s64, __u32 types in the structs exported to userspace rather than u64, s64, u32. - Make the sys_perf_counter_open syscall available to the SPUs on Cell platforms. And one issue that I noticed in looking at the code again: - Wrap the perf_counter_open syscall with SYSCALL_DEFINE4 so we get the proper handling of int arguments on ppc64 (and some other 64-bit architectures). Reported-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'kernel/perf_counter.c')
-rw-r--r--kernel/perf_counter.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/kernel/perf_counter.c b/kernel/perf_counter.c
index ad62965828d3..16b14ba99d34 100644
--- a/kernel/perf_counter.c
+++ b/kernel/perf_counter.c
@@ -1690,9 +1690,9 @@ perf_counter_alloc(struct perf_counter_hw_event *hw_event,
1690 * @cpu: target cpu 1690 * @cpu: target cpu
1691 * @group_fd: group leader counter fd 1691 * @group_fd: group leader counter fd
1692 */ 1692 */
1693asmlinkage int 1693SYSCALL_DEFINE4(perf_counter_open,
1694sys_perf_counter_open(struct perf_counter_hw_event *hw_event_uptr __user, 1694 const struct perf_counter_hw_event __user *, hw_event_uptr,
1695 pid_t pid, int cpu, int group_fd) 1695 pid_t, pid, int, cpu, int, group_fd)
1696{ 1696{
1697 struct perf_counter *counter, *group_leader; 1697 struct perf_counter *counter, *group_leader;
1698 struct perf_counter_hw_event hw_event; 1698 struct perf_counter_hw_event hw_event;