xref: /linux/arch/csky/kernel/probes/decode-insn.h (revision ead5d1f4d877e92c051e1a1ade623d0d30e71619)
1*33e53ae1SGuo Ren /* SPDX-License-Identifier: GPL-2.0+ */
2*33e53ae1SGuo Ren 
3*33e53ae1SGuo Ren #ifndef __CSKY_KERNEL_KPROBES_DECODE_INSN_H
4*33e53ae1SGuo Ren #define __CSKY_KERNEL_KPROBES_DECODE_INSN_H
5*33e53ae1SGuo Ren 
6*33e53ae1SGuo Ren #include <asm/sections.h>
7*33e53ae1SGuo Ren #include <asm/kprobes.h>
8*33e53ae1SGuo Ren 
9*33e53ae1SGuo Ren enum probe_insn {
10*33e53ae1SGuo Ren 	INSN_REJECTED,
11*33e53ae1SGuo Ren 	INSN_GOOD_NO_SLOT,
12*33e53ae1SGuo Ren 	INSN_GOOD,
13*33e53ae1SGuo Ren };
14*33e53ae1SGuo Ren 
15*33e53ae1SGuo Ren #define is_insn32(insn) ((insn & 0xc000) == 0xc000)
16*33e53ae1SGuo Ren 
17*33e53ae1SGuo Ren enum probe_insn __kprobes
18*33e53ae1SGuo Ren csky_probe_decode_insn(probe_opcode_t *addr, struct arch_probe_insn *asi);
19*33e53ae1SGuo Ren 
20*33e53ae1SGuo Ren #endif /* __CSKY_KERNEL_KPROBES_DECODE_INSN_H */
21