aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorPeter Zijlstra <a.p.zijlstra@chello.nl>2010-01-22 08:55:22 -0500
committerIngo Molnar <mingo@elte.hu>2010-01-29 03:01:36 -0500
commit81269a085669b5130058a0275aa7ba9f94abd1fa (patch)
tree66de290102b94e3044fd14648f4a822235f36f1b /arch
parent502568d563bcc37ac505a83341c0c95b88c015a8 (diff)
perf_event: x86: Fixup constraints typing issue
Constraints gets defined an u64 but in long quantities and then cast to long. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Stephane Eranian <eranian@google.com> LKML-Reference: <20100122155535.504916780@chello.nl> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch')
-rw-r--r--arch/x86/kernel/cpu/perf_event.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/x86/kernel/cpu/perf_event.c b/arch/x86/kernel/cpu/perf_event.c
index 7bd359a57839..7e181a5097ea 100644
--- a/arch/x86/kernel/cpu/perf_event.c
+++ b/arch/x86/kernel/cpu/perf_event.c
@@ -1232,7 +1232,7 @@ static int x86_schedule_events(struct cpu_hw_events *cpuc, int n, int *assign)
1232 int i, j , w, num; 1232 int i, j , w, num;
1233 int weight, wmax; 1233 int weight, wmax;
1234 unsigned long *c; 1234 unsigned long *c;
1235 u64 constraints[X86_PMC_IDX_MAX][BITS_TO_LONGS(X86_PMC_IDX_MAX)]; 1235 unsigned long constraints[X86_PMC_IDX_MAX][BITS_TO_LONGS(X86_PMC_IDX_MAX)];
1236 unsigned long used_mask[BITS_TO_LONGS(X86_PMC_IDX_MAX)]; 1236 unsigned long used_mask[BITS_TO_LONGS(X86_PMC_IDX_MAX)];
1237 struct hw_perf_event *hwc; 1237 struct hw_perf_event *hwc;
1238 1238
@@ -1249,7 +1249,7 @@ static int x86_schedule_events(struct cpu_hw_events *cpuc, int n, int *assign)
1249 */ 1249 */
1250 for (i = 0, num = n; i < n; i++, num--) { 1250 for (i = 0, num = n; i < n; i++, num--) {
1251 hwc = &cpuc->event_list[i]->hw; 1251 hwc = &cpuc->event_list[i]->hw;
1252 c = (unsigned long *)constraints[i]; 1252 c = constraints[i];
1253 1253
1254 /* never assigned */ 1254 /* never assigned */
1255 if (hwc->idx == -1) 1255 if (hwc->idx == -1)
@@ -1306,7 +1306,7 @@ static int x86_schedule_events(struct cpu_hw_events *cpuc, int n, int *assign)
1306 for (w = 1, num = n; num && w <= wmax; w++) { 1306 for (w = 1, num = n; num && w <= wmax; w++) {
1307 /* for each event */ 1307 /* for each event */
1308 for (i = 0; num && i < n; i++) { 1308 for (i = 0; num && i < n; i++) {
1309 c = (unsigned long *)constraints[i]; 1309 c = constraints[i];
1310 hwc = &cpuc->event_list[i]->hw; 1310 hwc = &cpuc->event_list[i]->hw;
1311 1311
1312 weight = bitmap_weight(c, X86_PMC_IDX_MAX); 1312 weight = bitmap_weight(c, X86_PMC_IDX_MAX);