Merge tag 'iwlwifi-next-for-kalle-2014-12-30' of https://git.kernel.org/pub/scm/linux...
[cascardo/linux.git] / arch / powerpc / kernel / hw_breakpoint.c
index 1f7d84e..05e804c 100644 (file)
@@ -63,7 +63,7 @@ int hw_breakpoint_slots(int type)
 int arch_install_hw_breakpoint(struct perf_event *bp)
 {
        struct arch_hw_breakpoint *info = counter_arch_bp(bp);
-       struct perf_event **slot = &__get_cpu_var(bp_per_reg);
+       struct perf_event **slot = this_cpu_ptr(&bp_per_reg);
 
        *slot = bp;
 
@@ -88,7 +88,7 @@ int arch_install_hw_breakpoint(struct perf_event *bp)
  */
 void arch_uninstall_hw_breakpoint(struct perf_event *bp)
 {
-       struct perf_event **slot = &__get_cpu_var(bp_per_reg);
+       struct perf_event **slot = this_cpu_ptr(&bp_per_reg);
 
        if (*slot != bp) {
                WARN_ONCE(1, "Can't find the breakpoint");
@@ -226,7 +226,7 @@ int __kprobes hw_breakpoint_handler(struct die_args *args)
         */
        rcu_read_lock();
 
-       bp = __get_cpu_var(bp_per_reg);
+       bp = __this_cpu_read(bp_per_reg);
        if (!bp)
                goto out;
        info = counter_arch_bp(bp);