perf tools: Add test_and_set_bit function
authorJiri Olsa <jolsa@kernel.org>
Sun, 26 Oct 2014 22:44:03 +0000 (23:44 +0100)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Thu, 6 Nov 2014 20:42:13 +0000 (17:42 -0300)
commit416c419cc3799ddf7ea467c9adcb4cd038bd94a4
treeb28e3aa0ab1b163db862e52304831dff483bfca7
parent96d78059d6d9da45d77078a219924304860497f2
perf tools: Add test_and_set_bit function

Set a bit and return its old value. Stolen from kernel sources, will be
used in next patches.

Signed-off-by: Jiri Olsa <jolsa@kernel.org>
Acked-by: Namhyung Kim <namhyung@gmail.com>
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Namhyung Kim <namhyung@gmail.com>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Link: http://lkml.kernel.org/r/1414363445-22370-1-git-send-email-jolsa@kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/perf/util/include/linux/bitmap.h
tools/perf/util/include/linux/bitops.h