1 #ifndef _PROBE_INFO_NEW_H
2 #define _PROBE_INFO_NEW_H
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
19 * Copyright (C) Samsung Electronics, 2015
21 * 2015 Vyacheslav Cherkashin <v.cherkashin@samsung.com>
26 #include <kprobe/swap_kprobes.h>
27 #include <uprobe/swap_uprobes.h>
35 struct probe_info_new {
39 kprobe_pre_handler_t handler;
43 uretprobe_handler_t entry_handler;
44 uretprobe_handler_t ret_handler;
46 * FIXME: make dynamic size,
47 * currently data_size = sizeof(void *)
54 struct probe_info *info;
60 struct probe_info_new *info;
64 #define MAKE_UPROBE(_handler) \
66 .type = SWAP_NEW_UP, \
67 .u.p.handler = _handler \
70 #define MAKE_URPROBE(_entry, _ret, _size) \
72 .type = SWAP_NEW_URP, \
73 .u.rp.entry_handler = _entry, \
74 .u.rp.ret_handler = _ret, \
75 .u.rp.data_size = _size \
78 struct probe_info_otg {
79 struct probe_info info;
80 struct probe_info_new *data; /* field 'data[0]' in probe_info struct */
83 void pin_set_probe(struct probe_info_otg *otg, unsigned long vaddr);
85 int pin_register(struct probe_new *probe, struct pf_group *pfg,
86 struct dentry *dentry);
87 int pin_unregister(struct probe_new *probe, struct pf_group *pfg,
88 struct dentry *dentry);
95 #endif /* _PROBE_INFO_NEW_H */