aboutsummaryrefslogtreecommitdiffstats
path: root/module/zfs/dsl_dir.c
diff options
context:
space:
mode:
authorRich Ercolani <[email protected]>2021-06-23 00:53:45 -0400
committerGitHub <[email protected]>2021-06-22 21:53:45 -0700
commit8e739b2c9ff446457ad04f63a3ee127ded70b996 (patch)
treecb8aed16bf38ded6d8018b2671b70c2b5741c595 /module/zfs/dsl_dir.c
parenta81b812495a20623a49c797d255ee5d89fc38790 (diff)
Annotated dprintf as printf-like
ZFS loves using %llu for uint64_t, but that requires a cast to not be noisy - which is even done in many, though not all, places. Also a couple places used %u for uint64_t, which were promoted to %llu. Reviewed-by: Brian Behlendorf <[email protected]> Signed-off-by: Rich Ercolani <[email protected]> Closes #12233
Diffstat (limited to 'module/zfs/dsl_dir.c')
-rw-r--r--module/zfs/dsl_dir.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/module/zfs/dsl_dir.c b/module/zfs/dsl_dir.c
index 90dd78702..df2c3d8f0 100644
--- a/module/zfs/dsl_dir.c
+++ b/module/zfs/dsl_dir.c
@@ -488,7 +488,7 @@ dsl_dir_hold(dsl_pool_t *dp, const char *name, void *tag,
if (next[0] == '@')
break;
dprintf("looking up %s in obj%lld\n",
- buf, dsl_dir_phys(dd)->dd_child_dir_zapobj);
+ buf, (longlong_t)dsl_dir_phys(dd)->dd_child_dir_zapobj);
err = zap_lookup(dp->dp_meta_objset,
dsl_dir_phys(dd)->dd_child_dir_zapobj,
@@ -1156,8 +1156,8 @@ dsl_dir_sync(dsl_dir_t *dd, dmu_tx_t *tx)
mutex_enter(&dd->dd_lock);
ASSERT0(dd->dd_tempreserved[tx->tx_txg & TXG_MASK]);
- dprintf_dd(dd, "txg=%llu towrite=%lluK\n", tx->tx_txg,
- dd->dd_space_towrite[tx->tx_txg & TXG_MASK] / 1024);
+ dprintf_dd(dd, "txg=%llu towrite=%lluK\n", (u_longlong_t)tx->tx_txg,
+ (u_longlong_t)dd->dd_space_towrite[tx->tx_txg & TXG_MASK] / 1024);
dd->dd_space_towrite[tx->tx_txg & TXG_MASK] = 0;
mutex_exit(&dd->dd_lock);
@@ -1344,8 +1344,9 @@ top_of_function:
retval = ERESTART;
dprintf_dd(dd, "failing: used=%lluK inflight = %lluK "
"quota=%lluK tr=%lluK err=%d\n",
- used_on_disk>>10, est_inflight>>10,
- quota>>10, asize>>10, retval);
+ (u_longlong_t)used_on_disk>>10,
+ (u_longlong_t)est_inflight>>10,
+ (u_longlong_t)quota>>10, (u_longlong_t)asize>>10, retval);
mutex_exit(&dd->dd_lock);
DMU_TX_STAT_BUMP(dmu_tx_quota);
return (SET_ERROR(retval));