[PATCH v3 2/2] powerpc: ftrace_64: split further based on -mprofile-kernel
mpe at ellerman.id.au
Tue Feb 28 14:58:42 AEDT 2017
Steven Rostedt <rostedt at goodmis.org> writes:
> On Wed, 22 Feb 2017 00:31:02 +0530
> "Naveen N. Rao" <naveen.n.rao at linux.vnet.ibm.com> wrote:
>> Split ftrace_64.S further retaining the core ftrace 64-bit aspects
>> in ftrace_64.S and moving ftrace_caller() and ftrace_graph_caller() into
>> separate files based on -mprofile-kernel. The livepatch routines are all
>> now contained within the mprofile file.
Because we have two ABIs that are basically entirely different.
Splitting them into separate files makes it easier to work on one or the
other without getting muddled.
It also makes it clearer that the livepatch code only relates to the
mprofile ABI for example.
> I would think that it may be possible to share code if they stay
> in the same file.
We can share code even if they're in separate files. But I don't think
there's much that can be shared TBH.
> I haven't had the chance to look deeply into the
> current code, but there may be ways to make macros and consolidate
> duplicate code like we did in x86.
I'd obviously be happy to remove duplicate code, but as I said above
there's not much that is obviously shared.
There's a few shared lines such as:
Which could go in a macro I guess, but it's almost not worth the
More information about the Linuxppc-dev