aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/trace
diff options
context:
space:
mode:
authorWenji Huang <wenji.huang@oracle.com>2010-02-24 02:40:26 -0500
committerSteven Rostedt <rostedt@goodmis.org>2010-02-25 10:42:55 -0500
commit7b60997f73865b019e595720185c85285ca3df9a (patch)
tree4b441b810a31484cf28621b7690dadcf71a19e3e /kernel/trace
parentc85f3a91f84d5a85f179c2504bb7a39370c82b41 (diff)
tracing: Simplify memory recycle of trace_define_field
Discard freeing field->type since it is not necessary. Reviewed-by: Li Zefan <lizf@cn.fujitsu.com> Signed-off-by: Wenji Huang <wenji.huang@oracle.com> LKML-Reference: <1266997226-6833-5-git-send-email-wenji.huang@oracle.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Diffstat (limited to 'kernel/trace')
-rw-r--r--kernel/trace/trace_events.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c
index c2a3077b7353..3f972ad98d04 100644
--- a/kernel/trace/trace_events.c
+++ b/kernel/trace/trace_events.c
@@ -60,10 +60,8 @@ int trace_define_field(struct ftrace_event_call *call, const char *type,
60 return 0; 60 return 0;
61 61
62err: 62err:
63 if (field) { 63 if (field)
64 kfree(field->name); 64 kfree(field->name);
65 kfree(field->type);
66 }
67 kfree(field); 65 kfree(field);
68 66
69 return -ENOMEM; 67 return -ENOMEM;