Closed liu-song-6 closed 2 years ago
Does this fix it?
diff --git a/kpatch-build/kpatch-build b/kpatch-build/kpatch-build
index 02504e6..296fa48 100755
--- a/kpatch-build/kpatch-build
+++ b/kpatch-build/kpatch-build
@@ -1100,6 +1100,7 @@ for i in $FILES; do
SYMVERS_FILE="$BUILDDIR/Module.symvers"
elif [[ "$(basename "$KOBJFILE")" = "$(basename "$OOT_MODULE")" ]]; then
KOBJFILE_NAME="$(basename --suffix=.ko "$OOT_MODULE")"
+ KOBJFILE_NAME="${KOBJFILE_NAME//-/_}"
KOBJFILE_PATH="$OOT_MODULE"
SYMTAB="${TEMPDIR}/module/${KOBJFILE_NAME}.symtab"
SYMVERS_FILE="$TEMPDIR/Module.symvers"
It does fix the issue! Thanks!
While building livepatch for an OOT module, we hit issue with '-'/'_' mismatch. The OOT module has name as abc_xyz, while the livepatch module is build as abc-xyz. The same mismatch also happens to klp.rela.abc-xyz section (this is a 5.6 based kernel).
scripts/Makefile.lib changes module name in
Can we do something similar in kpatch-build?