Patch "tracing: Fix error handling to ensure instances can always be removed" has been added to the 3.10-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    tracing: Fix error handling to ensure instances can always be removed

to the 3.10-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     tracing-fix-error-handling-to-ensure-instances-can-always-be-removed.patch
and it can be found in the queue-3.10 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.


>From 609e85a70bcd0eedf4ec60639dbcfb1ab011e054 Mon Sep 17 00:00:00 2001
From: Alexander Z Lam <azl@xxxxxxxxxx>
Date: Wed, 10 Jul 2013 17:34:34 -0700
Subject: tracing: Fix error handling to ensure instances can always be removed

From: Alexander Z Lam <azl@xxxxxxxxxx>

commit 609e85a70bcd0eedf4ec60639dbcfb1ab011e054 upstream.

Remove debugfs directories for tracing instances during creation if an error
occurs causing the trace_array for that instance to not be added to
ftrace_trace_arrays. If the directory continues to exist after the error, it
cannot be removed because the respective trace_array is not in
ftrace_trace_arrays.

Link: http://lkml.kernel.org/r/1373502874-1706-2-git-send-email-azl@xxxxxxxxxx

Signed-off-by: Alexander Z Lam <azl@xxxxxxxxxx>
Cc: Vaibhav Nagarnaik <vnagarnaik@xxxxxxxxxx>
Cc: David Sharp <dhsharp@xxxxxxxxxx>
Cc: Alexander Z Lam <lambchop468@xxxxxxxxx>
Signed-off-by: Steven Rostedt <rostedt@xxxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>

---
 kernel/trace/trace.c |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

--- a/kernel/trace/trace.c
+++ b/kernel/trace/trace.c
@@ -5926,8 +5926,10 @@ static int new_instance_create(const cha
 		goto out_free_tr;
 
 	ret = event_trace_add_tracer(tr->dir, tr);
-	if (ret)
+	if (ret) {
+		debugfs_remove_recursive(tr->dir);
 		goto out_free_tr;
+	}
 
 	init_tracer_debugfs(tr, tr->dir);
 


Patches currently in stable-queue which might be from azl@xxxxxxxxxx are

queue-3.10/tracing-fix-error-handling-to-ensure-instances-can-always-be-removed.patch
queue-3.10/tracing-remove-locking-trace_types_lock-from-tracing_reset_all_online_cpus.patch
queue-3.10/tracing-miscellaneous-fixes-for-trace_array-ref-counting.patch
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]