Commit a00dc319 authored by Stephane Eranian's avatar Stephane Eranian Committed by Arnaldo Carvalho de Melo

perf record: Fix branch_stack type in perf_record_opts

The attr.branch_sample_type field is defined as u64 by the API.  As
such, we need to ensure the variable holding the value of the branch
stack filters is also u64 otherwise we may lose bits in the future.

Note also that the bogus definition of the field in perf_record_opts
caused problems on big-endian PPC systems.  Thanks to Anshuman Khandual
for tracking the problem on PPC.
Reported-by: default avatarAnshuman Khandual <khandual@linux.vnet.ibm.com>
Signed-off-by: default avatarStephane Eranian <eranian@google.com>
Cc: Anshuman Khandual <khandual@linux.vnet.ibm.com>
Cc: Ingo Molnar <mingo@elte.hu>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/20120525211344.GA7729@quadSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent c410431c
...@@ -227,7 +227,7 @@ struct perf_record_opts { ...@@ -227,7 +227,7 @@ struct perf_record_opts {
unsigned int freq; unsigned int freq;
unsigned int mmap_pages; unsigned int mmap_pages;
unsigned int user_freq; unsigned int user_freq;
int branch_stack; u64 branch_stack;
u64 default_interval; u64 default_interval;
u64 user_interval; u64 user_interval;
}; };
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment