Re: [PATCH v4 4/4] selftests: pidfd: add tests for PIDFD_SELF_*

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 25, 2024 at 04:10:37PM +0800, kernel test robot wrote:
>
>
> Hello,
>
> kernel test robot noticed "kernel-selftests.cgroup.make.fail" on:
>
> commit: 930cb1423ee2522760ffde43455b14df5c0d5487 ("[PATCH v4 4/4] selftests: pidfd: add tests for PIDFD_SELF_*")
> url: https://github.com/intel-lab-lkp/linux/commits/Lorenzo-Stoakes/pidfd-extend-pidfd_get_pid-and-de-duplicate-pid-lookup/20241018-050825

Thanks.

This issue is because, incredibly, the cgroup tests import ../pidfd/pidfd.h
solely to use a helper, but in doing so inadvertently pull in linux/pidfd.h
_without_ the tools wrapper.

Adding a tools wrapper to cgroup fails too because of some other dependency.

I will separate out a header with this helper in it to work around this and
respin.

A gentle point on this - in my view, adding/updating tests shouldn't hold up a
series, rather we should do everything we can to encourage kernel developers to
add/expand tests.

So I'd say, in future, it might be best - if the tests already do something
considered 'bad' - to defer fixing that badness to a dedicated series, rather
than forcing an unrelated one to have to include commits to fixup pre-existing
problems like this.

I don't think anyone is really going to understand why a PIDFD_SELF series is
touching a cgroup test at this point.

Thanks!

> base: https://git.kernel.org/cgit/linux/kernel/git/shuah/linux-kselftest.git next
> patch link: https://lore.kernel.org/all/b9851fa9f87d22f352f960b847d99459ef7d74a1.1729198898.git.lorenzo.stoakes@xxxxxxxxxx/
> patch subject: [PATCH v4 4/4] selftests: pidfd: add tests for PIDFD_SELF_*
>
> in testcase: kernel-selftests
> version: kernel-selftests-x86_64-977d51cf-1_20240508
> with following parameters:
>
> 	group: cgroup
>
>
>
> config: x86_64-rhel-8.3-kselftests
> compiler: gcc-12
> test machine: 36 threads 1 sockets Intel(R) Core(TM) i9-10980XE CPU @ 3.00GHz (Cascade Lake) with 32G memory
>
> (please refer to attached dmesg/kmsg for entire log/backtrace)
>
>
>
>
> If you fix the issue in a separate patch/commit (i.e. not just a new version of
> the same patch/commit), kindly add following tags
> | Reported-by: kernel test robot <oliver.sang@xxxxxxxxx>
> | Closes: https://lore.kernel.org/oe-lkp/202410251504.707d78fc-oliver.sang@xxxxxxxxx
>
> KERNEL SELFTESTS: linux_headers_dir is /usr/src/linux-headers-x86_64-rhel-8.3-kselftests-930cb1423ee2522760ffde43455b14df5c0d5487
> '/usr/sbin/iptables' -> '/usr/sbin/iptables-nft'
> '/usr/sbin/iptables-restore' -> '/usr/sbin/iptables-nft-restore'
> '/usr/sbin/iptables-save' -> '/usr/sbin/iptables-nft-save'
> '/usr/sbin/ip6tables' -> '/usr/sbin/ip6tables-nft'
> '/usr/sbin/ip6tables-restore' -> '/usr/sbin/ip6tables-nft-restore'
> '/usr/sbin/ip6tables-save' -> '/usr/sbin/ip6tables-nft-save'
> 2024-10-23 12:53:55 sed -i s/default_timeout=45/default_timeout=300/ kselftest/runner.sh
> 2024-10-23 12:53:55 make -j36 -C cgroup
> make: Entering directory '/usr/src/perf_selftests-x86_64-rhel-8.3-kselftests-930cb1423ee2522760ffde43455b14df5c0d5487/tools/testing/selftests/cgroup'
>   CC       test_core
>   CC       test_cpu
>   CC       test_cpuset
>   CC       test_freezer
>   CC       test_hugetlb_memcg
>   CC       test_kill
>   CC       test_kmem
>   CC       test_memcontrol
>   CC       test_pids
>   CC       test_zswap
>   CC       wait_inotify
> In file included from /usr/x86_64-linux-gnu/include/asm/fcntl.h:1,
>                  from /usr/x86_64-linux-gnu/include/linux/fcntl.h:5,
>                  from /usr/x86_64-linux-gnu/include/linux/pidfd.h:7,
>                  from ../pidfd/pidfd.h:19,
>                  from test_kill.c:13:
> /usr/x86_64-linux-gnu/include/asm-generic/fcntl.h:156:8: error: redefinition of ‘struct f_owner_ex’
>   156 | struct f_owner_ex {
>       |        ^~~~~~~~~~
> In file included from /usr/include/x86_64-linux-gnu/bits/fcntl.h:61,
>                  from /usr/include/fcntl.h:35,
>                  from ../pidfd/pidfd.h:8:
> /usr/include/x86_64-linux-gnu/bits/fcntl-linux.h:274:8: note: originally defined here
>   274 | struct f_owner_ex
>       |        ^~~~~~~~~~
> /usr/x86_64-linux-gnu/include/asm-generic/fcntl.h:196:8: error: redefinition of ‘struct flock’
>   196 | struct flock {
>       |        ^~~~~
> /usr/include/x86_64-linux-gnu/bits/fcntl.h:35:8: note: originally defined here
>    35 | struct flock
>       |        ^~~~~
> /usr/x86_64-linux-gnu/include/asm-generic/fcntl.h:210:8: error: redefinition of ‘struct flock64’
>   210 | struct flock64 {
>       |        ^~~~~~~
> /usr/include/x86_64-linux-gnu/bits/fcntl.h:50:8: note: originally defined here
>    50 | struct flock64
>       |        ^~~~~~~
> make: *** [../lib.mk:221: /usr/src/perf_selftests-x86_64-rhel-8.3-kselftests-930cb1423ee2522760ffde43455b14df5c0d5487/tools/testing/selftests/cgroup/test_kill] Error 1
> make: *** Waiting for unfinished jobs....
> make: Leaving directory '/usr/src/perf_selftests-x86_64-rhel-8.3-kselftests-930cb1423ee2522760ffde43455b14df5c0d5487/tools/testing/selftests/cgroup'
> 2024-10-23 12:53:56 make quicktest=1 run_tests -C cgroup
> make: Entering directory '/usr/src/perf_selftests-x86_64-rhel-8.3-kselftests-930cb1423ee2522760ffde43455b14df5c0d5487/tools/testing/selftests/cgroup'
>   CC       test_kill
> In file included from /usr/x86_64-linux-gnu/include/asm/fcntl.h:1,
>                  from /usr/x86_64-linux-gnu/include/linux/fcntl.h:5,
>                  from /usr/x86_64-linux-gnu/include/linux/pidfd.h:7,
>                  from ../pidfd/pidfd.h:19,
>                  from test_kill.c:13:
> /usr/x86_64-linux-gnu/include/asm-generic/fcntl.h:156:8: error: redefinition of ‘struct f_owner_ex’
>   156 | struct f_owner_ex {
>       |        ^~~~~~~~~~
> In file included from /usr/include/x86_64-linux-gnu/bits/fcntl.h:61,
>                  from /usr/include/fcntl.h:35,
>                  from ../pidfd/pidfd.h:8:
> /usr/include/x86_64-linux-gnu/bits/fcntl-linux.h:274:8: note: originally defined here
>   274 | struct f_owner_ex
>       |        ^~~~~~~~~~
> /usr/x86_64-linux-gnu/include/asm-generic/fcntl.h:196:8: error: redefinition of ‘struct flock’
>   196 | struct flock {
>       |        ^~~~~
> /usr/include/x86_64-linux-gnu/bits/fcntl.h:35:8: note: originally defined here
>    35 | struct flock
>       |        ^~~~~
> /usr/x86_64-linux-gnu/include/asm-generic/fcntl.h:210:8: error: redefinition of ‘struct flock64’
>   210 | struct flock64 {
>       |        ^~~~~~~
> /usr/include/x86_64-linux-gnu/bits/fcntl.h:50:8: note: originally defined here
>    50 | struct flock64
>       |        ^~~~~~~
> make: *** [../lib.mk:222: /usr/src/perf_selftests-x86_64-rhel-8.3-kselftests-930cb1423ee2522760ffde43455b14df5c0d5487/tools/testing/selftests/cgroup/test_kill] Error 1
> make: Leaving directory '/usr/src/perf_selftests-x86_64-rhel-8.3-kselftests-930cb1423ee2522760ffde43455b14df5c0d5487/tools/testing/selftests/cgroup'
>
>
>
> The kernel config and materials to reproduce are available at:
> https://download.01.org/0day-ci/archive/20241025/202410251504.707d78fc-oliver.sang@xxxxxxxxx
>
>
>
> --
> 0-DAY CI Kernel Test Service
> https://github.com/intel/lkp-tests/wiki
>




[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [NTFS 3]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [NTFS 3]     [Samba]     [Device Mapper]     [CEPH Development]

  Powered by Linux