mirror of
https://git.freebsd.org/src.git
synced 2026-01-16 23:02:24 +00:00
Fix return value for setting zvol threading
We must return -1 instead of ENOENT if the special zvol threading property set function can't locate the dataset (this would typically happen with an encypted and unmounted zvol) so that the operation gets inserted properly into the nvlist for operations to set. This is because we want the property to be set once the zvol is decrypted again. Reviewed-by: Allan Jude <allan@klarasystems.com> Reviewed-by: Rob Norris <robn@despairlabs.com> Reviewed-by: Ameer Hamza <ahamza@ixsystems.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Motin <mav@FreeBSD.org> Signed-off-by: Andrew Walker <awalker@ixsystems.com> Closes #17836
This commit is contained in:
parent
3ea8ca8c0f
commit
adacf020ce
1 changed files with 1 additions and 1 deletions
|
|
@ -410,7 +410,7 @@ zvol_set_volthreading(const char *name, boolean_t value)
|
|||
{
|
||||
zvol_state_t *zv = zvol_find_by_name(name, RW_NONE);
|
||||
if (zv == NULL)
|
||||
return (SET_ERROR(ENOENT));
|
||||
return (-1);
|
||||
zv->zv_threading = value;
|
||||
mutex_exit(&zv->zv_state_lock);
|
||||
return (0);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue