• Ard Biesheuvel's avatar
    arm64: ftrace: emit ftrace-mod.o contents through code · be0f272b
    Ard Biesheuvel authored
    When building the arm64 kernel with both CONFIG_ARM64_MODULE_PLTS and
    CONFIG_DYNAMIC_FTRACE enabled, the ftrace-mod.o object file is built
    with the kernel and contains a trampoline that is linked into each
    module, so that modules can be loaded far away from the kernel and
    still reach the ftrace entry point in the core kernel with an ordinary
    relative branch, as is emitted by the compiler instrumentation code
    dynamic ftrace relies on.
    
    In order to be able to build out of tree modules, this object file
    needs to be included into the linux-headers or linux-devel packages,
    which is undesirable, as it makes arm64 a special case (although a
    precedent does exist for 32-bit PPC).
    
    Given that the trampoline essentially consists of a PLT entry, let's
    not bother with a source or object file for it, and simply patch it
    in whenever the trampoline is being populated, using the existing
    PLT support routines.
    
    Cc: <stable@vger.kernel.org>
    Signed-off-by: 's avatarArd Biesheuvel <ard.biesheuvel@linaro.org>
    Signed-off-by: 's avatarWill Deacon <will.deacon@arm.com>
    be0f272b
Name
Last commit
Last update
Documentation Loading commit data...
arch Loading commit data...
block Loading commit data...
certs Loading commit data...
crypto Loading commit data...
drivers Loading commit data...
firmware Loading commit data...
fs Loading commit data...
include Loading commit data...
init Loading commit data...
ipc Loading commit data...
kernel Loading commit data...
lib Loading commit data...
mm Loading commit data...
net Loading commit data...
samples Loading commit data...
scripts Loading commit data...
security Loading commit data...
sound Loading commit data...
tools Loading commit data...
usr Loading commit data...
virt Loading commit data...
.cocciconfig Loading commit data...
.get_maintainer.ignore Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.mailmap Loading commit data...
COPYING Loading commit data...
CREDITS Loading commit data...
Kbuild Loading commit data...
Kconfig Loading commit data...
MAINTAINERS Loading commit data...
Makefile Loading commit data...
README Loading commit data...