aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/builtin-record.c
diff options
context:
space:
mode:
authorDavid S. Miller <[email protected]>2018-11-12 01:57:54 +0000
committerDavid S. Miller <[email protected]>2018-11-12 01:57:54 +0000
commit2b9b7502dfcb6169dbf3359702953bf756b4e273 (patch)
tree58ab22096d49de6a0e049cf1267edc34b82916dc /tools/perf/builtin-record.c
parentPCI: add USR vendor id and use it in r8169 and w6692 driver (diff)
parentLinux 4.20-rc2 (diff)
downloadkernel-2b9b7502dfcb6169dbf3359702953bf756b4e273.tar.gz
kernel-2b9b7502dfcb6169dbf3359702953bf756b4e273.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'tools/perf/builtin-record.c')
-rw-r--r--tools/perf/builtin-record.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/perf/builtin-record.c b/tools/perf/builtin-record.c
index 10cf889c6d75..488779bc4c8d 100644
--- a/tools/perf/builtin-record.c
+++ b/tools/perf/builtin-record.c
@@ -391,7 +391,12 @@ try_again:
ui__warning("%s\n", msg);
goto try_again;
}
-
+ if ((errno == EINVAL || errno == EBADF) &&
+ pos->leader != pos &&
+ pos->weak_group) {
+ pos = perf_evlist__reset_weak_group(evlist, pos);
+ goto try_again;
+ }
rc = -errno;
perf_evsel__open_strerror(pos, &opts->target,
errno, msg, sizeof(msg));