ring-buffer/selftest: Add ring-buffer mapping test
authorVincent Donnefort <vdonnefort@google.com>
Fri, 10 May 2024 14:04:34 +0000 (15:04 +0100)
committerSteven Rostedt (Google) <rostedt@goodmis.org>
Mon, 13 May 2024 22:09:56 +0000 (18:09 -0400)
commit75961e55415cdc368ca2d7f6203fb627c259d58a
treeba48d042becbed09a613d080dd45ff5d700fd146
parenta1e0dd7ce38af3fb1a3bc54a222a7c5e4eaa4202
ring-buffer/selftest: Add ring-buffer mapping test

Map a ring-buffer, validate the meta-page before and after emitting few
events. Also check ring-buffer mapping boundaries and finally ensure the
tracing snapshot is mutually exclusive.

Link: https://lore.kernel.org/linux-trace-kernel/20240510140435.3550353-6-vdonnefort@google.com
Cc: Shuah Khan <shuah@kernel.org>
Cc: Shuah Khan <skhan@linuxfoundation.org>
Cc: linux-kselftest@vger.kernel.org
Acked-by: Muhammad Usama Anjum <usama.anjum@collabora.com>
Signed-off-by: Vincent Donnefort <vdonnefort@google.com>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
tools/testing/selftests/ring-buffer/.gitignore [new file with mode: 0644]
tools/testing/selftests/ring-buffer/Makefile [new file with mode: 0644]
tools/testing/selftests/ring-buffer/config [new file with mode: 0644]
tools/testing/selftests/ring-buffer/map_test.c [new file with mode: 0644]