cyclictest: move debugfs init code to its own function

A function added by a future commit will want to call
this code too.

Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Signed-off-by: John Kacur <jkacur@redhat.com>
diff --git a/src/cyclictest/cyclictest.c b/src/cyclictest/cyclictest.c
index fe79345..b9571f5 100644
--- a/src/cyclictest/cyclictest.c
+++ b/src/cyclictest/cyclictest.c
@@ -543,11 +543,8 @@
 		warn("unable to open trace_marker file: %s\n", path);
 }
 
-static void setup_tracer(void)
+static void debugfs_prepare(void)
 {
-	if (!tracelimit || notrace)
-		return;
-
 	if (mount_debugfs(NULL))
 		fatal("could not mount debugfs");
 
@@ -562,6 +559,14 @@
 			    "TRACERs not configured?\n", testname);
 	} else
 		fileprefix = procfileprefix;
+}
+
+static void setup_tracer(void)
+{
+	if (!tracelimit || notrace)
+		return;
+
+	debugfs_prepare();
 
 	if (kernelversion >= KV_26_33) {
 		int ret;