Public bug reported:

New pahole (version >1.24) generates by default new BTF_KIND_ENUM64 BTF
tag, which is not supported by stable kernel.

As a result the kernel with CONFIG_DEBUG_INFO_BTF option will fail to
load kernel modules (such as media-control e.g. mc.ko) with following
error:

  BTFIDS mc
FAILED: load BTF from vmlinux: Invalid argument

New pahole provides --skip_encoding_btf_enum64 option to skip
BTF_KIND_ENUM64 generation and produce BTF supported by stable kernel.

diff --git a/scripts/Makefile.btf b/scripts/Makefile.btf
index b75f09f3f424..f7279643c4a6 100644
--- a/scripts/Makefile.btf
+++ b/scripts/Makefile.btf
@@ -14,6 +14,8 @@ pahole-flags-$(call test-ge, $(pahole-ver), 121)      += 
--btf_gen_floats

 pahole-flags-$(call test-ge, $(pahole-ver), 122)       += -j

+pahole-flags-$(call test-ge, $(pahole-ver), 124)       += 
--skip_encoding_btf_enum64
+
 pahole-flags-$(call test-ge, $(pahole-ver), 125)       += 
--skip_encoding_btf_inconsistent_proto --btf_gen_optimized

--

See similar issue in Jammy to
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/2051376

** Affects: linux-meta-realtime (Ubuntu)
     Importance: Undecided
         Status: New

** Summary changed:

- realtime kernel FAILED: load BTF from mc: Invalid argument
+ Linux realtime 6.8.1 kernel FAILED: load BTF from mc: Invalid argument

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2125475

Title:
  Linux realtime 6.8.1 kernel FAILED: load BTF from mc: Invalid argument

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux-meta-realtime/+bug/2125475/+subscriptions


-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to