5c581041cf
Allocating just the space needed for nr_cpus * nr_threads * nr_evsels, not the MAX_NR_CPUS and counters. LKML-Reference: <new-submission> Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: Ingo Molnar <mingo@elte.hu> Cc: Mike Galbraith <efault@gmx.de> Cc: Paul Mackerras <paulus@samba.org> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Stephane Eranian <eranian@google.com> Cc: Tom Zanussi <tzanussi@gmail.com> Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
26 lines
572 B
C
26 lines
572 B
C
#ifndef __PERF_EVLIST_H
|
|
#define __PERF_EVLIST_H 1
|
|
|
|
#include <linux/list.h>
|
|
|
|
struct pollfd;
|
|
|
|
struct perf_evlist {
|
|
struct list_head entries;
|
|
int nr_entries;
|
|
int nr_fds;
|
|
struct pollfd *pollfd;
|
|
};
|
|
|
|
struct perf_evsel;
|
|
|
|
struct perf_evlist *perf_evlist__new(void);
|
|
void perf_evlist__delete(struct perf_evlist *evlist);
|
|
|
|
void perf_evlist__add(struct perf_evlist *evlist, struct perf_evsel *entry);
|
|
int perf_evlist__add_default(struct perf_evlist *evlist);
|
|
|
|
int perf_evlist__alloc_pollfd(struct perf_evlist *evlist, int ncpus, int nthreads);
|
|
|
|
#endif /* __PERF_EVLIST_H */
|