ZTS: Fix zvol_misc_volmode test
commit399159f7fbef693a77d9aef50b119cc7c10edc01
authorBrian Behlendorf <behlendorf1@llnl.gov>
Thu, 10 Feb 2022 01:00:03 +0000 (9 17:00 -0800)
committerGitHub <noreply@github.com>
Thu, 10 Feb 2022 01:00:03 +0000 (9 17:00 -0800)
treea5e8aad696f21062b5a9a236202612e6ff8a3e15
parent3819aaaff921733a58e091b37b5e87b740356542
ZTS: Fix zvol_misc_volmode test

Changing volmode may need to remove minors, which could be open, so
call udev_wait() before we "zfs set volmode=<value>".  This ensures
no udev process has the zvol open (i.e. blkid) and the kernel
zvol_remove_minor_impl() function won't skip removing the in use
device.

Reviewed-by: John Kennedy <john.kennedy@delphix.com>
Reviewed-by: George Melikov <mail@gmelikov.ru>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Closes #13075
tests/zfs-tests/tests/functional/zvol/zvol_misc/zvol_misc_volmode.ksh