cachepc-linux

Fork of AMDESE/linux with modifications for CachePC side-channel attack
git clone https://git.sinitax.com/sinitax/cachepc-linux
Log | Files | Refs | README | LICENSE | sfeed.txt

probes.h (563B)


      1/* SPDX-License-Identifier: GPL-2.0 */
      2
      3#ifndef _ASM_RISCV_PROBES_H
      4#define _ASM_RISCV_PROBES_H
      5
      6typedef u32 probe_opcode_t;
      7typedef bool (probes_handler_t) (u32 opcode, unsigned long addr, struct pt_regs *);
      8
      9/* architecture specific copy of original instruction */
     10struct arch_probe_insn {
     11	probe_opcode_t *insn;
     12	probes_handler_t *handler;
     13	/* restore address after simulation */
     14	unsigned long restore;
     15};
     16
     17#ifdef CONFIG_KPROBES
     18typedef u32 kprobe_opcode_t;
     19struct arch_specific_insn {
     20	struct arch_probe_insn api;
     21};
     22#endif
     23
     24#endif /* _ASM_RISCV_PROBES_H */