Commit 5214638384a968574a5ea3df1d3b3194da32a496
Exists in
master
and in
20 other branches
Merge branch 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kerne…
…l/git/tip/linux-2.6-tip * 'perf-urgent-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip: perf tools: Fix sample type size calculation in 32 bits archs profile: Use vzalloc() rather than vmalloc() & memset()
Showing 2 changed files Side-by-side Diff
kernel/profile.c
... | ... | @@ -126,11 +126,9 @@ |
126 | 126 | if (prof_buffer) |
127 | 127 | return 0; |
128 | 128 | |
129 | - prof_buffer = vmalloc(buffer_bytes); | |
130 | - if (prof_buffer) { | |
131 | - memset(prof_buffer, 0, buffer_bytes); | |
129 | + prof_buffer = vzalloc(buffer_bytes); | |
130 | + if (prof_buffer) | |
132 | 131 | return 0; |
133 | - } | |
134 | 132 | |
135 | 133 | free_cpumask_var(prof_cpu_mask); |
136 | 134 | return -ENOMEM; |