mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-23 19:04:45 +03:00
Prefer VERIFY0(n) over VERIFY3U(n, ==, 0)
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Alexander Motin <alexander.motin@TrueNAS.com> Signed-off-by: Rob Norris <robn@despairlabs.com> Sponsored-by: https://despairlabs.com/sponsor/ Closes #17591
This commit is contained in:
committed by
Brian Behlendorf
parent
c39e076f23
commit
5c7df3bcac
@@ -863,11 +863,11 @@ spl_kmem_cache_destroy(spl_kmem_cache_t *skc)
|
||||
* Validate there are no objects in use and free all the
|
||||
* spl_kmem_slab_t, spl_kmem_obj_t, and object buffers.
|
||||
*/
|
||||
ASSERT3U(skc->skc_slab_alloc, ==, 0);
|
||||
ASSERT3U(skc->skc_obj_alloc, ==, 0);
|
||||
ASSERT3U(skc->skc_slab_total, ==, 0);
|
||||
ASSERT3U(skc->skc_obj_total, ==, 0);
|
||||
ASSERT3U(skc->skc_obj_emergency, ==, 0);
|
||||
ASSERT0(skc->skc_slab_alloc);
|
||||
ASSERT0(skc->skc_obj_alloc);
|
||||
ASSERT0(skc->skc_slab_total);
|
||||
ASSERT0(skc->skc_obj_total);
|
||||
ASSERT0(skc->skc_obj_emergency);
|
||||
ASSERT(list_empty(&skc->skc_complete_list));
|
||||
|
||||
ASSERT3U(percpu_counter_sum(&skc->skc_linux_alloc), ==, 0);
|
||||
|
||||
@@ -986,7 +986,7 @@ zfs_drop_nlink_locked(znode_t *zp, dmu_tx_t *tx, boolean_t *unlinkedp)
|
||||
SA_ADD_BULK_ATTR(bulk, count, SA_ZPL_LINKS(zfsvfs),
|
||||
NULL, &links, sizeof (links));
|
||||
error = sa_bulk_update(zp->z_sa_hdl, bulk, count, tx);
|
||||
ASSERT3U(error, ==, 0);
|
||||
ASSERT0(error);
|
||||
|
||||
if (unlinkedp != NULL)
|
||||
*unlinkedp = unlinked;
|
||||
@@ -1058,7 +1058,7 @@ zfs_link_destroy(zfs_dirlock_t *dl, znode_t *zp, dmu_tx_t *tx, int flag,
|
||||
|
||||
/* The only error is !zfs_dirempty() and we checked earlier. */
|
||||
error = zfs_drop_nlink_locked(zp, tx, &unlinked);
|
||||
ASSERT3U(error, ==, 0);
|
||||
ASSERT0(error);
|
||||
mutex_exit(&zp->z_lock);
|
||||
} else {
|
||||
error = zfs_dropname(dl, zp, dzp, tx, flag);
|
||||
|
||||
Reference in New Issue
Block a user