ftrace: Return ENOTSUPP when DYNAMIC_FTRACE_WITH_DIRECT_CALLS is not configured
authorAlexei Starovoitov <alexei.starovoitov@gmail.com>
Wed, 20 Nov 2019 23:32:25 +0000 (18:32 -0500)
committerSteven Rostedt (VMware) <rostedt@goodmis.org>
Wed, 20 Nov 2019 23:52:23 +0000 (18:52 -0500)
commiteb01fedc3d539f9443082aa2384c5d1ca26ed5c1
treee01210c8c124d22e2d77fd35c9b69c285ba840a5
parent46f9469247c6f4697cbbf37e4b3961120bf07f29
ftrace: Return ENOTSUPP when DYNAMIC_FTRACE_WITH_DIRECT_CALLS is not configured

When CONFIG_DYNAMIC_FTRACE_WITH_DIRECT_CALLS is not set it's best to
have the stub functions return ENOTSUPP instead of ENODEV,
otherwise ENODEV is a valid error when ip is incorrect which is
indistinguishable from ftrace not compiled in.

Link: http://lkml.kernel.org/r/CAADnVQ+OzTikM9EhrfsC7NFsVYhATW1SVHxK64w3xn9qpk81pg@mail.gmail.com
Signed-off-by: Alexei Starovoitov <ast@kernel.org>
Signed-off-by: Steven Rostedt (VMware) <rostedt@goodmis.org>
include/linux/ftrace.h