[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3084f512-7476-4de7-9c28-92546d0358c7@linux.dev>
Date: Wed, 13 Nov 2024 14:06:18 +0000
From: Vadim Fedorenko <vadim.fedorenko@...ux.dev>
To: Hardevsinh Palaniya <hardevsinh.palaniya@...iconsignals.io>,
ast@...nel.org, list+bpf@...edi.org
Cc: tarang.raval@...iconsignals.io, Daniel Borkmann <daniel@...earbox.net>,
Andrii Nakryiko <andrii@...nel.org>, Martin KaFai Lau
<martin.lau@...ux.dev>, 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@...ichev.me>, Hao Luo <haoluo@...gle.com>,
Jiri Olsa <jolsa@...nel.org>, Vineet Gupta <vgupta@...nel.org>,
bpf@...r.kernel.org, linux-snps-arc@...ts.infradead.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] ARC: bpf: Correct conditional check in 'check_jmp_32'
On 13/11/2024 13:41, Hardevsinh Palaniya wrote:
> The original code checks 'if (ARC_CC_AL)', which is always true since
> ARC_CC_AL is a constant. This makes the check redundant and likely
> obscures the intention of verifying whether the jump is conditional.
>
> Updates the code to check cond == ARC_CC_AL instead, reflecting the intent
> to differentiate conditional from unconditional jumps.
>
> Suggested-by: Vadim Fedorenko <vadim.fedorenko@...ux.dev>
> Signed-off-by: Hardevsinh Palaniya <hardevsinh.palaniya@...iconsignals.io>
> ---
>
> Changelog in V2:
>
> - Changed subject line
> - Updated condition check to 'if (cond == ARC_CC_AL)' instead of removing it
>
> Link for v1: https://lore.kernel.org/bpf/e6d27adb-151c-46c1-9668-1cd2b492321b@linux.dev/T/#t
> ---
Reviewed-by: Vadim Fedorenko <vadim.fedorenko@...ux.dev>
Powered by blists - more mailing lists