Hi Josh, When I run kpatch-build tool for the memnfo-string.patch on our 3.4 kernel, I got an error of
meminfo.o: function meminfo_proc_show has no fentry call, unable to patch It seems the fentry support is added in d57c5d51a30152f3175d2344cb6395f08bf8ee0c, which I didn’t backport yet. Should I backport it and maybe some other commits? Or there is a kpatch version which only use mcount instead of fentry? commit d57c5d51a30152f3175d2344cb6395f08bf8ee0c Author: Steven Rostedt <[email protected]<mailto:[email protected]>> Date: Wed Feb 9 13:32:18 2011 -0500 ftrace/x86: Add support for -mfentry to x86_64 Thanks Michael On Jan 27, 2016, at 7:55 PM, Josh Poimboeuf <[email protected]<mailto:[email protected]>> wrote: Michael, The 06aeaaeabf69da4a3e86df532425640f51b01cef commit seems to be just a cosmetic change so I don't think you need it (unless it's a dependency for another needed change). Otherwise I'm not sure what else you need. On Wed, Jan 27, 2016 at 04:16:39AM +0000, Michael Liu (zuwliu) wrote: Hi Josh, Wondering to which stage of ftrace I need to backport to 3.4 kernel? I already back ported commits: 08f6fba503111e0336f2b4d6915a4a18f9b60e51 (ftrace/x86: Add separate function to save regs) 647664eaf4033501739ac1f42dd52ce8c9266ccc (ftrace: add ftrace_set_filter_ip() for address based filter) Now I can compile kmod/core KLM in kpatch on 3.4 kernel. Wondering do I need also backport the commit of 06aeaaeabf69da4a3e86df532425640f51b01cef (ftrace: Move ARCH_SUPPORTS_FTRACE_SAVE_REGS in Kconfig) to make kpatch really work on 3.4 kernel? Really appreciate your help! Thanks Michael On Jan 20, 2016, at 7:39 AM, Josh Poimboeuf <[email protected]<mailto:[email protected]><mailto:[email protected]>> wrote: On Tue, Jan 19, 2016 at 04:15:10PM +0000, Michael Liu (zuwliu) wrote: I joined the member and try to send it again. Hello Kpatch, I’m in a project which requires running kpatch on our 3.4 kernel, wondering how much effort is needed to do so? We currently using GCC 4.6.3, but I think we can move to GCC 4.8 if needed. However we cannot move our kernel to 3.9. In 3.4 kernel I saw there is already ftrace, although there is no CONFIG_DYNAMIC_FTRACE_WITH_REGS feature. Wondering whether CONFIG_DYNAMIC_FTRACE_WITH_REGS is the only feature missing on 3.4 to support kpatch? Are there other things we need to backport to run kpatch on 3.4 kernel? Thank you for your time! Hi Michael, CONFIG_DYNAMIC_FTRACE_WITH_REGS is the biggest required feature I know about that's missing on 3.4. Also, there are at least some minor kernel API differences that affect the kpatch core module, described here: https://github.com/dynup/kpatch/issues/257 GCC 4.6 may have issues: https://github.com/dynup/kpatch/issues/246#issuecomment-46615292 Those are just the problems I know about. You might run into other issues... -- Josh -- Josh
_______________________________________________ kpatch mailing list [email protected] https://www.redhat.com/mailman/listinfo/kpatch
