diff options
author | Namhyung Kim <namhyung.kim@lge.com> | 2013-04-01 21:46:23 +0900 |
---|---|---|
committer | Ben Hutchings <ben@decadent.org.uk> | 2013-04-25 20:25:36 +0100 |
commit | fb8384c36adbba5af69cc0c6fcb92d8c7135835d (patch) | |
tree | 0b428181d6ff1076ae3bac15e9dddcda65a061e0 /kernel | |
parent | 9dc0052f9b53d6f02f7a2b405b0f19d262cf7bda (diff) |
tracing: Fix double free when function profile init failed
commit 83e03b3fe4daffdebbb42151d5410d730ae50bd1 upstream.
On the failure path, stat->start and stat->pages will refer same page.
So it'll attempt to free the same page again and get kernel panic.
Link: http://lkml.kernel.org/r/1364820385-32027-1-git-send-email-namhyung@kernel.org
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Namhyung Kim <namhyung.kim@lge.com>
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/trace/ftrace.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c index 1b378d04573..bed7991e984 100644 --- a/kernel/trace/ftrace.c +++ b/kernel/trace/ftrace.c @@ -572,7 +572,6 @@ int ftrace_profile_pages_init(struct ftrace_profile_stat *stat) free_page(tmp); } - free_page((unsigned long)stat->pages); stat->pages = NULL; stat->start = NULL; |