From: "Sam Kent" <sam.john.kent@gmail.com>
To: openembedded-core@lists.openembedded.org
Cc: Sam Kent <sam.john.kent@gmail.com>
Subject: [PATCH 1/2] package.py: fix kernel module file pre-filter and document strip asymmetry
Date: Tue, 21 Apr 2026 11:28:44 +0100 [thread overview]
Message-ID: <20260421102845.292954-2-sam.john.kent@gmail.com> (raw)
In-Reply-To: <20260421102845.292954-1-sam.john.kent@gmail.com>
Change the check to f.endswith(".ko"), consistent with strip_execs() and
with the /lib/modules/ guard already present in is_elf() and
splitdebuginfo().
Fixes [YOCTO #2348]
Signed-off-by: Sam Kent <sam.john.kent@gmail.com>
---
meta/lib/oe/package.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/meta/lib/oe/package.py b/meta/lib/oe/package.py
index 279cd56..c375acc 100644
--- a/meta/lib/oe/package.py
+++ b/meta/lib/oe/package.py
@@ -37,7 +37,8 @@ def runstrip(file, elftype, strip, extra_strip_sections=''):
stripcmd = [strip]
skip_strip = False
- # kernel module
+ # kernel module: use --strip-debug and --preserve-dates (required for
+ # module signing to remain valid after stripping)
if elftype & 16:
if is_kernel_module_signed(file):
bb.debug(1, "Skip strip on signed module %s" % file)
@@ -1167,7 +1168,7 @@ def process_split_and_strip_files(d):
or (s[stat.ST_MODE] & stat.S_IXOTH) \
or ((file.startswith(libdir) or file.startswith(baselibdir)) \
and (".so" in f or ".node" in f)) \
- or (f.startswith('vmlinux') or ".ko" in f):
+ or (f.startswith('vmlinux') or f.endswith(".ko")):
if cpath.islink(file):
checkelflinks[file] = ltarget
--
2.34.1
next prev parent reply other threads:[~2026-04-21 10:42 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-04-21 10:28 [PATCH 0/2] Fix .ko file pre-filter to use endswith instead of string contains sam.john.kent
2026-04-21 10:28 ` Sam Kent [this message]
2026-04-21 10:28 ` [PATCH 2/2] oe/package: add unit tests for kernel module detection helpers Sam Kent
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=20260421102845.292954-2-sam.john.kent@gmail.com \
--to=sam.john.kent@gmail.com \
--cc=openembedded-core@lists.openembedded.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox