struct hlist_node node;
struct ftrace_probe_ops *ops;
unsigned long ip;
- void *data;
struct list_head free_list;
};
return -EIO;
if (rec->ops->print)
- return rec->ops->print(m, rec->ip, rec->ops, rec->data);
+ return rec->ops->print(m, rec->ip, rec->ops, NULL);
seq_printf(m, "%ps:%ps\n", (void *)rec->ip, (void *)rec->ops->func);
preempt_disable_notrace();
hlist_for_each_entry_rcu_notrace(entry, hhd, node) {
if (entry->ip == ip)
- entry->ops->func(ip, parent_ip, entry->ops, &entry->data);
+ entry->ops->func(ip, parent_ip, entry->ops, NULL);
}
preempt_enable_notrace();
}
static void ftrace_free_entry(struct ftrace_func_probe *entry)
{
if (entry->ops->free)
- entry->ops->free(entry->ops, entry->ip, &entry->data);
+ entry->ops->free(entry->ops, entry->ip, NULL);
kfree(entry);
}
count++;
- entry->data = data;
-
/*
* The caller might want to do something special
* for each function we find. We call the callback
* to give the caller an opportunity to do so.
*/
if (ops->init) {
- if (ops->init(ops, rec->ip, &entry->data) < 0) {
+ if (ops->init(ops, rec->ip, data) < 0) {
/* caller does not like this func */
kfree(entry);
continue;
static int
ftrace_snapshot_init(struct ftrace_probe_ops *ops, unsigned long ip,
- void **data)
+ void *data)
{
struct ftrace_func_mapper *mapper = ops->private_data;
- return ftrace_func_mapper_add_ip(mapper, ip, *data);
+ return ftrace_func_mapper_add_ip(mapper, ip, data);
}
static void
struct ftrace_probe_ops *ops,
void **data);
int (*init)(struct ftrace_probe_ops *ops,
- unsigned long ip, void **data);
+ unsigned long ip, void *data);
void (*free)(struct ftrace_probe_ops *ops,
unsigned long ip, void **data);
int (*print)(struct seq_file *m,
static int
event_enable_init(struct ftrace_probe_ops *ops, unsigned long ip,
- void **_data)
+ void *_data)
{
struct ftrace_func_mapper *mapper = ops->private_data;
- struct event_probe_data **pdata = (struct event_probe_data **)_data;
- struct event_probe_data *data = *pdata;
+ struct event_probe_data *data = _data;
int ret;
ret = ftrace_func_mapper_add_ip(mapper, ip, data);
static int
ftrace_count_init(struct ftrace_probe_ops *ops, unsigned long ip,
- void **data)
+ void *data)
{
struct ftrace_func_mapper *mapper = ops->private_data;
- return ftrace_func_mapper_add_ip(mapper, ip, *data);
+ return ftrace_func_mapper_add_ip(mapper, ip, data);
}
static void