Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 0a87e7bc authored by Arnaldo Carvalho de Melo's avatar Arnaldo Carvalho de Melo
Browse files

perf scripting perl: Do not die() when not founding event for a type

Do just like handling other cases i.e. print some debug message and
ignore the sample.

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/n/tip-t7kzlm3cxyvbd7d9n9554ai9@git.kernel.org


Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent e28ff1a8
Loading
Loading
Loading
Loading
+4 −2
Original line number Original line Diff line number Diff line
@@ -350,8 +350,10 @@ static void perl_process_tracepoint(struct perf_sample *sample,
	if (evsel->attr.type != PERF_TYPE_TRACEPOINT)
	if (evsel->attr.type != PERF_TYPE_TRACEPOINT)
		return;
		return;


	if (!event)
	if (!event) {
		die("ug! no event found for type %" PRIu64, (u64)evsel->attr.config);
		pr_debug("ug! no event found for type %" PRIu64, (u64)evsel->attr.config);
		return;
	}


	pid = raw_field_value(event, "common_pid", data);
	pid = raw_field_value(event, "common_pid", data);