diff options
Diffstat (limited to 'tools/perf/bench')
-rw-r--r-- | tools/perf/bench/futex-hash.c | 3 | ||||
-rw-r--r-- | tools/perf/bench/futex-lock-pi.c | 3 | ||||
-rw-r--r-- | tools/perf/bench/mem-functions.c | 2 | ||||
-rw-r--r-- | tools/perf/bench/numa.c | 2 |
4 files changed, 6 insertions, 4 deletions
diff --git a/tools/perf/bench/futex-hash.c b/tools/perf/bench/futex-hash.c index 9aa3a674829b..a80797763e1f 100644 --- a/tools/perf/bench/futex-hash.c +++ b/tools/perf/bench/futex-hash.c @@ -18,6 +18,7 @@ #include <stdlib.h> #include <linux/compiler.h> #include <linux/kernel.h> +#include <linux/zalloc.h> #include <sys/time.h> #include "../util/stat.h" @@ -214,7 +215,7 @@ int bench_futex_hash(int argc, const char **argv) &worker[i].futex[nfutexes-1], t); } - free(worker[i].futex); + zfree(&worker[i].futex); } print_summary(); diff --git a/tools/perf/bench/futex-lock-pi.c b/tools/perf/bench/futex-lock-pi.c index 8e9c4753e304..d02330a69745 100644 --- a/tools/perf/bench/futex-lock-pi.c +++ b/tools/perf/bench/futex-lock-pi.c @@ -12,6 +12,7 @@ #include <subcmd/parse-options.h> #include <linux/compiler.h> #include <linux/kernel.h> +#include <linux/zalloc.h> #include <errno.h> #include "bench.h" #include "futex.h" @@ -217,7 +218,7 @@ int bench_futex_lock_pi(int argc, const char **argv) worker[i].tid, worker[i].futex, t); if (multi) - free(worker[i].futex); + zfree(&worker[i].futex); } print_summary(); diff --git a/tools/perf/bench/mem-functions.c b/tools/perf/bench/mem-functions.c index 0251dd348124..64dc994c72ea 100644 --- a/tools/perf/bench/mem-functions.c +++ b/tools/perf/bench/mem-functions.c @@ -9,7 +9,6 @@ #include "debug.h" #include "../perf.h" -#include "../util/util.h" #include <subcmd/parse-options.h> #include "../util/header.h" #include "../util/cloexec.h" @@ -24,6 +23,7 @@ #include <sys/time.h> #include <errno.h> #include <linux/time64.h> +#include <linux/zalloc.h> #define K 1024 diff --git a/tools/perf/bench/numa.c b/tools/perf/bench/numa.c index a7784554a80d..a640ca7aaada 100644 --- a/tools/perf/bench/numa.c +++ b/tools/perf/bench/numa.c @@ -11,7 +11,6 @@ #include "../perf.h" #include "../builtin.h" -#include "../util/util.h" #include <subcmd/parse-options.h> #include "../util/cloexec.h" @@ -35,6 +34,7 @@ #include <linux/kernel.h> #include <linux/time64.h> #include <linux/numa.h> +#include <linux/zalloc.h> #include <numa.h> #include <numaif.h> |