Skip to content

Commit ab2f993

Browse files
nathanchancerostedt
authored andcommitted
ftrace: Remove unused ftrace_startup_enable() stub
When building with clang + CONFIG_DYNAMIC_FTRACE=n + W=1, there is a warning: kernel/trace/ftrace.c:7194:20: error: unused function 'ftrace_startup_enable' [-Werror,-Wunused-function] static inline void ftrace_startup_enable(int command) { } ^ 1 error generated. Clang warns on instances of static inline functions in .c files with W=1 after commit 6863f56 ("kbuild: allow Clang to find unused static inline functions for W=1 build"). The ftrace_startup_enable() stub has been unused since commit e1effa0 ("ftrace: Annotate the ops operation on update"), where its use outside of the CONFIG_DYNAMIC_TRACE section was replaced by ftrace_startup_all(). Remove it to resolve the warning. Link: https://lkml.kernel.org/r/[email protected] Reported-by: kernel test robot <[email protected]> Signed-off-by: Nathan Chancellor <[email protected]> Signed-off-by: Steven Rostedt (Google) <[email protected]>
1 parent 7acf3a1 commit ab2f993

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

kernel/trace/ftrace.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7191,7 +7191,6 @@ static int __init ftrace_nodyn_init(void)
71917191
core_initcall(ftrace_nodyn_init);
71927192

71937193
static inline int ftrace_init_dyn_tracefs(struct dentry *d_tracer) { return 0; }
7194-
static inline void ftrace_startup_enable(int command) { }
71957194
static inline void ftrace_startup_all(int command) { }
71967195

71977196
# define ftrace_startup_sysctl() do { } while (0)

0 commit comments

Comments
 (0)