aboutsummaryrefslogtreecommitdiffstats
path: root/tools/perf/tests/mmap-basic.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/perf/tests/mmap-basic.c')
-rw-r--r--tools/perf/tests/mmap-basic.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/perf/tests/mmap-basic.c b/tools/perf/tests/mmap-basic.c
index 666b67a4df9d..4495493c9431 100644
--- a/tools/perf/tests/mmap-basic.c
+++ b/tools/perf/tests/mmap-basic.c
@@ -3,6 +3,7 @@
3#include "thread_map.h" 3#include "thread_map.h"
4#include "cpumap.h" 4#include "cpumap.h"
5#include "tests.h" 5#include "tests.h"
6#include <linux/err.h>
6 7
7/* 8/*
8 * This test will generate random numbers of calls to some getpid syscalls, 9 * This test will generate random numbers of calls to some getpid syscalls,
@@ -65,7 +66,7 @@ int test__basic_mmap(void)
65 66
66 snprintf(name, sizeof(name), "sys_enter_%s", syscall_names[i]); 67 snprintf(name, sizeof(name), "sys_enter_%s", syscall_names[i]);
67 evsels[i] = perf_evsel__newtp("syscalls", name); 68 evsels[i] = perf_evsel__newtp("syscalls", name);
68 if (evsels[i] == NULL) { 69 if (IS_ERR(evsels[i])) {
69 pr_debug("perf_evsel__new\n"); 70 pr_debug("perf_evsel__new\n");
70 goto out_delete_evlist; 71 goto out_delete_evlist;
71 } 72 }