代码拉取完成,页面将自动刷新
同步操作将从 src-openEuler/kpatch 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
From 41cb82ddd28ce6abd70686839f871d44f670b5dd Mon Sep 17 00:00:00 2001
From: Zhipeng Xie <[email protected]>
Date: Wed, 26 Feb 2020 21:01:02 -0500
Subject: [PATCH 13/38] kpatch-build: ignore debuginfo in patch
Just ignore all .debug_* sections
Signed-off-by: Zhipeng Xie <[email protected]>
---
kpatch-build/create-diff-object.c | 18 ++++++++++++++++++
kpatch-build/kpatch-build | 1 +
2 files changed, 19 insertions(+)
diff --git a/kpatch-build/create-diff-object.c b/kpatch-build/create-diff-object.c
index ee06ad1..2d28aa0 100644
--- a/kpatch-build/create-diff-object.c
+++ b/kpatch-build/create-diff-object.c
@@ -2899,6 +2899,23 @@ static void kpatch_include_debug_sections(struct kpatch_elf *kelf)
}
}
+static void kpatch_ignore_debug_sections(struct kpatch_elf *kelf)
+{
+ struct section *sec;
+
+ /* include all .debug_* sections */
+ list_for_each_entry(sec, &kelf->sections, list) {
+ if (is_debug_section(sec)) {
+ sec->include = 0;
+ sec->status = SAME;
+ if (!is_rela_section(sec)) {
+ sec->secsym->include = 0;
+ sec->secsym->status = SAME;
+ }
+ }
+ }
+}
+
static void kpatch_mark_ignored_sections(struct kpatch_elf *kelf)
{
struct section *sec, *strsec, *ignoresec;
@@ -4206,6 +4223,7 @@ int main(int argc, char *argv[])
new_globals_exist = kpatch_include_new_globals(kelf_patched);
kpatch_include_new_static_var(kelf_patched);
kpatch_include_debug_sections(kelf_patched);
+ kpatch_ignore_debug_sections(kelf_patched);
kpatch_process_special_sections(kelf_patched, lookup);
diff --git a/kpatch-build/kpatch-build b/kpatch-build/kpatch-build
index 39f8050..9f14bb2 100755
--- a/kpatch-build/kpatch-build
+++ b/kpatch-build/kpatch-build
@@ -1492,6 +1492,7 @@ CROSS_COMPILE="$CROSS_COMPILE"
save_env
make "${MAKEVARS[@]}" 2>&1 | logger || die
+strip -g "$TEMPDIR/patch/$MODNAME.ko"
if [[ "$USE_KLP" -eq 1 ]]; then
if [[ "$USE_KLP_ARCH" -eq 0 ]]; then
--
2.33.0
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。