alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
From: Shuah Khan <skhan@linuxfoundation.org>
To: Mark Brown <broonie@kernel.org>
Cc: alsa-devel@alsa-project.org, Takashi Iwai <tiwai@suse.com>,
	linux-kselftest@vger.kernel.org,
	Shuah Khan <skhan@linuxfoundation.org>,
	Shuah Khan <shuah@kernel.org>
Subject: Re: [PATCH] kselftest: alsa: Add test case for writing invalid values
Date: Mon, 24 Jan 2022 15:12:47 -0700	[thread overview]
Message-ID: <92819c09-f77d-0a4b-b3cf-a144cde7e30c@linuxfoundation.org> (raw)
In-Reply-To: <Ye8enGjqmiUB9HTw@sirena.org.uk>

On 1/24/22 2:48 PM, Mark Brown wrote:
> On Mon, Jan 24, 2022 at 02:35:53PM -0700, Shuah Khan wrote:
>> On 1/24/22 8:14 AM, Mark Brown wrote:
> 
>>> +	/* Restore the default value to minimise disruption */
>>> +	err = write_and_verify(ctl, ctl->def_val, NULL);
> 
>> Why not read the value and then restore the value, in case the value
>> before the write test is different from the ctl->def_val?
> 
> That's what we're doing - def_val is the value read from the device at
> the start of the test program before it tries to do any writes, we then
> restore it at the end of every test to minimise the chances that the
> device configuration will be messed up if the test program falls over.
> 

Missed that. Sounds good. In case this is going through sound tree

Reviewed-by: Shuah Khan <skhan@linuxfoundation.org>

thanks,
-- Shuah

  reply	other threads:[~2022-01-24 22:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-24 15:14 [PATCH] kselftest: alsa: Add test case for writing invalid values Mark Brown
2022-01-24 21:35 ` Shuah Khan
2022-01-24 21:48   ` Mark Brown
2022-01-24 22:12     ` Shuah Khan [this message]
2022-01-25 14:14 ` Takashi Iwai

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=92819c09-f77d-0a4b-b3cf-a144cde7e30c@linuxfoundation.org \
    --to=skhan@linuxfoundation.org \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=shuah@kernel.org \
    --cc=tiwai@suse.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).