[PATCH] perf_counter: Fix atomic_set vs. atomic64_t type mismatch
From: Paul Mackerras
Date: Sat Jun 13 2009 - 03:07:34 EST
Using atomic_set on an atomic64_t variable gives a compiler warning on
powerpc, and won't give the desired result at runtime. This fixes an
instance of this error in the perf_counter code.
Signed-off-by: Paul Mackerras <paulus@xxxxxxxxx>
---
kernel/perf_counter.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/kernel/perf_counter.c b/kernel/perf_counter.c
index 29b685f..8d14a73 100644
--- a/kernel/perf_counter.c
+++ b/kernel/perf_counter.c
@@ -1283,7 +1283,7 @@ static void perf_ctx_adjust_freq(struct perf_counter_context *ctx)
if (!interrupts) {
perf_disable();
counter->pmu->disable(counter);
- atomic_set(&hwc->period_left, 0);
+ atomic64_set(&hwc->period_left, 0);
counter->pmu->enable(counter);
perf_enable();
}
--
1.6.0.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/