Files
android_kernel_xiaomi_sm8450/arch/mips/include/asm
Maneesh Soni 6457a396bb MIPS Kprobes: Support branch instructions probing
This patch provides support for kprobes on branch instructions. The branch
instruction at the probed address is actually emulated and not executed
out-of-line like other normal instructions. Instead the delay-slot instruction
is copied and single stepped out of line.

At the time of probe hit, the original branch instruction is evaluated
and the target cp0_epc is computed similar to compute_retrun_epc(). It
is also checked if the delay slot instruction can be skipped, which is
true if there is a NOP in delay slot or branch is taken in case of
branch likely instructions. Once the delay slot instruction is single
stepped the normal execution resume with the cp0_epc updated the earlier
computed cp0_epc as per the branch instructions.

Signed-off-by: Maneesh Soni <manesoni@cisco.com>
Signed-off-by: Victor Kamensky <kamensky@cisco.com>
Cc: David Daney <david.daney@cavium.com>
Cc: ananth@in.ibm.com
Cc: linux-kernel@vger.kernel.org
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/2914/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2011-12-07 22:04:03 +00:00
..
2011-03-31 11:26:23 -03:00
2011-09-27 18:08:04 +02:00
2011-03-31 11:26:23 -03:00
2011-05-19 09:55:41 +01:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2011-03-31 11:26:23 -03:00
2009-07-03 15:45:26 +01:00
2008-12-12 18:12:23 +00:00
2010-02-27 12:53:42 +01:00
2010-08-05 13:26:29 +01:00
2009-12-05 09:10:12 -08:00
2011-05-10 18:15:24 +01:00
2010-02-27 12:53:27 +01:00
2009-07-03 15:45:29 +01:00
2011-07-25 17:26:53 +01:00
2009-12-17 01:57:32 +00:00
2010-10-26 16:52:08 -07:00
2011-07-26 16:49:47 -07:00
2009-06-17 11:06:28 +01:00
2011-03-31 11:26:23 -03:00
2010-08-05 13:26:29 +01:00
2010-06-09 11:12:36 +02:00
2011-07-26 16:49:47 -07:00
2011-01-13 17:32:47 -08:00
2010-04-12 17:26:14 +01:00
2010-02-27 12:53:14 +01:00
2010-02-27 12:53:14 +01:00
2011-03-31 11:26:23 -03:00
2010-10-04 18:33:55 +01:00
2010-02-27 12:53:27 +01:00
2010-10-26 16:52:08 -07:00
2011-07-25 17:26:51 +01:00
2011-03-31 11:26:23 -03:00
2009-07-03 15:45:27 +01:00
2010-02-27 12:53:27 +01:00
2009-11-02 12:00:01 +01:00
2011-03-31 11:26:23 -03:00
2011-07-26 16:49:47 -07:00
2011-07-20 23:12:10 +01:00
2010-02-27 12:53:14 +01:00
2010-02-27 12:53:42 +01:00
2010-08-09 16:48:44 -04:00
2011-03-23 19:47:18 -07:00
2011-07-26 06:47:36 +01:00
2010-02-27 12:53:27 +01:00
2010-04-12 17:26:14 +01:00
2011-03-31 11:26:23 -03:00