ftrace: Remove the now superfluous sentinel elements from ctl_table array
authorJoel Granados <j.granados@samsung.com>
Tue, 27 Jun 2023 13:30:23 +0000 (15:30 +0200)
committerJoel Granados <j.granados@samsung.com>
Wed, 24 Apr 2024 07:43:53 +0000 (09:43 +0200)
This commit comes at the tail end of a greater effort to remove the
empty elements at the end of the ctl_table arrays (sentinels) which
will reduce the overall build time size of the kernel and run time
memory bloat by ~64 bytes per sentinel (further information Link :
https://lore.kernel.org/all/ZO5Yx5JFogGi%2FcBo@bombadil.infradead.org/)

Remove sentinel elements from ftrace_sysctls and user_event_sysctls

Acked-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
Acked-by: Steven Rostedt (Google) <rostedt@goodmis.org>
Signed-off-by: Joel Granados <j.granados@samsung.com>
kernel/trace/ftrace.c
kernel/trace/trace_events_user.c

index da1710499698b0ed56ea89183d18befda56c0243..6cec53aa45a6d2f10f8b00011963b884cc7c81c6 100644 (file)
@@ -8270,7 +8270,6 @@ static struct ctl_table ftrace_sysctls[] = {
                .mode           = 0644,
                .proc_handler   = ftrace_enable_sysctl,
        },
-       {}
 };
 
 static int __init ftrace_sysctl_init(void)
index 70d428c394b68dee53cc26a08c101945ef8587cd..304ceed9fd7d428b004919ea9b709441ac4bd3df 100644 (file)
@@ -2833,7 +2833,6 @@ static struct ctl_table user_event_sysctls[] = {
                .mode           = 0644,
                .proc_handler   = set_max_user_events_sysctl,
        },
-       {}
 };
 
 static int __init trace_events_user_init(void)