perf evlist: Refcount mmaps
authorArnaldo Carvalho de Melo <[email protected]>
Mon, 8 Sep 2014 16:26:35 +0000 (13:26 -0300)
committerArnaldo Carvalho de Melo <[email protected]>
Thu, 25 Sep 2014 19:46:55 +0000 (16:46 -0300)
commit82396986032915c1572bfb74b224fcc2e4e8ba7c
tree14a4781ac1f5892ae12e18c0dd1fe159b1fb4d31
parent1b85337d0685d1dc5a6f9061434ba4316d69f3b8
perf evlist: Refcount mmaps

We need to know how many fds are using a perf mmap via
PERF_EVENT_IOC_SET_OUTPUT, so that we can know when to ditch an mmap,
refcount it.

v2: Automatically unmap it when the refcount hits one, which will happen
when all fds are filtered by perf_evlist__filter_pollfd(), in later
patches.

Cc: Adrian Hunter <[email protected]>
Cc: Borislav Petkov <[email protected]>
Cc: Corey Ashford <[email protected]>
Cc: David Ahern <[email protected]>
Cc: Frederic Weisbecker <[email protected]>
Cc: Ingo Molnar <[email protected]>
Cc: Jean Pihet <[email protected]>
Cc: Jiri Olsa <[email protected]>
Cc: Namhyung Kim <[email protected]>
Cc: Paul Mackerras <[email protected]>
Cc: Peter Zijlstra <[email protected]>
Link: http://lkml.kernel.org/r/[email protected]
Link: http://lkml.kernel.org/n/[email protected]
Signed-off-by: Arnaldo Carvalho de Melo <[email protected]>
tools/perf/util/evlist.c
tools/perf/util/evlist.h