aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc')
-rw-r--r--arch/powerpc/platforms/pseries/hvCall_inst.c4
-rw-r--r--arch/powerpc/platforms/pseries/lpar.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/arch/powerpc/platforms/pseries/hvCall_inst.c b/arch/powerpc/platforms/pseries/hvCall_inst.c
index f106662f4381..c9311cfdfcac 100644
--- a/arch/powerpc/platforms/pseries/hvCall_inst.c
+++ b/arch/powerpc/platforms/pseries/hvCall_inst.c
@@ -109,7 +109,7 @@ static void probe_hcall_entry(void *ignored, unsigned long opcode, unsigned long
109 if (opcode > MAX_HCALL_OPCODE) 109 if (opcode > MAX_HCALL_OPCODE)
110 return; 110 return;
111 111
112 h = &get_cpu_var(hcall_stats)[opcode / 4]; 112 h = &__get_cpu_var(hcall_stats)[opcode / 4];
113 h->tb_start = mftb(); 113 h->tb_start = mftb();
114 h->purr_start = mfspr(SPRN_PURR); 114 h->purr_start = mfspr(SPRN_PURR);
115} 115}
@@ -126,8 +126,6 @@ static void probe_hcall_exit(void *ignored, unsigned long opcode, unsigned long
126 h->num_calls++; 126 h->num_calls++;
127 h->tb_total += mftb() - h->tb_start; 127 h->tb_total += mftb() - h->tb_start;
128 h->purr_total += mfspr(SPRN_PURR) - h->purr_start; 128 h->purr_total += mfspr(SPRN_PURR) - h->purr_start;
129
130 put_cpu_var(hcall_stats);
131} 129}
132 130
133static int __init hcall_inst_init(void) 131static int __init hcall_inst_init(void)
diff --git a/arch/powerpc/platforms/pseries/lpar.c b/arch/powerpc/platforms/pseries/lpar.c
index 27a49508b410..dc36ea6c7727 100644
--- a/arch/powerpc/platforms/pseries/lpar.c
+++ b/arch/powerpc/platforms/pseries/lpar.c
@@ -554,6 +554,7 @@ void __trace_hcall_entry(unsigned long opcode, unsigned long *args)
554 goto out; 554 goto out;
555 555
556 (*depth)++; 556 (*depth)++;
557 preempt_disable();
557 trace_hcall_entry(opcode, args); 558 trace_hcall_entry(opcode, args);
558 (*depth)--; 559 (*depth)--;
559 560
@@ -576,6 +577,7 @@ void __trace_hcall_exit(long opcode, unsigned long retval,
576 577
577 (*depth)++; 578 (*depth)++;
578 trace_hcall_exit(opcode, retval, retbuf); 579 trace_hcall_exit(opcode, retval, retbuf);
580 preempt_enable();
579 (*depth)--; 581 (*depth)--;
580 582
581out: 583out: