From: Christian Kujau <lists@nerdbynature.de>
To: linux-kernel@vger.kernel.org
Cc: Martin KaFai Lau <martin.lau@linux.dev>,
Alexei Starovoitov <ast@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
Andrii Nakryiko <andrii@kernel.org>,
Eduard Zingerman <eddyz87@gmail.com>, Song Liu <song@kernel.org>,
Yonghong Song <yonghong.song@linux.dev>,
John Fastabend <john.fastabend@gmail.com>,
KP Singh <kpsingh@kernel.org>,
Stanislav Fomichev <sdf@google.com>, Hao Luo <haoluo@google.com>,
Jiri Olsa <jolsa@kernel.org>,
regressions@lists.linux.dev, patchwork-bot+netdevbpf@kernel.org,
peter.ujfalusi@intel.com
Subject: [regression] bpf_local_storage.c:785:60: error: ‘kvmalloc_array_node_noprof’ sizes specified with ‘sizeof’
Date: Mon, 1 Jul 2024 22:56:22 +0200 (CEST) [thread overview]
Message-ID: <d0dd2457-ab58-1b08-caa4-93eaa2de221e@nerdbynature.de> (raw)
[-- Attachment #1: Type: text/plain, Size: 1405 bytes --]
This has been brought up before along with a patch[0] but has not been
pushed to mainline:
$ make allnoconfig
$ enable CONFIG_WERROR and CONFIG_BPF
$ make
[...]
kernel/bpf/bpf_local_storage.c: In function ‘bpf_local_storage_map_alloc’:
kernel/bpf/bpf_local_storage.c:785:60: error: ‘kvmalloc_array_node_noprof’ sizes specified with ‘sizeof’ in the earlier
argument and not in the later argument [-Werror=calloc-transposed-args]
785 | smap->buckets = bpf_map_kvcalloc(&smap->map, sizeof(*smap->buckets),
| ^
I always compile kernels with CONFIG_WERROR=y and I'm surprised that this
has not been caught by any build bots yet (or I did not see those
reports), the help text even says "If in doubt, say Y", so I'm very
puzzled why almost nobody else would be affected by this. The compilation
error happens on a Fedora 40 laptop, with gcc 14.1.1 20240620 (Red Hat
14.1.1-6) installed.
The fix posted in [0] does fix the compilation errors, but maybe never
made it to the correct trees to be included upstream? We are already in
-rc6 and I fear that the next release will be shipped with that problem.
Thanks,
Christian.
[0] https://lore.kernel.org/bpf/363ad8d1-a2d2-4fca-b66a-3d838eb5def9@intel.com/T/
--
BOFH excuse #424:
operation failed because: there is no message for this error (#1014)
[-- Attachment #2: Type: application/gzip, Size: 9149 bytes --]
next reply other threads:[~2024-07-01 21:02 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-07-01 20:56 Christian Kujau [this message]
2024-07-01 23:21 ` Jiri Olsa
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d0dd2457-ab58-1b08-caa4-93eaa2de221e@nerdbynature.de \
--to=lists@nerdbynature.de \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=daniel@iogearbox.net \
--cc=eddyz87@gmail.com \
--cc=haoluo@google.com \
--cc=john.fastabend@gmail.com \
--cc=jolsa@kernel.org \
--cc=kpsingh@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=martin.lau@linux.dev \
--cc=patchwork-bot+netdevbpf@kernel.org \
--cc=peter.ujfalusi@intel.com \
--cc=regressions@lists.linux.dev \
--cc=sdf@google.com \
--cc=song@kernel.org \
--cc=yonghong.song@linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®