From: Ricardo Ribalda Date: Wed, 21 Dec 2022 19:55:29 +0000 (+0100) Subject: bpf: Remove unused field initialization in bpf's ctl_table X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=cfca00767febba5f4f5e300fab10e0974491dd4b;p=linux.git bpf: Remove unused field initialization in bpf's ctl_table Maxlen is used by standard proc_handlers such as proc_dointvec(), but in this case we have our own proc_handler via bpf_stats_handler(). Therefore, remove the initialization. Signed-off-by: Ricardo Ribalda Signed-off-by: Daniel Borkmann Acked-by: Stanislav Fomichev Link: https://lore.kernel.org/bpf/20221221-bpf-syscall-v1-0-9550f5f2c3fc@chromium.org --- diff --git a/kernel/bpf/syscall.c b/kernel/bpf/syscall.c index 35972afb68504..8e55456bd6489 100644 --- a/kernel/bpf/syscall.c +++ b/kernel/bpf/syscall.c @@ -5319,7 +5319,6 @@ static struct ctl_table bpf_syscall_table[] = { { .procname = "bpf_stats_enabled", .data = &bpf_stats_enabled_key.key, - .maxlen = sizeof(bpf_stats_enabled_key), .mode = 0644, .proc_handler = bpf_stats_handler, },