]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc: Make probe_kernel_read_inst() common to PPC32 and PPC64
authorChristophe Leroy <christophe.leroy@csgroup.eu>
Wed, 14 Apr 2021 13:08:41 +0000 (13:08 +0000)
committerMichael Ellerman <mpe@ellerman.id.au>
Wed, 21 Apr 2021 12:52:33 +0000 (22:52 +1000)
commitdc8b179e9d247f5130555480f7ba095e0045d1f8
treee5b7d3fc1e56ad3679f78cd26af715f0892c0665
parent3a86ec7aec3439daf3b883ad58ed1f2f45b647fb
powerpc: Make probe_kernel_read_inst() common to PPC32 and PPC64

We have two independant versions of probe_kernel_read_inst(), one for
PPC32 and one for PPC64.

The PPC32 is identical to the first part of the PPC64 version.
The remaining part of PPC64 version is not relevant for PPC32, but
not contradictory, so we can easily have a common function with
the PPC64 part opted out via a IS_ENABLED(CONFIG_PPC64).

The only need is to add a version of ppc_inst_prefix() for PPC32.

Signed-off-by: Christophe Leroy <christophe.leroy@csgroup.eu>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/f7b9dfddef3b3760182c7e5466356c121a293dc9.1618405715.git.christophe.leroy@csgroup.eu
arch/powerpc/include/asm/inst.h
arch/powerpc/lib/inst.c