On Tue, Mar 26, 2024 at 6:48 PM Bruce Ashfield <bruce.ashfi...@gmail.com> wrote: > > > > On Tue, Mar 26, 2024 at 1:46 PM Bruce Ashfield <bruce.ashfi...@gmail.com> > wrote: >> >> >> >> On Mon, Mar 25, 2024 at 6:21 AM <max.oss...@gmail.com> wrote: >>> >>> From: Max Krummenacher <max.krummenac...@toradex.com> >>> >>> Kernel commit 9eea8fafe33e ("libbpf: fix __arg_ctx type enforcement for >>> perf_event programs") added with 6.9-rc1 >>> tools/include/uapi/asm/bpf_perf_event.h >>> which for arc, arm64, loongarch, riscv and s390 includes headers from >>> the arch/${ARCH}/... directories. >>> Thus the build in OE fails as those headers are not present. >>> >>> Fix this by additioanly copying all files in arch/${ARCH}/include/. >>> >>> Fixes: >>> ERROR: perf-1.0-r0 do_compile: oe_runmake failed >>> | In file included from >>> work/verdin_imx8mm-tdx-linux/perf/1.0/perf-1.0/tools/include/uapi/linux/bpf_perf_event.h:11, >>> | from libbpf.c:36: >>> | >>> work/verdin_imx8mm-tdx-linux/perf/1.0/perf-1.0/tools/include/uapi/asm/bpf_perf_event.h:2:10: >>> fatal error: ../../arch/arm64/include/uapi/asm/bpf_perf_event.h: No such >>> file or directory >>> | 2 | #include "../../arch/arm64/include/uapi/asm/bpf_perf_event.h" >>> | | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ >>> >>> Signed-off-by: Max Krummenacher <max.krummenac...@toradex.com> >>> --- >>> meta/recipes-kernel/perf/perf.bb | 1 + >>> 1 file changed, 1 insertion(+) >>> >>> diff --git a/meta/recipes-kernel/perf/perf.bb >>> b/meta/recipes-kernel/perf/perf.bb >>> index 4f26813de0..6408c65462 100644 >>> --- a/meta/recipes-kernel/perf/perf.bb >>> +++ b/meta/recipes-kernel/perf/perf.bb >>> @@ -139,6 +139,7 @@ PERF_SRC ?= "Makefile \ >>> tools/scripts \ >>> scripts/ \ >>> arch/arm64/tools \ >>> + arch/${ARCH}/include \ >> >> >> We've always tried to stay within the tools/ source umbrella since we really >> don't want to copy any more of the kernel than we have to, since otherwise, >> we might as well go back to simplifying things and just building against the >> entire kernel source tree. >> >> I'd like to see if there's a way that we could limit this to the uapi (and >> hence >> use our uapi headers), and avoid needing to make the copy. If we need a >> copy, then being as specific as possible would be the goal.
I was too lazy to limit this when I came up with the patch. Currently the only header missing is ../../arch/arm64/include/uapi/asm/bpf_perf_event.h, so limiting to arch/${ARCH}/include/uapi should work fine, I'm unsure if the header file itself exists for every ${ARCH} so only copying the one file is probably a dangerous way forward. > > > > I meant to also add that I'm not talking about the libc-headers for the > uapi bits, as they are not tracking the latest kernel by design. Although > it would be interesting to see how perf does treat the older uapi against > the new kernel, so we can document the tested combinations. > > Bruce Let's wait till you give linux-yocto-dev a try run.Happy Easter. Max > > >> >> >> I'm not moving linux-yocto-dev to the latest -dev until next week, but I can >> look into this more then. >> >> Bruce >> >> >>> >>> arch/${ARCH}/Makefile \ >>> " >>> >>> -- >>> 2.42.0 >>> >> >> >> -- >> - Thou shalt not follow the NULL pointer, for chaos and madness await thee >> at its end >> - "Use the force Harry" - Gandalf, Star Trek II >> > > > -- > - Thou shalt not follow the NULL pointer, for chaos and madness await thee at > its end > - "Use the force Harry" - Gandalf, Star Trek II >
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#197601): https://lists.openembedded.org/g/openembedded-core/message/197601 Mute This Topic: https://lists.openembedded.org/mt/105135063/21656 Group Owner: openembedded-core+ow...@lists.openembedded.org Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-