[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZoM6CUhbWuAFuHjP@krava>
Date: Tue, 2 Jul 2024 01:21:45 +0200
From: Jiri Olsa <olsajiri@...il.com>
To: Christian Kujau <lists@...dbynature.de>,
Daniel Borkmann <daniel@...earbox.net>
Cc: linux-kernel@...r.kernel.org, Martin KaFai Lau <martin.lau@...ux.dev>,
bpf@...r.kernel.org, Alexei Starovoitov <ast@...nel.org>,
Andrii Nakryiko <andrii@...nel.org>,
Eduard Zingerman <eddyz87@...il.com>, Song Liu <song@...nel.org>,
Yonghong Song <yonghong.song@...ux.dev>,
John Fastabend <john.fastabend@...il.com>,
KP Singh <kpsingh@...nel.org>, Stanislav Fomichev <sdf@...gle.com>,
Hao Luo <haoluo@...gle.com>, regressions@...ts.linux.dev,
patchwork-bot+netdevbpf@...nel.org, peter.ujfalusi@...el.com
Subject: Re: [regression] bpf_local_storage.c:785:60: error: ‘kvmalloc_array_node_noprof’ sizes specified with ‘sizeof’
On Mon, Jul 01, 2024 at 10:56:22PM +0200, Christian Kujau wrote:
> 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/
hum.. it's in bpf-next and linux-next tree [1], but not sure it's
on the way for next release.. Daniel?
jirka
[1] 6f130e4d4a5f bpf: Fix order of args in call to bpf_map_kvcalloc
> --
> BOFH excuse #424:
>
> operation failed because: there is no message for this error (#1014)
Powered by blists - more mailing lists