mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 02:27:36 +03:00
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 <behlendorf1@llnl.gov> Signed-off-by: Rich Ercolani <rincebrain@gmail.com> Closes #12233
This commit is contained in:
committed by
Brian Behlendorf
parent
dfbda2465f
commit
5e89181544
@@ -181,7 +181,7 @@ __set_error(const char *file, const char *func, int line, int err)
|
||||
* $ echo 512 >/sys/module/zfs/parameters/zfs_flags
|
||||
*/
|
||||
if (zfs_flags & ZFS_DEBUG_SET_ERROR)
|
||||
__dprintf(B_FALSE, file, func, line, "error %lu", err);
|
||||
__dprintf(B_FALSE, file, func, line, "error %lu", (ulong_t)err);
|
||||
}
|
||||
|
||||
#ifdef _KERNEL
|
||||
|
||||
@@ -1066,7 +1066,7 @@ zfsvfs_setup(zfsvfs_t *zfsvfs, boolean_t mounting)
|
||||
&zfsvfs->z_kstat, zs.zs_num_entries);
|
||||
dprintf_ds(zfsvfs->z_os->os_dsl_dataset,
|
||||
"num_entries in unlinked set: %llu",
|
||||
zs.zs_num_entries);
|
||||
(u_longlong_t)zs.zs_num_entries);
|
||||
}
|
||||
|
||||
zfs_unlinked_drain(zfsvfs);
|
||||
@@ -1880,7 +1880,9 @@ zfs_fhtovp(vfs_t *vfsp, fid_t *fidp, int flags, vnode_t **vpp)
|
||||
|
||||
gen_mask = -1ULL >> (64 - 8 * i);
|
||||
|
||||
dprintf("getting %llu [%u mask %llx]\n", object, fid_gen, gen_mask);
|
||||
dprintf("getting %llu [%llu mask %llx]\n", (u_longlong_t)object,
|
||||
(u_longlong_t)fid_gen,
|
||||
(u_longlong_t)gen_mask);
|
||||
if ((err = zfs_zget(zfsvfs, object, &zp))) {
|
||||
ZFS_EXIT(zfsvfs);
|
||||
return (err);
|
||||
@@ -1891,7 +1893,8 @@ zfs_fhtovp(vfs_t *vfsp, fid_t *fidp, int flags, vnode_t **vpp)
|
||||
if (zp_gen == 0)
|
||||
zp_gen = 1;
|
||||
if (zp->z_unlinked || zp_gen != fid_gen) {
|
||||
dprintf("znode gen (%u) != fid gen (%u)\n", zp_gen, fid_gen);
|
||||
dprintf("znode gen (%llu) != fid gen (%llu)\n",
|
||||
(u_longlong_t)zp_gen, (u_longlong_t)fid_gen);
|
||||
vrele(ZTOV(zp));
|
||||
ZFS_EXIT(zfsvfs);
|
||||
return (SET_ERROR(EINVAL));
|
||||
|
||||
Reference in New Issue
Block a user