From bc96b361cbf90e61d2665b1305cd2c4ac1fd9cfc Mon Sep 17 00:00:00 2001 From: Namhyung Kim Date: Mon, 18 Mar 2013 11:41:47 +0900 Subject: perf tests: Add a test case for checking sw clock event frequency This test case checks frequency conversion of hrtimer-based software clock events (cpu-clock, task-clock) have valid (non-1) periods. Signed-off-by: Namhyung Kim Cc: Ingo Molnar Cc: Jiri Olsa Cc: Peter Zijlstra Link: http://lkml.kernel.org/r/1363574507-18808-2-git-send-email-namhyung@kernel.org [ committer note: Moved .sample_freq to outside named init block to cope with some gcc versions ] Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/tests/builtin-test.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'tools/perf/tests/builtin-test.c') diff --git a/tools/perf/tests/builtin-test.c b/tools/perf/tests/builtin-test.c index 9b5c70a180d2..0918ada4cc41 100644 --- a/tools/perf/tests/builtin-test.c +++ b/tools/perf/tests/builtin-test.c @@ -89,6 +89,10 @@ static struct test { .desc = "Test number of exit event of a simple workload", .func = test__task_exit, }, + { + .desc = "Test software clock events have valid period values", + .func = test__sw_clock_freq, + }, { .func = NULL, }, -- cgit v1.2.3