perf tools: Handle kernels that don't support attr.exclude_{guest,host}
[firefly-linux-kernel-4.4.55.git] / tools / perf / perf.h
index 64f8bee31ced8d7eb3586788e4a69f872c33e57a..8b9c43635f4dfabe52545f5d8d1605f18e17cbf0 100644 (file)
@@ -167,7 +167,6 @@ sys_perf_event_open(struct perf_event_attr *attr,
                      pid_t pid, int cpu, int group_fd,
                      unsigned long flags)
 {
-       attr->size = sizeof(*attr);
        return syscall(__NR_perf_event_open, attr, pid, cpu,
                       group_fd, flags);
 }
@@ -186,8 +185,9 @@ extern const char perf_version_string[];
 void pthread__unblock_sigwinch(void);
 
 struct perf_record_opts {
-       pid_t        target_pid;
-       pid_t        target_tid;
+       const char   *target_pid;
+       const char   *target_tid;
+       uid_t        uid;
        bool         call_graph;
        bool         group;
        bool         inherit_stat;
@@ -199,6 +199,7 @@ struct perf_record_opts {
        bool         sample_address;
        bool         sample_time;
        bool         sample_id_all_avail;
+       bool         exclude_guest_missing;
        bool         system_wide;
        bool         period;
        unsigned int freq;