[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3f392f10e29f651836bf28e342150a6169e6e0d9.camel@gmail.com>
Date: Mon, 03 Feb 2025 10:49:32 -0800
From: Eduard Zingerman <eddyz87@...il.com>
To: Daniel Xu <dxu@...uu.xyz>, daniel@...earbox.net, andrii@...nel.org,
ast@...nel.org
Cc: john.fastabend@...il.com, martin.lau@...ux.dev, song@...nel.org,
yonghong.song@...ux.dev, kpsingh@...nel.org, sdf@...ichev.me,
haoluo@...gle.com, jolsa@...nel.org, bpf@...r.kernel.org,
linux-kernel@...r.kernel.org, mhartmay@...ux.ibm.com, iii@...ux.ibm.com
Subject: Re: [PATCH bpf-next 3/3] bpf: verifier: Disambiguate
get_constant_map_key() errors
On Sat, 2025-02-01 at 12:58 -0700, Daniel Xu wrote:
> Refactor get_constant_map_key() to disambiguate the constant key
> value from potential error values. In the case that the key is
> negative, it could be confused for an error.
>
> It's not currently an issue, as the verifier seems to track s32 spills
> as u32. So even if the program wrongly uses a negative value for an
> arraymap key, the verifier just thinks it's an impossibly high value
> which gets correctly discarded.
>
> Refactor anyways to make things cleaner and prevent potential future
> issues.
>
> Signed-off-by: Daniel Xu <dxu@...uu.xyz>
> ---
Acked-by: Eduard Zingerman <eddyz87@...il.com>
[...]
Powered by blists - more mailing lists