From b6e19c7795e56f20a565f4e4a47e193377a98d44 Mon Sep 17 00:00:00 2001 From: chenzefeng Date: Thu, 9 May 2019 15:49:31 +0800 Subject: [PATCH] create-diff-object: fix the condition for the sections changed The create-diff-object.c create intermediate ".kpatch.relocations" sections instead of ".kpatch.dynrelas" sections, and add a new section ".rela.kpatch.symbols", so we should update the conditions in function kpatch_create_intermediate_sections for these changed. Fixes: 87643703a757 ("create-diff-object: create .kpatch.relocations and .kpatch.symbols sections") Signed-off-by: chenzefeng --- kpatch-build/create-diff-object.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kpatch-build/create-diff-object.c b/kpatch-build/create-diff-object.c index 2b8eb15..f0090eb 100644 --- a/kpatch-build/create-diff-object.c +++ b/kpatch-build/create-diff-object.c @@ -2748,7 +2748,8 @@ static void kpatch_create_intermediate_sections(struct kpatch_elf *kelf, if (!is_rela_section(sec)) continue; if (!strcmp(sec->name, ".rela.kpatch.funcs") || - !strcmp(sec->name, ".rela.kpatch.dynrelas")) + !strcmp(sec->name, ".rela.kpatch.relocations") || + !strcmp(sec->name, ".rela.kpatch.symbols")) continue; list_for_each_entry_safe(rela, safe, &sec->relas, list) { if (!rela->need_dynrela)