aboutsummaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'kernel')
-rw-r--r--kernel/trace/trace_kprobe.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/kernel/trace/trace_kprobe.c b/kernel/trace/trace_kprobe.c
index 0b7386a54b1e..6e86fbbae337 100644
--- a/kernel/trace/trace_kprobe.c
+++ b/kernel/trace/trace_kprobe.c
@@ -733,8 +733,6 @@ static __kprobes void kprobe_trace_func(struct kprobe *kp, struct pt_regs *regs)
733 unsigned long irq_flags; 733 unsigned long irq_flags;
734 struct ftrace_event_call *call = &tp->call; 734 struct ftrace_event_call *call = &tp->call;
735 735
736 tp->nhit++;
737
738 local_save_flags(irq_flags); 736 local_save_flags(irq_flags);
739 pc = preempt_count(); 737 pc = preempt_count();
740 738
@@ -767,8 +765,6 @@ static __kprobes void kretprobe_trace_func(struct kretprobe_instance *ri,
767 unsigned long irq_flags; 765 unsigned long irq_flags;
768 struct ftrace_event_call *call = &tp->call; 766 struct ftrace_event_call *call = &tp->call;
769 767
770 tp->nhit++;
771
772 local_save_flags(irq_flags); 768 local_save_flags(irq_flags);
773 pc = preempt_count(); 769 pc = preempt_count();
774 770
@@ -1075,6 +1071,8 @@ int kprobe_dispatcher(struct kprobe *kp, struct pt_regs *regs)
1075{ 1071{
1076 struct trace_probe *tp = container_of(kp, struct trace_probe, rp.kp); 1072 struct trace_probe *tp = container_of(kp, struct trace_probe, rp.kp);
1077 1073
1074 tp->nhit++;
1075
1078 if (tp->flags & TP_FLAG_TRACE) 1076 if (tp->flags & TP_FLAG_TRACE)
1079 kprobe_trace_func(kp, regs); 1077 kprobe_trace_func(kp, regs);
1080#ifdef CONFIG_PERF_EVENTS 1078#ifdef CONFIG_PERF_EVENTS
@@ -1089,6 +1087,8 @@ int kretprobe_dispatcher(struct kretprobe_instance *ri, struct pt_regs *regs)
1089{ 1087{
1090 struct trace_probe *tp = container_of(ri->rp, struct trace_probe, rp); 1088 struct trace_probe *tp = container_of(ri->rp, struct trace_probe, rp);
1091 1089
1090 tp->nhit++;
1091
1092 if (tp->flags & TP_FLAG_TRACE) 1092 if (tp->flags & TP_FLAG_TRACE)
1093 kretprobe_trace_func(ri, regs); 1093 kretprobe_trace_func(ri, regs);
1094#ifdef CONFIG_PERF_EVENTS 1094#ifdef CONFIG_PERF_EVENTS