perf stat: Use nftw() instead of ftw()
authorPaul Cercueil <paul@crapouillou.net>
Mon, 8 Feb 2021 18:11:57 +0000 (18:11 +0000)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Mon, 8 Feb 2021 19:39:14 +0000 (16:39 -0300)
commita81fbb8771a3810a58d657763fde610bf2c33286
treeaaffa36629fd3a3b9312a95a43e95aa2c3f7d966
parent7d91e8181dc0ed8585e55234288d11bc5dc083b2
perf stat: Use nftw() instead of ftw()

ftw() has been obsolete for about 12 years now.

Committer notes:

Further notes provided by the patch author:

    "NOTE: Not runtime-tested, I have no idea what I need to do in perf
     to test this. But at least it compiles now with my uClibc-based
     toolchain."

I looked at the nftw()/ftw() man page and for the use made with cgroups
in 'perf stat' the end result is equivalent.

Fixes: bb1c15b60b98 ("perf stat: Support regex pattern in --for-each-cgroup")
Signed-off-by: Paul Cercueil <paul@crapouillou.net>
Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: od@zcrc.me
Cc: stable@vger.kernel.org
Link: http://lore.kernel.org/lkml/20210208181157.1324550-1-paul@crapouillou.net
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/cgroup.c