summaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorMasami Hiramatsu <mhiramat@kernel.org>2019-05-07 22:55:52 +0900
committerSteven Rostedt (VMware) <rostedt@goodmis.org>2019-05-08 12:15:11 -0400
commit489fe0096b19b664b8f3bed0fd604d617a229b5a (patch)
tree327e52655bf3df8a3b4e0fbbe00cf736faa5858a /kernel
parent4dd537aca25dd2e0e8aca8b8923930cbe6240003 (diff)
downloadlinux-489fe0096b19b664b8f3bed0fd604d617a229b5a.tar.bz2
tracing: probeevent: Do not accumulate on ret variable
Do not accumulate strlen result on "ret" local variable, because it is accumulated on "total" local variable for array case. Link: http://lkml.kernel.org/r/155723735237.9149.3192150444705457531.stgit@devnote2 Fixes: 40b53b771806 ("tracing: probeevent: Add array type support") Signed-off-by: Masami Hiramatsu <mhiramat@kernel.org> Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
Diffstat (limited to 'kernel')
-rw-r--r--kernel/trace/trace_probe_tmpl.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/trace/trace_probe_tmpl.h b/kernel/trace/trace_probe_tmpl.h
index 4737bb8c07a3..c30c61f12ddd 100644
--- a/kernel/trace/trace_probe_tmpl.h
+++ b/kernel/trace/trace_probe_tmpl.h
@@ -88,7 +88,7 @@ stage3:
/* 3rd stage: store value to buffer */
if (unlikely(!dest)) {
if (code->op == FETCH_OP_ST_STRING) {
- ret += fetch_store_strlen(val + code->offset);
+ ret = fetch_store_strlen(val + code->offset);
code++;
goto array;
} else