Linux Audio

Check our new training course

Loading...
v4.17
 
 1#ifndef _ASM_UPROBES_H
 2#define _ASM_UPROBES_H
 3/*
 4 * User-space Probes (UProbes) for sparc
 5 *
 6 * Copyright (C) 2013 Oracle, Inc.
 7 *
 8 * This program is free software: you can redistribute it and/or modify
 9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation, either version 2 of the License, or
11 * (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.	 See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License
19 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
20 *
21 * Authors:
22 *     Jose E. Marchesi <jose.marchesi@oracle.com>
23 *	Eric Saint Etienne <eric.saint.etienne@oracle.com>
24 */
25
26typedef u32 uprobe_opcode_t;
27
28#define MAX_UINSN_BYTES		4
29#define UPROBE_XOL_SLOT_BYTES	(MAX_UINSN_BYTES * 2)
30
31#define UPROBE_SWBP_INSN_SIZE	4
32#define UPROBE_SWBP_INSN	0x91d02073 /* ta 0x73 */
33#define UPROBE_STP_INSN		0x91d02074 /* ta 0x74 */
34
35#define ANNUL_BIT (1 << 29)
36
37struct arch_uprobe {
38	union {
39		u8  insn[MAX_UINSN_BYTES];
40		u32 ixol;
41	};
42};
43
44struct arch_uprobe_task {
45	u64 saved_tpc;
46	u64 saved_tnpc;
47};
48
49struct task_struct;
50struct notifier_block;
51
52extern int  arch_uprobe_analyze_insn(struct arch_uprobe *aup, struct mm_struct *mm, unsigned long addr);
53extern int  arch_uprobe_pre_xol(struct arch_uprobe *aup, struct pt_regs *regs);
54extern int  arch_uprobe_post_xol(struct arch_uprobe *aup, struct pt_regs *regs);
55extern bool arch_uprobe_xol_was_trapped(struct task_struct *tsk);
56extern int  arch_uprobe_exception_notify(struct notifier_block *self, unsigned long val, void *data);
57extern void arch_uprobe_abort_xol(struct arch_uprobe *aup, struct pt_regs *regs);
58
59#endif	/* _ASM_UPROBES_H */
v6.8
 1/* SPDX-License-Identifier: GPL-2.0-or-later */
 2#ifndef _ASM_UPROBES_H
 3#define _ASM_UPROBES_H
 4/*
 5 * User-space Probes (UProbes) for sparc
 6 *
 7 * Copyright (C) 2013 Oracle, Inc.
 
 
 
 
 
 
 
 
 
 
 
 
 
 8 *
 9 * Authors:
10 *     Jose E. Marchesi <jose.marchesi@oracle.com>
11 *	Eric Saint Etienne <eric.saint.etienne@oracle.com>
12 */
13
14typedef u32 uprobe_opcode_t;
15
16#define MAX_UINSN_BYTES		4
17#define UPROBE_XOL_SLOT_BYTES	(MAX_UINSN_BYTES * 2)
18
19#define UPROBE_SWBP_INSN_SIZE	4
20#define UPROBE_SWBP_INSN	0x91d02073 /* ta 0x73 */
21#define UPROBE_STP_INSN		0x91d02074 /* ta 0x74 */
22
23#define ANNUL_BIT (1 << 29)
24
25struct arch_uprobe {
26	union {
27		u8  insn[MAX_UINSN_BYTES];
28		u32 ixol;
29	};
30};
31
32struct arch_uprobe_task {
33	u64 saved_tpc;
34	u64 saved_tnpc;
35};
36
37struct task_struct;
38struct notifier_block;
39
40extern int  arch_uprobe_analyze_insn(struct arch_uprobe *aup, struct mm_struct *mm, unsigned long addr);
41extern int  arch_uprobe_pre_xol(struct arch_uprobe *aup, struct pt_regs *regs);
42extern int  arch_uprobe_post_xol(struct arch_uprobe *aup, struct pt_regs *regs);
43extern bool arch_uprobe_xol_was_trapped(struct task_struct *tsk);
44extern int  arch_uprobe_exception_notify(struct notifier_block *self, unsigned long val, void *data);
45extern void arch_uprobe_abort_xol(struct arch_uprobe *aup, struct pt_regs *regs);
46
47#endif	/* _ASM_UPROBES_H */