]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc/kprobes: Replace ppc_optinsn by common optinsn
authorChristophe Leroy <christophe.leroy@csgroup.eu>
Thu, 13 May 2021 09:07:53 +0000 (09:07 +0000)
committerMichael Ellerman <mpe@ellerman.id.au>
Sun, 23 May 2021 10:51:35 +0000 (20:51 +1000)
commit871a3c120ab99266269dd02a11c5b3d3fc3624da
tree4f695af1eade6a14ff2903f0427660ccef905bfb
parentcd1809a7428c95273b942e01b2d325d3c87e8a7e
powerpc/kprobes: Replace ppc_optinsn by common optinsn

Commit eba76bf2e389 ("powerpc/kprobes: Implement Optprobes")
implemented a powerpc specific version of optinsn in order
to workaround the 32Mb limitation for direct branches.

Instead of implementing a dedicated powerpc version, use the
common optinsn and override the allocation and freeing functions.

This also indirectly remove the CLANG warning about
is_kprobe_ppc_optinsn_slot() not being use, and the powerpc will
now benefit from commit 83b8b035c5dc ("kprobes, extable: Identify
kprobes trampolines as kernel text area")

Suggested-by: Masami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Acked-by: Masami Hiramatsu <mhiramat@kernel.org>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/ec5e85f9f9abcfecc959a03495f4a7858eb4d203.1620896780.git.christophe.leroy@csgroup.eu
arch/powerpc/kernel/optprobes.c