On Fri, Jun 14, 2024 at 02:47:26PM +0200, Takashi Iwai wrote: > The control elements with volatile flag don't guarantee that the > written values are actually saved for the next reads, hence they > aren't suitable for the standard mixer tests. Skip the write tests > for those volatile controls for avoiding confusion. We should still verify that you can actually write I think... > + if (!snd_ctl_elem_info_is_volatile(ctl->info)) { > + ksft_print_msg("%s is volatile\n", ctl->name); > + ksft_test_result_skip("write_invalid.%d.%d\n", > + ctl->card->card, ctl->elem); > + return; > + } ...and that you don't read back invalid values after a write like this for example. I think any change for this should be in the validation of the read but we should still try the writes we think we can do.
Attachment:
signature.asc
Description: PGP signature
- Follow-Ups:
- References:
- [PATCH 0/5] ALSA: some driver fixes for control input validations
- From: Takashi Iwai
- [PATCH 4/5] kselftest/alsa: mixer-test: Skip write tests for volatile controls
- From: Takashi Iwai
- [PATCH 0/5] ALSA: some driver fixes for control input validations
- Prev by Date: Re: [PATCH 3/5] ALSA: control: Apply sanity check of input values for user elements
- Next by Date: Re: [PATCH 4/5] kselftest/alsa: mixer-test: Skip write tests for volatile controls
- Previous by thread: [PATCH 4/5] kselftest/alsa: mixer-test: Skip write tests for volatile controls
- Next by thread: Re: [PATCH 4/5] kselftest/alsa: mixer-test: Skip write tests for volatile controls
- Index(es):