livepatch/core: Add support for arm for klp relocation
hulk inclusion category: feature bugzilla: 51923 CVE: NA --------------------------- In the older version of livepatch implementation without ftrace on arm, it use klp_relocs and do special relocation for klp syms. The kpatch-build front-tools use kpatch version to generate klp_relocs. After commit 7c8e2bdd ("livepatch: Apply vmlinux-specific KLP relocations early") and commit 425595a7 ("livepatch: reuse module loader code to write relocations"), the mainline klp relocation flow is always using ".klp.rela." section and kpatch-build front-tools use klp version to generate klp module. The default klp_apply_section_relocs is only for 64bit and modules with rela support. Because CONFIG_MODULES_USE_ELF_REL is set in arm, so we modify klp relocation to support 32bit and modules using rel. Also the kpatch-build front-tools should adapter to support this. Signed-off-by: NDong Kai <dongkai11@huawei.com> Signed-off-by: NYe Weihua <yeweihua4@huawei.com> Reviewed-by: NYang Jihong <yangjihong1@huawei.com> Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
Showing
想要评论请 注册 或 登录