#ifndef __PERF_COUNTS_H
#define __PERF_COUNTS_H

#include "xyarray.h"

struct perf_counts_values {
	union {
		struct {
			u64 val;
			u64 ena;
			u64 run;
		};
		u64 values[3];
	};
};

struct perf_counts {
	s8			  scaled;
	struct perf_counts_values aggr;
	struct xyarray		  *values;
};


static inline struct perf_counts_values*
perf_counts(struct perf_counts *counts, int cpu, int thread)
{
	return xyarray__entry(counts->values, cpu, thread);
}

struct perf_counts *perf_counts__new(int ncpus, int nthreads);
void perf_counts__delete(struct perf_counts *counts);

void perf_evsel__reset_counts(struct perf_evsel *evsel);
int perf_evsel__alloc_counts(struct perf_evsel *evsel, int ncpus, int nthreads);
void perf_evsel__free_counts(struct perf_evsel *evsel);

#endif /* __PERF_COUNTS_H */
><a href='/cgit.cgi/'>index</a> : <a href='/cgit.cgi/linux/net-next.git/'>net-next.git</a></td><td class='form'><form method='get'>
<input type='hidden' name='id' value='a507c346b7fdc97296fa74626df49fdb7296a04e'/><select name='h' onchange='this.form.submit();'>
<option value='emaclite-cleanup'>emaclite-cleanup</option>
<option value='master'>master</option>
<option value='nds-private-remove' selected='selected'>nds-private-remove</option>
<option value='packet-loop-back'>packet-loop-back</option>
<option value='packet-rx-pump-back'>packet-rx-pump-back</option>
</select> <input type='submit' value='switch'/></form></td></tr>
<tr><td class='sub'>net-next plumbings</td><td class='sub right'>Tobias Klauser</td></tr></table>
<table class='tabs'><tr><td>
<a href='/cgit.cgi/linux/net-next.git/?h=nds-private-remove'>summary</a><a href='/cgit.cgi/linux/net-next.git/refs/?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e'>refs</a><a class='active' href='/cgit.cgi/linux/net-next.git/log/sound/firewire/tascam/tascam-midi.c?h=nds-private-remove'>log</a><a href='/cgit.cgi/linux/net-next.git/tree/sound/firewire/tascam/tascam-midi.c?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e'>tree</a><a href='/cgit.cgi/linux/net-next.git/commit/sound/firewire/tascam/tascam-midi.c?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e'>commit</a><a href='/cgit.cgi/linux/net-next.git/diff/sound/firewire/tascam/tascam-midi.c?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e'>diff</a></td><td class='form'><form class='right' method='get' action='/cgit.cgi/linux/net-next.git/log/sound/firewire/tascam/tascam-midi.c'>
<input type='hidden' name='h' value='nds-private-remove'/><input type='hidden' name='id' value='a507c346b7fdc97296fa74626df49fdb7296a04e'/><select name='qt'>
<option value='grep'>log msg</option>
<option value='author'>author</option>
<option value='committer'>committer</option>
<option value='range'>range</option>
</select>
<input class='txt' type='search' size='10' name='q' value=''/>
<input type='submit' value='search'/>
</form>
</td></tr></table>
<div class='path'>path: <a href='/cgit.cgi/linux/net-next.git/log/?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e'>root</a>/<a href='/cgit.cgi/linux/net-next.git/log/sound?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e'>sound</a>/<a href='/cgit.cgi/linux/net-next.git/log/sound/firewire?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e'>firewire</a>/<a href='/cgit.cgi/linux/net-next.git/log/sound/firewire/tascam?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e'>tascam</a>/<a href='/cgit.cgi/linux/net-next.git/log/sound/firewire/tascam/tascam-midi.c?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e'>tascam-midi.c</a></div><div class='content'><table class='list nowrap'><tr class='nohover'><th class='left'>Age</th><th class='left'>Commit message (<a href='/cgit.cgi/linux/net-next.git/log/sound/firewire/tascam/tascam-midi.c?h=nds-private-remove&amp;id=a507c346b7fdc97296fa74626df49fdb7296a04e&amp;showmsg=1'>Expand</a>)</th><th class='left'>Author</th><th class='left'>Files</th><th class='left'>Lines</th></tr>