linux/tools
Mark Brown b1446bda56 kselftest: alsa: Check for event generation when we write to controls
Add some coverage of event generation to mixer-test. Rather than doing a
separate set of writes designed to trigger events we add a step to the
existing write_and_verify() which checks to see if the value we read back
from non-volatile controls matches the value before writing and that an
event is or isn't generated as appropriate. The "tests" for events then
simply check that no spurious or missing events were detected. This avoids
needing further logic to generate appropriate values for each control type
and maximises coverage.

When checking for events we use a timeout of 0. This relies on the kernel
generating any event prior to returning to userspace when setting a control.
That is currently the case and it is difficult to see it changing, if it
does the test will need to be updated. Using a delay of 0 means that we
don't slow things down unduly when checking for no event or when events
fail to be generated.

We don't check behaviour for volatile controls since we can't tell what
the behaviour is supposed to be for any given control.

Signed-off-by: Mark Brown <broonie@kernel.org>
Reviewed-by: Shuah Khan <skhan@linuxfoundation.org>
Reviewed-by: Jaroslav Kysela <perex@perex.cz>
Link: https://lore.kernel.org/r/20220202150902.19563-1-broonie@kernel.org
Signed-off-by: Takashi Iwai <tiwai@suse.de>
2022-02-04 10:39:09 +01:00
..
accounting delayacct: track delays from memory compact 2022-01-20 08:52:55 +02:00
arch tools headers UAPI: Sync x86 arch prctl headers with the kernel sources 2022-01-19 14:41:29 -03:00
bootconfig bootconfig: Cleanup dummy headers in tools/bootconfig 2021-10-10 22:16:02 -04:00
bpf Merge branch 'akpm' (patches from Andrew) 2022-01-20 10:41:01 +02:00
build Merge remote-tracking branch 'torvalds/master' into perf/core 2022-01-13 10:20:59 -03:00
cgroup
counter tools/counter: Create Counter tools 2021-10-17 10:54:16 +01:00
debugging
edid
firewire
firmware
gpio
hv
iio iio: event_monitor: Flush output on event 2021-12-16 12:20:35 +00:00
include perf tools changes for v5.17: 2nd batch 2022-01-23 08:14:21 +02:00
io_uring
kvm/kvm_stat KVM: kvm_stat: do not show halt_wait_ns 2021-10-18 14:07:18 -04:00
laptop
leds
lib perf tools changes for v5.17: 2nd batch 2022-01-23 08:14:21 +02:00
memory-model tools/memory-model: litmus: Add two tests for unlock(A)+lock(B) ordering 2021-11-30 17:47:08 -08:00
objtool Merge branch 'signal-for-v5.17' of git://git.kernel.org/pub/scm/linux/kernel/git/ebiederm/user-namespace 2022-01-17 05:49:30 +02:00
pci
pcmcia
perf perf tools: Remove redundant err variable 2022-01-22 17:25:02 -03:00
power More ACPI updates for 5.17-rc1 2022-01-18 08:51:51 +02:00
rcu tools/rcu: Add an extract-stall script 2021-09-16 10:31:26 -07:00
scripts tools: Help cross-building with clang 2021-12-16 12:15:04 -08:00
spi
testing kselftest: alsa: Check for event generation when we write to controls 2022-02-04 10:39:09 +01:00
thermal/tmon thermal: tools: tmon: remove unneeded local variable 2021-11-24 17:26:13 +01:00
time
tracing rtla: Add Documentation 2022-01-13 17:02:43 -05:00
usb usb: testusb: Fix for showing the connection speed 2021-09-14 10:31:41 +02:00
virtio
vm tools/vm/page-types.c: print file offset in hexadecimal 2021-11-06 13:30:40 -07:00
wmi
Makefile tools/lib/lockdep: drop liblockdep 2021-11-12 11:07:17 -08:00