]> git.baikalelectronics.ru Git - kernel.git/commit
arm64/module: ftrace: deal with place relative nature of PLTs
authorArd Biesheuvel <ard.biesheuvel@linaro.org>
Sat, 13 Apr 2019 06:59:25 +0000 (23:59 -0700)
committerCatalin Marinas <catalin.marinas@arm.com>
Tue, 23 Apr 2019 12:35:00 +0000 (13:35 +0100)
commitb57c14ad29e4e6fe4df72aabe964a1420824dbc8
treeae2a3114a580f1a47890883ead541ba5b8d0ec14
parent0de192362608978a0a5dc3335a9bb8e5941904df
arm64/module: ftrace: deal with place relative nature of PLTs

Another bodge for the ftrace PLT code: plt_entries_equal() now takes
the place relative nature of the ADRP/ADD based PLT entries into
account, which means that a struct trampoline instance on the stack
is no longer equal to the same set of opcodes in the module struct,
given that they don't point to the same place in memory anymore.

Work around this by using memcmp() in the ftrace PLT handling code.

Acked-by: Will Deacon <will.deacon@arm.com>
Tested-by: dann frazier <dann.frazier@canonical.com>
Signed-off-by: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
arch/arm64/kernel/ftrace.c