|
@@ -414,12 +414,27 @@ get_tracepoints_path(struct list_head *pattrs)
|
|
if (pos->attr.type != PERF_TYPE_TRACEPOINT)
|
|
if (pos->attr.type != PERF_TYPE_TRACEPOINT)
|
|
continue;
|
|
continue;
|
|
++nr_tracepoints;
|
|
++nr_tracepoints;
|
|
|
|
+
|
|
|
|
+ if (pos->name) {
|
|
|
|
+ ppath->next = tracepoint_name_to_path(pos->name);
|
|
|
|
+ if (ppath->next)
|
|
|
|
+ goto next;
|
|
|
|
+
|
|
|
|
+ if (strchr(pos->name, ':') == NULL)
|
|
|
|
+ goto try_id;
|
|
|
|
+
|
|
|
|
+ goto error;
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+try_id:
|
|
ppath->next = tracepoint_id_to_path(pos->attr.config);
|
|
ppath->next = tracepoint_id_to_path(pos->attr.config);
|
|
if (!ppath->next) {
|
|
if (!ppath->next) {
|
|
|
|
+error:
|
|
pr_debug("No memory to alloc tracepoints list\n");
|
|
pr_debug("No memory to alloc tracepoints list\n");
|
|
put_tracepoints_path(&path);
|
|
put_tracepoints_path(&path);
|
|
return NULL;
|
|
return NULL;
|
|
}
|
|
}
|
|
|
|
+next:
|
|
ppath = ppath->next;
|
|
ppath = ppath->next;
|
|
}
|
|
}
|
|
|
|
|