Linux kernel mirror (for testing)
git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel
os
linux
1/* SPDX-License-Identifier: GPL-2.0-only */
2/*
3 * Copyright (C) 2014-2016 Pratyush Anand <panand@redhat.com>
4 */
5
6#ifndef _ASM_UPROBES_H
7#define _ASM_UPROBES_H
8
9#include <asm/debug-monitors.h>
10#include <asm/insn.h>
11#include <asm/probes.h>
12
13#define UPROBE_SWBP_INSN cpu_to_le32(BRK64_OPCODE_UPROBES)
14#define UPROBE_SWBP_INSN_SIZE AARCH64_INSN_SIZE
15#define UPROBE_XOL_SLOT_BYTES AARCH64_INSN_SIZE
16
17typedef __le32 uprobe_opcode_t;
18
19struct arch_uprobe_task {
20};
21
22struct arch_uprobe {
23 union {
24 __le32 insn;
25 __le32 ixol;
26 };
27 struct arch_probe_insn api;
28 bool simulate;
29};
30
31int uprobe_brk_handler(struct pt_regs *regs, unsigned long esr);
32#ifdef CONFIG_UPROBES
33int uprobe_single_step_handler(struct pt_regs *regs, unsigned long esr);
34#else
35static inline int uprobe_single_step_handler(struct pt_regs *regs,
36 unsigned long esr)
37{
38 return DBG_HOOK_ERROR;
39}
40#endif
41
42#endif