]> git.baikalelectronics.ru Git - kernel.git/commit
powerpc: sstep: Add tests for compute type instructions
authorSandipan Das <sandipan@linux.ibm.com>
Wed, 20 Feb 2019 06:56:58 +0000 (12:26 +0530)
committerMichael Ellerman <mpe@ellerman.id.au>
Sat, 23 Feb 2019 10:04:31 +0000 (21:04 +1100)
commit6f79204c6b11ecd4e6b6d098cc17cfcfb54799f2
tree51558d665c1d44ea97611610b34a987ed8ff8670
parent3bdb730471f2696c09f4132939f26ce3c961c642
powerpc: sstep: Add tests for compute type instructions

This enhances the current selftest framework for validating
the in-kernel instruction emulation infrastructure by adding
support for compute type instructions i.e. integer ALU-based
instructions. Originally, this framework was limited to only
testing load and store instructions.

While most of the GPRs can be validated, support for SPRs is
limited to LR, CR and XER for now.

When writing the test cases, one must ensure that the Stack
Pointer (GPR1) or the Thread Pointer (GPR13) are not touched
by any means as these are vital non-volatile registers.

Signed-off-by: Sandipan Das <sandipan@linux.ibm.com>
[mpe: Use patch_site for the code patching]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
arch/powerpc/lib/Makefile
arch/powerpc/lib/test_emulate_step.c
arch/powerpc/lib/test_emulate_step_exec_instr.S [new file with mode: 0644]