#!/bin/sh
# - runtime

## Ftrace is an internal tracer designed to help out developers and
## designers of systems to find what is going on inside the kernel.
## It can be used for debugging or analyzing latencies and
## performance issues that take place outside of user-space.

. $LKP_SRC/lib/reproduce-log.sh

cd /sys/kernel/debug/tracing || die "no /sys/kernel/debug/tracing"

: ${runtime:=300}

do_test()
{
	for tracer in $(cat available_tracers)
	do
		log_eval "echo $tracer > current_tracer"
		log_eval "echo 1 > tracing_on"
		log_eval "echo 0 > tracing_on"
	done
}

. $LKP_SRC/lib/runtime_loop.sh
runtime_loop
