aboutsummaryrefslogtreecommitdiffstats
path: root/module/zfs/zvol.c
diff options
context:
space:
mode:
authorBrian Behlendorf <[email protected]>2016-10-28 22:40:14 +0000
committerBrian Behlendorf <[email protected]>2016-11-02 12:14:45 -0700
commit48d3eb40c71e5840e4d9e9af7addcfef7c382511 (patch)
treef8832b7512bcdb948ab48d9fcfd145a91bac7ca6 /module/zfs/zvol.c
parentb3c159fee4ab92832e6a735431b8b5f930665fab (diff)
Add TASKQID_INVALID
Add the TASKQID_INVALID macros and update callers to use the macro instead of testing against 0. There is no functional change even though the functions in zfs_ctldir.c incorrectly used -1 instead of 0. Reviewed-by: Tom Caputi <[email protected]> Reviewed-by: Tim Chase <[email protected]> Signed-off-by: Brian Behlendorf <[email protected]> Issue #5347
Diffstat (limited to 'module/zfs/zvol.c')
-rw-r--r--module/zfs/zvol.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/module/zfs/zvol.c b/module/zfs/zvol.c
index 72a6bc5e2..b5169baf4 100644
--- a/module/zfs/zvol.c
+++ b/module/zfs/zvol.c
@@ -1895,7 +1895,7 @@ zvol_create_minors(spa_t *spa, const char *name, boolean_t async)
return;
id = taskq_dispatch(spa->spa_zvol_taskq, zvol_task_cb, task, TQ_SLEEP);
- if ((async == B_FALSE) && (id != 0))
+ if ((async == B_FALSE) && (id != TASKQID_INVALID))
taskq_wait_id(spa->spa_zvol_taskq, id);
}
@@ -1910,7 +1910,7 @@ zvol_remove_minors(spa_t *spa, const char *name, boolean_t async)
return;
id = taskq_dispatch(spa->spa_zvol_taskq, zvol_task_cb, task, TQ_SLEEP);
- if ((async == B_FALSE) && (id != 0))
+ if ((async == B_FALSE) && (id != TASKQID_INVALID))
taskq_wait_id(spa->spa_zvol_taskq, id);
}
@@ -1926,7 +1926,7 @@ zvol_rename_minors(spa_t *spa, const char *name1, const char *name2,
return;
id = taskq_dispatch(spa->spa_zvol_taskq, zvol_task_cb, task, TQ_SLEEP);
- if ((async == B_FALSE) && (id != 0))
+ if ((async == B_FALSE) && (id != TASKQID_INVALID))
taskq_wait_id(spa->spa_zvol_taskq, id);
}