Thread (10 messages) 10 messages, 4 authors, 2024-08-08

Re: [PATCH v3 4/4] selftests: ALSA: Cover userspace-driven timers with test

From: Ivan Orlov <ivan.orlov0322@gmail.com>
Date: 2024-08-06 13:53:09
Also in: linux-kselftest, linux-sound, lkml

On 8/6/24 14:04, Mark Brown wrote:
On Tue, Aug 06, 2024 at 01:52:43PM +0100, Ivan Orlov wrote:
quoted
-TEST_GEN_PROGS := mixer-test pcm-test test-pcmtest-driver
+TEST_GEN_PROGS := mixer-test pcm-test utimer-test test-pcmtest-driver global-timer
This is adding the timer timer tests as standard kselftests to be run by
the wrapper script...
quoted
index 000000000000..c15ec0ba851a
--- /dev/null
+++ b/tools/testing/selftests/alsa/global-timer.c
quoted
+int main(int argc, char *argv[])
+{
+	int device, subdevice, timeout;
+
+	if (argc < 4) {
+		perror("Usage: %s <device> <subdevice> <timeout>");
+		return EXIT_FAILURE;
+	}
...but this requires specific arguments to be run which the kselftest
runner won't supply.  I'd expect it to be a good default to enumerate
and test every possible device and generate a test for each.  However it
looks like this is really intended not as a standalone test but rather
as something run from within utimer-test, in that case it should be a
TEST_GEN_PROGS_EXTENDED.
Hi Mark,

Yes, the 'global-timer' application is not a standalone test and it 
should be ran by 'utimer-test'. I had to extract the timer-binding 
functionality into a different application as we can't have 
'sound/asound.h' and 'alsa/asoundlib.h' in single source due to some 
declarations overlap problems.

I'll move the 'global-timer' tool into the TEST_GEN_PROGS_EXTENDED list.

Thank you so much for the review!

-- 
Kind regards,
Ivan Orlov
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help