[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <331d97f7-c1de-4b46-a1e5-75a3261d4e97@linux.dev>
Date: Fri, 28 Feb 2025 10:55:19 -0800
From: Yonghong Song <yonghong.song@...ux.dev>
To: Breno Leitao <leitao@...ian.org>, Martin KaFai Lau
<martin.lau@...ux.dev>, Daniel Borkmann <daniel@...earbox.net>,
John Fastabend <john.fastabend@...il.com>,
Alexei Starovoitov <ast@...nel.org>, Andrii Nakryiko <andrii@...nel.org>,
Eduard Zingerman <eddyz87@...il.com>, Song Liu <song@...nel.org>,
KP Singh <kpsingh@...nel.org>, Stanislav Fomichev <sdf@...ichev.me>,
Hao Luo <haoluo@...gle.com>, Jiri Olsa <jolsa@...nel.org>,
"David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Simon Horman <horms@...nel.org>
Cc: bpf@...r.kernel.org, netdev@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next] net: filter: Avoid shadowing variable in
bpf_convert_ctx_access()
On 2/28/25 10:43 AM, Breno Leitao wrote:
> Rename the local variable 'off' to 'offset' to avoid shadowing the existing
> 'off' variable that is declared as an `int` in the outer scope of
> bpf_convert_ctx_access().
>
> This fixes a compiler warning:
>
> net/core/filter.c:9679:8: warning: declaration shadows a local variable [-Wshadow]
>
> Signed-off-by: Breno Leitao <leitao@...ian.org>
Make sense to me.
Acked-by: Yonghong Song <yonghong.song@...ux.dev>
Powered by blists - more mailing lists