Re: [PATCH] ftracetest: Cope properly with stack tracer not being enabled

From: Steven Rostedt
Date: Mon Mar 30 2015 - 17:36:40 EST


On Mon, 30 Mar 2015 16:21:40 +1100
Michael Ellerman <mpe@xxxxxxxxxxxxxx> wrote:

> If the stack tracer (CONFIG_STACK_TRACER) is disabled, the
> fgraph-filter-stack test blows chunks:
>
> [8] ftrace - function graph filters with stack tracer [FAIL]
> + reset_tracer
> + echo nop
> ./ftracetest: 19: /home/michael/selftests/ftrace/test.d/ftrace/fgraph-filter-stack.tc:
> cannot create /proc/sys/kernel/stack_tracer_enabled: Directory nonexistent
>
> Fix it by checking if the proc file exists before echoing to it. With
> the patch applied it fails correctly with:
>
> [8] ftrace - function graph filters with stack tracer [UNSUPPORTED]
>
> Signed-off-by: Michael Ellerman <mpe@xxxxxxxxxxxxxx>
> ---

Acked-by: Steven Rostedt <rostedt@xxxxxxxxxxx>

-- Steve
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/