]> granicus.if.org Git - zfs/commitdiff
Fix dprintf format specifiers
authorNed Bass <bass6@llnl.gov>
Thu, 23 Oct 2014 23:59:27 +0000 (16:59 -0700)
committerBrian Behlendorf <behlendorf1@llnl.gov>
Mon, 17 Nov 2014 19:13:45 +0000 (11:13 -0800)
Fix a few dprintf format specifiers that disagreed with their argument
types.  These came to light as compiler errors when converting dprintf
to use the Linux trace buffer.  Previously this wasn't a problem,
presumably because the SPL debug logging uses vsnprintf which must
perform automatic type conversion.

Signed-off-by: Ned Bass <bass6@llnl.gov>
Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
module/zfs/arc.c
module/zfs/bptree.c
module/zfs/space_map.c
module/zfs/zap.c
module/zfs/zfs_vfsops.c

index 148b208a800565257e001a5f452dab4873258509..fd593a13e8ef7152a175b5c839505e92f8f92daf 100644 (file)
@@ -1928,7 +1928,7 @@ top:
 
        if (bytes_evicted < bytes)
                dprintf("only evicted %lld bytes from %x\n",
-                   (longlong_t)bytes_evicted, state);
+                   (longlong_t)bytes_evicted, state->arcs_state);
 
        if (skipped)
                ARCSTAT_INCR(arcstat_evict_skip, skipped);
index 61fa17f6ee9f7bd951cdaa99c9a7ea4b5efb62a2..0eafa4d7d8ae7e5a1512187fa95523c273e70dc5 100644 (file)
@@ -221,7 +221,7 @@ bptree_iterate(objset_t *os, uint64_t obj, boolean_t free, bptree_itor_t func,
 
                if (zfs_free_leak_on_eio)
                        flags |= TRAVERSE_HARD;
-               zfs_dbgmsg("bptree index %d: traversing from min_txg=%lld "
+               zfs_dbgmsg("bptree index %lld: traversing from min_txg=%lld "
                    "bookmark %lld/%lld/%lld/%lld",
                    i, (longlong_t)bte.be_birth_txg,
                    (longlong_t)bte.be_zb.zb_objset,
index 0ceccf669618ca73c9eac6ec53d4b1842d38b6df..fc0df756e6aa255e37bf5843805ff3a97e4397f8 100644 (file)
@@ -427,7 +427,7 @@ space_map_truncate(space_map_t *sm, dmu_tx_t *tx)
            doi.doi_bonus_size != sizeof (space_map_phys_t)) ||
            doi.doi_data_block_size != space_map_blksz) {
                zfs_dbgmsg("txg %llu, spa %s, reallocating: "
-                   "old bonus %u, old blocksz %u", dmu_tx_get_txg(tx),
+                   "old bonus %llu, old blocksz %u", dmu_tx_get_txg(tx),
                    spa_name(spa), doi.doi_bonus_size, doi.doi_data_block_size);
 
                space_map_free(sm, tx);
index 02c92748f6c050210deca4441361e2a04a1324d2..4ee75b6d92295df93dc394d3d2e24a7ff9685efa 100644 (file)
@@ -209,7 +209,7 @@ zap_table_grow(zap_t *zap, zap_table_phys_t *tbl,
                tbl->zt_nextblk = 0;
                tbl->zt_blks_copied = 0;
 
-               dprintf("finished; numblocks now %llu (%lluk entries)\n",
+               dprintf("finished; numblocks now %llu (%uk entries)\n",
                    tbl->zt_numblks, 1<<(tbl->zt_shift-10));
        }
 
index eea78417a5ba2391580dfcedf283c838ab6e1bbf..d67f11eca08b84644736dac75fd25b07cc0fba5c 100644 (file)
@@ -1436,7 +1436,7 @@ zfs_vget(struct super_block *sb, struct inode **ipp, fid_t *fidp)
 
        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", object, fid_gen, gen_mask);
        if ((err = zfs_zget(zsb, object, &zp))) {
                ZFS_EXIT(zsb);
                return (err);
@@ -1447,7 +1447,8 @@ zfs_vget(struct super_block *sb, struct inode **ipp, fid_t *fidp)
        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", zp_gen,
+                   fid_gen);
                iput(ZTOI(zp));
                ZFS_EXIT(zsb);
                return (SET_ERROR(EINVAL));