aboutsummaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
authorPeter Zijlstra <a.p.zijlstra@chello.nl>2009-07-22 11:13:50 +0200
committerPeter Zijlstra <a.p.zijlstra@chello.nl>2009-07-22 18:05:55 +0200
commit573402db02746179b3f95f83a11a787501f52d0a (patch)
tree111fb9d0b65d31cb9308a84164f111874d2522ae /kernel
parentc9f73a3dd27e03411f18a58c0814d51392d2b17a (diff)
perf_counter: Plug more stack leaks
Per example of Arjan's patch, I went through and found a few more. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/perf_counter.c23
1 files changed, 21 insertions, 2 deletions
diff --git a/kernel/perf_counter.c b/kernel/perf_counter.c
index ff854fd89a8..e1d6a3aa133 100644
--- a/kernel/perf_counter.c
+++ b/kernel/perf_counter.c
@@ -2897,8 +2897,11 @@ void perf_counter_fork(struct task_struct *task)
.event = {
.header = {
.type = PERF_EVENT_FORK,
+ .misc = 0,
.size = sizeof(fork_event.event),
},
+ /* .pid */
+ /* .ppid */
},
};
@@ -3008,8 +3011,16 @@ void perf_counter_comm(struct task_struct *task)
comm_event = (struct perf_comm_event){
.task = task,
+ /* .comm */
+ /* .comm_size */
.event = {
- .header = { .type = PERF_EVENT_COMM, },
+ .header = {
+ .type = PERF_EVENT_COMM,
+ .misc = 0,
+ /* .size */
+ },
+ /* .pid */
+ /* .tid */
},
};
@@ -3160,8 +3171,16 @@ void __perf_counter_mmap(struct vm_area_struct *vma)
mmap_event = (struct perf_mmap_event){
.vma = vma,
+ /* .file_name */
+ /* .file_size */
.event = {
- .header = { .type = PERF_EVENT_MMAP, },
+ .header = {
+ .type = PERF_EVENT_MMAP,
+ .misc = 0,
+ /* .size */
+ },
+ /* .pid */
+ /* .tid */
.start = vma->vm_start,
.len = vma->vm_end - vma->vm_start,
.pgoff = vma->vm_pgoff,