Re: [PATCH v2] selftests: sched_ext: Add sched_ext as proper selftest target

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

 



Mark Brown <broonie@xxxxxxxxxx> writes:

> On Mon, Oct 07, 2024 at 06:00:57PM +0200, Björn Töpel wrote:
>> Mark Brown <broonie@xxxxxxxxxx> writes:
>> > On Mon, Oct 07, 2024 at 09:31:32AM +0200, Björn Töpel wrote:
>
>> >   CLNG-BPF create_dsq.bpf.o
>> > In file included from create_dsq.bpf.c:9:
>> > /home/broonie/git/linux/tools/sched_ext/include/scx/common.bpf.h:33:17: error: use of undeclared identifier 'SCX_DSQ_FLAG_BUILTIN'
>> >    33 |         _Static_assert(SCX_DSQ_FLAG_BUILTIN,
>> >       |                        ^
>
>> This is most likely due to incorrect VMLINUX_BTF_PATHS, so that
>> vmlinux.h is incorrectly generated. Try grepping for
>> SCX_DSQ_FLAG_BUILTIN in vmlinux.h.
>
> Yeah, it's not in the generated files:
>
> broonie@finisterre:~/git/linux$ grep SCX_DSQ_FLAG_BUILTIN ./tools/testing/selftests/sched_ext/build/include/vmlinux.h ./tools/testing/selftests/sched_ext/build/obj/bpftool/vmlinux.h
> broonie@finisterre:~/git/linux$ 
>
> I didn't actually build a kernel, if the build system needs a kernel
> it's just silently not detected that it's missing?

It tries to find a kernel with BTF:
  | VMLINUX_BTF_PATHS ?= $(if $(O),$(O)/vmlinux)                                    \
  |                      $(if $(KBUILD_OUTPUT),$(KBUILD_OUTPUT)/vmlinux)            \
  |                      ../../../../vmlinux                                        \
  |                      /sys/kernel/btf/vmlinux                                    \
  |                      /boot/vmlinux-$(shell uname -r)

Similar to all the other selftests using BPF.

(Oh, and at some point the BPF parts should be in lib.mk...)


Björn





[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux