Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 06fa75ab authored by Steven Rostedt's avatar Steven Rostedt Committed by Thomas Gleixner
Browse files

ftrace: add TRACE_STACK and TRACE_SPECIAL to selftest validation



The selftest validation code checks for valid entries in the trace buffer.
TRACE_STACK and TRACE_SPECIAL have been added to the code but not to
the validator. This patch adds the two to prevent them from flagging a
failure in the selftest.

Signed-off-by: default avatarSteven Rostedt <srostedt@redhat.com>
Signed-off-by: default avatarIngo Molnar <mingo@elte.hu>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
parent 4fe8c304
Loading
Loading
Loading
Loading
+3 −1
Original line number Original line Diff line number Diff line
@@ -9,6 +9,8 @@ static inline int trace_valid_entry(struct trace_entry *entry)
	case TRACE_FN:
	case TRACE_FN:
	case TRACE_CTX:
	case TRACE_CTX:
	case TRACE_WAKE:
	case TRACE_WAKE:
	case TRACE_STACK:
	case TRACE_SPECIAL:
		return 1;
		return 1;
	}
	}
	return 0;
	return 0;
@@ -180,7 +182,7 @@ int trace_selftest_startup_dynamic_tracing(struct tracer *trace,


	/* we should only have one item */
	/* we should only have one item */
	if (!ret && count != 1) {
	if (!ret && count != 1) {
		printk(KERN_CONT ".. filter failed ..");
		printk(KERN_CONT ".. filter failed count=%ld ..", count);
		ret = -1;
		ret = -1;
		goto out;
		goto out;
	}
	}