24 Jan
2022
24 Jan
'22
11:48 p.m.
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.