From: Ihor Solodrai <ihor.solodrai@linux.dev>
To: Alexei Starovoitov <alexei.starovoitov@gmail.com>
Cc: Song Liu <song@kernel.org>, bpf <bpf@vger.kernel.org>,
Kernel Team <kernel-team@meta.com>,
Andrii Nakryiko <andrii@kernel.org>, Eduard <eddyz87@gmail.com>,
Alexei Starovoitov <ast@kernel.org>,
Daniel Borkmann <daniel@iogearbox.net>,
Martin KaFai Lau <martin.lau@linux.dev>,
Jakub Kicinski <kuba@kernel.org>,
brauner@kernel.org
Subject: Re: [PATCH v2 bpf-next] selftests/bpf: Fix cgroup_xattr/read_cgroupfs_xattr
Date: Fri, 27 Jun 2025 15:05:51 -0700 [thread overview]
Message-ID: <fbdb8883-cffe-4764-889b-6d00f2058e75@linux.dev> (raw)
In-Reply-To: <c0b17b50-3d8a-4e63-be6e-d4cd2564a49e@linux.dev>
On 6/27/25 2:56 PM, Ihor Solodrai wrote:
> On 6/27/25 2:38 PM, Alexei Starovoitov wrote:
>> On Fri, Jun 27, 2025 at 2:36 PM Ihor Solodrai
>> <ihor.solodrai@linux.dev> wrote:
>>>
>>> On 6/27/25 2:34 PM, Alexei Starovoitov wrote:
>>>> On Fri, Jun 27, 2025 at 2:19 PM Ihor Solodrai
>>>> <ihor.solodrai@linux.dev> wrote:
>>>>>
>>>>> On 6/27/25 12:12 PM, Song Liu wrote:
>>>>>> cgroup_xattr/read_cgroupfs_xattr has two issues:
>>>>>>
>>>>>> 1. cgroup_xattr/read_cgroupfs_xattr messes up lo without creating
>>>>>> a netns
>>>>>> first. This causes issue with other tests.
>>>>>>
>>>>>> Fix this by using a different hook (lsm.s/file_open) and not
>>>>>> messing
>>>>>> with lo.
>>>>>>
>>>>>> 2. cgroup_xattr/read_cgroupfs_xattr sets up cgroups without proper
>>>>>> mount namespaces.
>>>>>>
>>>>>> Fix this by using the existing cgroup helpers. A new helper
>>>>>> set_cgroup_xattr() is added to set xattr on cgroup files.
>>>>>>
>>>>>> Fixes: f4fba2d6d282 ("selftests/bpf: Add tests for
>>>>>> bpf_cgroup_read_xattr")
>>>>>> Reported-by: Alexei Starovoitov <ast@kernel.org>
>>>>>> Closes: https://lore.kernel.org/bpf/
>>>>>> CAADnVQ+iqMi2HEj_iH7hsx+XJAsqaMWqSDe4tzcGAnehFWA9Sw@mail.gmail.com/
>>>>>> Signed-off-by: Song Liu <song@kernel.org>
>>>>>>
>>>>>> ---
>>>>>> Changes v1 => v2:
>>>>>> 1. Add the second fix above.
>>>>>>
>>>>>> v1: https://lore.kernel.org/bpf/20250627165831.2979022-1-
>>>>>> song@kernel.org/
>>>>>> ---
>>>>>> tools/testing/selftests/bpf/cgroup_helpers.c | 21 ++++
>>>>>> tools/testing/selftests/bpf/cgroup_helpers.h | 4 +
>>>>>> .../selftests/bpf/prog_tests/cgroup_xattr.c | 117 +++
>>>>>> +--------------
>>>>>> .../selftests/bpf/progs/read_cgroupfs_xattr.c | 4 +-
>>>>>> 4 files changed, 49 insertions(+), 97 deletions(-)
>>>>>
>>>>> Hi Song.
>>>>>
>>>>> I tried this patch on BPF CI, and it appears it fixes the hanging
>>>>> failure we've been seeing today on bpf-next and netdev.
>>>>> I am going to add it to ci/diffs.
>>>>
>>>> Applied to bpf-next already.
>>>
>>> CI patches apply to all base branches. My understanding is, it's needed
>>> at least for netdev too.
>>
>> How is that possible?
>>
>> The offending commit is only in /master and in /for-next branches,
>> while /for-next is there for linux-next only.
>
> I am not sure.
>
> I compared CI logs between bpf-next and netdev runs that both were
> cancelled due to 100min job timeout, and they are very similar.
>
> netdev: https://github.com/kernel-patches/bpf/actions/runs/15932863319/
> job/44946276955
> bpf-next: https://github.com/kernel-patches/bpf/actions/
> runs/15934258609/job/44950981852
>
> So the root cause is likely the same.
>
> And most recent netdev (with this patch applied) is green:
> https://github.com/kernel-patches/bpf/actions/runs/15936292169
>
> CC Jakub
>
>
Apparently offending patches were merged by Christian Brauner:
https://github.com/linux-netdev/testing-bpf-ci/commit/13b0cce9e294f8ddf228b9db3e01d76ac29872f2
next prev parent reply other threads:[~2025-06-27 22:06 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-06-27 19:12 [PATCH v2 bpf-next] selftests/bpf: Fix cgroup_xattr/read_cgroupfs_xattr Song Liu
2025-06-27 20:50 ` Eduard Zingerman
2025-06-27 21:19 ` Ihor Solodrai
2025-06-27 21:34 ` Alexei Starovoitov
2025-06-27 21:36 ` Ihor Solodrai
2025-06-27 21:38 ` Alexei Starovoitov
2025-06-27 21:56 ` Ihor Solodrai
2025-06-27 22:05 ` Ihor Solodrai [this message]
2025-06-27 23:19 ` Alexei Starovoitov
2025-06-30 21:49 ` Ihor Solodrai
2025-06-30 22:11 ` Alexei Starovoitov
2025-06-30 22:22 ` Ihor Solodrai
2025-06-27 21:40 ` patchwork-bot+netdevbpf
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=fbdb8883-cffe-4764-889b-6d00f2058e75@linux.dev \
--to=ihor.solodrai@linux.dev \
--cc=alexei.starovoitov@gmail.com \
--cc=andrii@kernel.org \
--cc=ast@kernel.org \
--cc=bpf@vger.kernel.org \
--cc=brauner@kernel.org \
--cc=daniel@iogearbox.net \
--cc=eddyz87@gmail.com \
--cc=kernel-team@meta.com \
--cc=kuba@kernel.org \
--cc=martin.lau@linux.dev \
--cc=song@kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.