Whamcloud - gitweb
LU-6245 server: remove types abstraction from quota/target/nodemap code 87/21187/12
authorJames Simmons <uja.ornl@yahoo.com>
Sat, 10 Sep 2016 15:01:31 +0000 (11:01 -0400)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 26 Sep 2016 15:19:33 +0000 (15:19 +0000)
Originally when lustre code was built for userland we needed
a proper way to handle 32 bit and 64 bit platforms when
reporting unsigned longs. Now that this code is only built
for kernel space and the kernel has it own special string
handling functions we don't need this abstraction anymore.
Remove this abstraction from the quota/target/nodemap code.

Change-Id: Ie3d4fa79dc687fc85296c3a4b21655001d0c7081
Signed-off-by: James Simmons <uja.ornl@yahoo.com>
Reviewed-on: http://review.whamcloud.com/21187
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
Reviewed-by: Frank Zago <fzago@cray.com>
Reviewed-by: John L. Hammond <john.hammond@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
18 files changed:
lustre/ptlrpc/nodemap_storage.c
lustre/quota/lproc_quota.c
lustre/quota/lquota_entry.c
lustre/quota/qmt_entry.c
lustre/quota/qmt_handler.c
lustre/quota/qmt_lock.c
lustre/quota/qsd_entry.c
lustre/quota/qsd_handler.c
lustre/quota/qsd_lock.c
lustre/quota/qsd_reint.c
lustre/quota/qsd_writeback.c
lustre/target/out_handler.c
lustre/target/out_lib.c
lustre/target/tgt_handler.c
lustre/target/tgt_lastrcvd.c
lustre/target/update_records.c
lustre/target/update_recovery.c
lustre/target/update_trans.c

index 46a467c..0648748 100644 (file)
@@ -1249,8 +1249,7 @@ int nodemap_index_read(struct lu_env *env,
        dt_read_lock(env, nodemap_idx, 0);
        version = dt_version_get(env, nodemap_idx);
        if (rdpg->rp_hash != 0 && ii->ii_version != version) {
-               CDEBUG(D_INFO, "nodemap config changed while sending, "
-                              "old "LPU64", new "LPU64"\n",
+               CDEBUG(D_INFO, "nodemap config changed inflight, old %llu, new %llu\n",
                       ii->ii_version,
                       version);
                ii->ii_hash_end = 0;
index 296169d..8c8ad65 100644 (file)
@@ -228,14 +228,12 @@ static int lprocfs_quota_seq_show(struct seq_file *p, void *v)
 
        seq_printf(p, "- %-8s %llu\n", "id:", *((__u64 *)key));
        if (fid_is_acct(fid))
-               seq_printf(p, "  %-8s { inodes: %20"LPF64"u, kbytes: %20"LPF64
-                          "u }\n", "usage:",
+               seq_printf(p, "  %-8s { inodes: %20llu, kbytes: %20llu }\n", "usage:",
                           ((struct lquota_acct_rec *)rec)->ispace,
                           toqb(((struct lquota_acct_rec *)rec)->bspace));
        else if (fid_seq(fid) == FID_SEQ_QUOTA_GLB ||
                 fid_seq(fid) == FID_SEQ_LOCAL_NAME)
-               seq_printf(p, "  %-8s { hard: %20"LPF64"u, soft: %20"LPF64
-                          "u, granted: %20"LPF64"u, time: %20"LPF64"u }\n",
+               seq_printf(p, "  %-8s { hard: %20llu, soft: %20llu, granted: %20llu, time: %20llu }\n",
                           "limits:",
                           ((struct lquota_glb_rec *)rec)->qbr_hardlimit,
                           ((struct lquota_glb_rec *)rec)->qbr_softlimit,
index 92a9c6e..3194bfc 100644 (file)
@@ -326,7 +326,7 @@ struct lquota_entry *lqe_locate(const struct lu_env *env,
 
        OBD_SLAB_ALLOC_PTR_GFP(new, lqe_kmem, GFP_NOFS);
        if (new == NULL) {
-               CERROR("Fail to allocate lqe for id:"LPU64", "
+               CERROR("Fail to allocate lqe for id:%llu, "
                        "hash:%s\n", qid->qid_uid, site->lqs_hash->hs_name);
                RETURN(ERR_PTR(-ENOMEM));
        }
index d7a48f9..d0374cf 100644 (file)
@@ -112,9 +112,9 @@ static void qmt_lqe_debug(struct lquota_entry *lqe, void *arg,
        struct qmt_pool_info    *pool = (struct qmt_pool_info *)arg;
 
        libcfs_debug_vmsg2(msgdata, fmt, args,
-                          "qmt:%s pool:%d-%s id:"LPU64" enforced:%d hard:"LPU64
-                          " soft:"LPU64" granted:"LPU64" time:"LPU64" qunit:"
-                          LPU64" edquot:%d may_rel:"LPU64" revoke:"LPU64"\n",
+                          "qmt:%s pool:%d-%s id:%llu enforced:%d hard:%llu"
+                          " soft:%llu granted:%llu time:%llu qunit:"
+                          "%llu edquot:%d may_rel:%llu revoke:%llu\n",
                           pool->qpi_qmt->qmt_svname,
                           pool->qpi_key & 0x0000ffff,
                           RES_NAME(pool->qpi_key >> 16),
@@ -327,7 +327,7 @@ int qmt_slv_read(const struct lu_env *env, struct lquota_entry *lqe,
                RETURN(rc);
        }
 
-       LQUOTA_DEBUG(lqe, "successful slv read "LPU64, *granted);
+       LQUOTA_DEBUG(lqe, "successful slv read %llu", *granted);
 
        RETURN(0);
 }
@@ -360,7 +360,7 @@ int qmt_slv_write(const struct lu_env *env, struct thandle *th,
        LASSERT(lqe_is_master(lqe));
        LASSERT(lqe_is_locked(lqe));
 
-       LQUOTA_DEBUG(lqe, "write slv "DFID" granted:"LPU64,
+       LQUOTA_DEBUG(lqe, "write slv "DFID" granted:%llu",
                     PFID(lu_object_fid(&slv_obj->do_lu)), granted);
 
        /* never delete the entry, otherwise, it'll not be transferred
@@ -375,7 +375,7 @@ int qmt_slv_write(const struct lu_env *env, struct thandle *th,
                               (struct dt_rec *)rec, flags, ver);
        if (rc) {
                LQUOTA_ERROR(lqe, "failed to update slave index "DFID" granted:"
-                            LPU64, PFID(lu_object_fid(&slv_obj->do_lu)),
+                            "%llu", PFID(lu_object_fid(&slv_obj->do_lu)),
                             granted);
                RETURN(rc);
        }
@@ -660,7 +660,7 @@ done:
                /* keep current qunit */
                RETURN_EXIT;
 
-       LQUOTA_DEBUG(lqe, "%s qunit to "LPU64,
+       LQUOTA_DEBUG(lqe, "%s qunit to %llu",
                     lqe->lqe_qunit < qunit ? "increasing" : "decreasing",
                     qunit);
 
index 7ae6a0c..6a84a1a 100644 (file)
@@ -118,8 +118,8 @@ static int qmt_set(const struct lu_env *env, struct qmt_device *qmt,
        now = cfs_time_current_sec();
 
        lqe_write_lock(lqe);
-       LQUOTA_DEBUG(lqe, "changing quota settings valid:%x hard:"LPU64" soft:"
-                    LPU64" time:"LPU64, valid, hard, soft, time);
+       LQUOTA_DEBUG(lqe, "changing quota settings valid:%x hard:%llu soft:"
+                    "%llu time:%llu", valid, hard, soft, time);
 
        if ((valid & QIF_TIMES) != 0 && lqe->lqe_gracetime != time) {
                /* change time settings */
@@ -378,8 +378,8 @@ int qmt_dqacq0(const struct lu_env *env, struct lquota_entry *lqe,
                GOTO(out, rc = PTR_ERR(th));
 
        lqe_write_lock(lqe);
-       LQUOTA_DEBUG(lqe, "dqacq starts uuid:%s flags:0x%x wanted:"LPU64
-                    " usage:"LPU64, obd_uuid2str(uuid), qb_flags, qb_count,
+       LQUOTA_DEBUG(lqe, "dqacq starts uuid:%s flags:0x%x wanted:%llu"
+                    " usage:%llu", obd_uuid2str(uuid), qb_flags, qb_count,
                     qb_usage);
 
        /* Legal race, limits have been removed on master, but slave didn't
@@ -415,7 +415,7 @@ int qmt_dqacq0(const struct lu_env *env, struct lquota_entry *lqe,
                    lqe->lqe_granted < qb_count) {
                        /* can't release more than granted */
                        LQUOTA_ERROR(lqe, "Release too much! uuid:%s release:"
-                                    LPU64" granted:"LPU64", total:"LPU64,
+                                    "%llu granted:%llu, total:%llu",
                                     obd_uuid2str(uuid), qb_count,
                                     slv_granted, lqe->lqe_granted);
                        GOTO(out_locked, rc = -EINVAL);
@@ -549,7 +549,7 @@ out_write:
        /* clear/set edquot flag and notify slaves via glimpse if needed */
        qmt_adjust_edquot(lqe, now);
 out_locked:
-       LQUOTA_DEBUG(lqe, "dqacq ends count:"LPU64" ver:"LPU64" rc:%d",
+       LQUOTA_DEBUG(lqe, "dqacq ends count:%llu ver:%llu rc:%d",
                     repbody->qb_count, repbody->qb_slv_ver, rc);
        lqe_write_unlock(lqe);
 out:
index ae8a035..1020ede 100644 (file)
@@ -127,7 +127,7 @@ int qmt_intent_policy(const struct lu_env *env, struct lu_device *ld,
                break;
 
        default:
-               CERROR("%s: invalid intent opcode: "LPU64"\n", qmt->qmt_svname,
+               CERROR("%s: invalid intent opcode: %llu\n", qmt->qmt_svname,
                       it->opc);
                GOTO(out, rc = err_serious(-EINVAL));
        }
@@ -267,7 +267,7 @@ int qmt_lvbo_update(struct lu_device *ld, struct ldlm_resource *res,
        LASSERT(lqe != NULL);
        lqe_getref(lqe);
 
-       LQUOTA_DEBUG(lqe, "releasing:"LPU64" may release:"LPU64,
+       LQUOTA_DEBUG(lqe, "releasing:%llu may release:%llu",
                     lvb->lvb_id_rel, lvb->lvb_id_may_rel);
 
        if (lvb->lvb_id_rel == 0) {
@@ -315,7 +315,7 @@ int qmt_lvbo_update(struct lu_device *ld, struct ldlm_resource *res,
                        QUOTA_DQACQ_FL_REL, lvb->lvb_id_rel, 0, &qti->qti_body);
        if (rc || qti->qti_body.qb_count != lvb->lvb_id_rel)
                LQUOTA_ERROR(lqe, "failed to release quota space on glimpse "
-                            LPU64"!="LPU64" rc:%d\n", qti->qti_body.qb_count,
+                            "%llu!=%llu : rc = %d\n", qti->qti_body.qb_count,
                             lvb->lvb_id_rel, rc);
        class_export_put(exp);
        if (rc)
index f4e26a0..d0b49f0 100644 (file)
@@ -138,9 +138,9 @@ static void qsd_lqe_debug(struct lquota_entry *lqe, void *arg,
        struct qsd_qtype_info   *qqi = (struct qsd_qtype_info *)arg;
 
        libcfs_debug_vmsg2(msgdata, fmt, args,
-                          "qsd:%s qtype:%s id:"LPU64" enforced:%d granted:"
-                          LPU64" pending:"LPU64" waiting:"LPU64" req:%d usage:"
-                          LPU64" qunit:"LPU64" qtune:"LPU64" edquot:%d\n",
+                          "qsd:%s qtype:%s id:%llu enforced:%d granted:"
+                          "%llu pending:%llu waiting:%llu req:%d usage:"
+                          "%llu qunit:%llu qtune:%llu edquot:%d\n",
                           qqi->qqi_qsd->qsd_svname, QTYPE_NAME(qqi->qqi_qtype),
                           lqe->lqe_id.qid_uid, lqe->lqe_enforced,
                           lqe->lqe_granted, lqe->lqe_pending_write,
@@ -212,7 +212,7 @@ int qsd_refresh_usage(const struct lu_env *env, struct lquota_entry *lqe)
                RETURN(rc);
        }
 
-       LQUOTA_DEBUG(lqe, "disk usage: "LPU64, lqe->lqe_usage);
+       LQUOTA_DEBUG(lqe, "disk usage: %llu", lqe->lqe_usage);
        RETURN(0);
 }
 
@@ -261,15 +261,15 @@ int qsd_update_index(const struct lu_env *env, struct qsd_qtype_info *qqi,
                /* Update record in global index copy */
                struct lquota_glb_rec *glb_rec = (struct lquota_glb_rec *)rec;
 
-               CDEBUG(D_QUOTA, "%s: updating global index hardlimit: "LPU64", "
-                      "softlimit: "LPU64" for id "LPU64"\n",
+               CDEBUG(D_QUOTA, "%s: updating global index hardlimit: %llu, "
+                      "softlimit: %llu for id %llu\n",
                       qqi->qqi_qsd->qsd_svname, glb_rec->qbr_hardlimit,
                       glb_rec->qbr_softlimit, qid->qid_uid);
        } else {
                /* Update record in slave index copy */
                struct lquota_slv_rec *slv_rec = (struct lquota_slv_rec *)rec;
 
-               CDEBUG(D_QUOTA, "%s: update granted to "LPU64" for id "LPU64
+               CDEBUG(D_QUOTA, "%s: update granted to %llu for id %llu"
                       "\n", qqi->qqi_qsd->qsd_svname, slv_rec->qsr_granted,
                       qid->qid_uid);
        }
@@ -286,8 +286,8 @@ int qsd_update_index(const struct lu_env *env, struct qsd_qtype_info *qqi,
 out:
        dt_trans_stop(env, qqi->qqi_qsd->qsd_dev, th);
        if (rc)
-               CERROR("%s: failed to update %s index copy for id "LPU64", rc:"
-                      "%d\n", qqi->qqi_qsd->qsd_svname,
+               CERROR("%s: failed to update %s index copy for id %llu, : rc = %d\n",
+                      qqi->qqi_qsd->qsd_svname,
                       global ? "global" : "slave", qid->qid_uid, rc);
        else if (flags == LQUOTA_SET_VER)
                qsd_bump_version(qqi, ver, global);
@@ -322,15 +322,15 @@ int qsd_update_lqe(const struct lu_env *env, struct lquota_entry *lqe,
                lqe->lqe_enforced = (glb_rec->qbr_hardlimit ||
                                     glb_rec->qbr_softlimit) ? true : false;
 
-               LQUOTA_DEBUG(lqe, "updating global index hardlimit: "LPU64", "
-                            "softlimit: "LPU64, glb_rec->qbr_hardlimit,
+               LQUOTA_DEBUG(lqe, "updating global index hardlimit: %llu, "
+                            "softlimit: %llu", glb_rec->qbr_hardlimit,
                             glb_rec->qbr_softlimit);
        } else {
                struct lquota_slv_rec *slv_rec = (struct lquota_slv_rec *)rec;
 
                lqe->lqe_granted = slv_rec->qsr_granted;
 
-               LQUOTA_DEBUG(lqe, "updating slave index, granted:"LPU64"",
+               LQUOTA_DEBUG(lqe, "updating slave index, granted:%llu",
                             slv_rec->qsr_granted);
        }
 
index 16f274c..b90ecc0 100644 (file)
@@ -45,7 +45,7 @@ static inline int qsd_request_enter(struct lquota_entry *lqe)
        }
 
        if (lqe->lqe_pending_rel != 0) {
-               LQUOTA_ERROR(lqe, "no request in flight with pending_rel="LPU64,
+               LQUOTA_ERROR(lqe, "no request in flight with pending_rel=%llu",
                             lqe->lqe_pending_rel);
                LBUG();
        }
@@ -350,12 +350,12 @@ static void qsd_req_completion(const struct lu_env *env,
         * the DQACQ since the limit for this ID has been removed, so we
         * should not update quota entry & slave index copy neither. */
        if (repbody != NULL && repbody->qb_count != 0) {
-               LQUOTA_DEBUG(lqe, "DQACQ qb_count:"LPU64, repbody->qb_count);
+               LQUOTA_DEBUG(lqe, "DQACQ qb_count:%llu", repbody->qb_count);
 
                if (req_is_rel(reqbody->qb_flags)) {
                        if (lqe->lqe_granted < repbody->qb_count) {
                                LQUOTA_ERROR(lqe, "can't release more space "
-                                            "than owned "LPU64"<"LPU64,
+                                            "than owned %llu<%llu",
                                             lqe->lqe_granted,
                                             repbody->qb_count);
                                lqe->lqe_granted = 0;
@@ -634,7 +634,7 @@ static bool qsd_acquire(const struct lu_env *env, struct lquota_entry *lqe,
        ENTRY;
 
        for (count = 0; rc == 0; count++) {
-               LQUOTA_DEBUG(lqe, "acquiring:"LPD64 " count=%d", space, count);
+               LQUOTA_DEBUG(lqe, "acquiring:%lld count=%d", space, count);
 
                if (lqe2qqi(lqe)->qqi_qsd->qsd_stopping) {
                        rc = -EINPROGRESS;
@@ -722,7 +722,7 @@ static int qsd_op_begin0(const struct lu_env *env, struct qsd_qtype_info *qqi,
                RETURN(0);
        }
 
-       LQUOTA_DEBUG(lqe, "op_begin space:"LPD64, space);
+       LQUOTA_DEBUG(lqe, "op_begin space:%lld", space);
 
        lqe_write_lock(lqe);
        lqe->lqe_waiting_write += space;
@@ -1151,7 +1151,7 @@ void qsd_op_adjust(const struct lu_env *env, struct qsd_instance *qsd,
 
        lqe = lqe_locate(env, qqi->qqi_site, qid);
        if (IS_ERR(lqe)) {
-               CERROR("%s: fail to locate lqe for id:"LPU64", type:%d\n",
+               CERROR("%s: fail to locate lqe for id:%llu, type:%d\n",
                       qsd->qsd_svname, qid->qid_uid, qtype);
                RETURN_EXIT;
        }
index 29c70cd..673b668 100644 (file)
@@ -252,13 +252,13 @@ static int qsd_glb_glimpse_ast(struct ldlm_lock *lock, void *data)
                /* valid race */
                GOTO(out, rc = -ELDLM_NO_LOCK_DATA);
 
-       CDEBUG(D_QUOTA, "%s: glimpse on glb quota locks, id:"LPU64" ver:"LPU64
-              " hard:" LPU64" soft:"LPU64"\n", qqi->qqi_qsd->qsd_svname,
+       CDEBUG(D_QUOTA, "%s: glimpse on glb quota locks, id:%llu ver:%llu"
+              " hard:" "%llu soft:%llu\n", qqi->qqi_qsd->qsd_svname,
               desc->gl_id.qid_uid, desc->gl_ver, desc->gl_hardlimit,
               desc->gl_softlimit);
 
        if (desc->gl_ver == 0) {
-               CERROR("%s: invalid global index version "LPU64"\n",
+               CERROR("%s: invalid global index version %llu\n",
                       qqi->qqi_qsd->qsd_svname, desc->gl_ver);
                GOTO(out_qqi, rc = -EINVAL);
        }
@@ -395,7 +395,7 @@ static int qsd_id_glimpse_ast(struct ldlm_lock *lock, void *data)
                /* valid race */
                GOTO(out, rc = -ELDLM_NO_LOCK_DATA);
 
-       LQUOTA_DEBUG(lqe, "glimpse on quota locks, new qunit:"LPU64,
+       LQUOTA_DEBUG(lqe, "glimpse on quota locks, new qunit:%llu",
                     desc->gl_qunit);
 
        qsd = lqe2qqi(lqe)->qqi_qsd;
@@ -416,13 +416,13 @@ static int qsd_id_glimpse_ast(struct ldlm_lock *lock, void *data)
                if (space > 0) {
                        if (lqe->lqe_pending_req > 0) {
                                LQUOTA_DEBUG(lqe, "request in flight, postpone "
-                                            "release of "LPD64, space);
+                                            "release of %lld", space);
                                lvb->lvb_id_may_rel = space;
                        } else {
                                lqe->lqe_pending_req++;
 
                                /* release quota space in glimpse reply */
-                               LQUOTA_DEBUG(lqe, "releasing "LPD64, space);
+                               LQUOTA_DEBUG(lqe, "releasing %lld", space);
                                lqe->lqe_granted -= space;
                                lvb->lvb_id_rel   = space;
 
index d9a5537..f50862e 100644 (file)
@@ -58,7 +58,7 @@ static void qsd_reint_completion(const struct lu_env *env,
        }
 
        CDEBUG(D_QUOTA, "%s: global quota lock successfully acquired, glb "
-              "fid:"DFID", glb ver:"LPU64", slv fid:"DFID", slv ver:"LPU64"\n",
+              "fid:"DFID", glb ver:%llu, slv fid:"DFID", slv ver:%llu\n",
               qsd->qsd_svname, PFID(&req_qbody->qb_fid),
               lvb->lvb_glb_ver, PFID(&rep_qbody->qb_slv_fid),
               rep_qbody->qb_slv_ver);
@@ -284,8 +284,8 @@ out:
        if (rc == 0) {
                rc = qsd_write_version(env, qqi, ver, global);
                if (rc)
-                       CERROR("%s: write version "LPU64" to "DFID" failed. "
-                              "%d\n", qsd->qsd_svname, ver, PFID(fid), rc);
+                       CERROR("%s: write version %llu to "DFID" failed : rc = %d\n",
+                              qsd->qsd_svname, ver, PFID(fid), rc);
        }
 
        RETURN(rc);
@@ -469,8 +469,8 @@ static int qsd_reint_main(void *args)
                if (rc)
                        GOTO(out_env_init, rc);
 
-               CDEBUG(D_QUOTA, "%s: glb_ver:"LPU64"/"LPU64",slv_ver:"LPU64"/"
-                      LPU64"\n", qsd->qsd_svname,
+               CDEBUG(D_QUOTA, "%s: glb_ver:%llu/%llu,slv_ver:%llu/"
+                      "%llu\n", qsd->qsd_svname,
                       qti->qti_lvb.lvb_glb_ver, qqi->qqi_glb_ver,
                       qti->qti_slv_ver, qqi->qqi_slv_ver);
        }
index 3109ca3..8352e59 100644 (file)
@@ -123,7 +123,7 @@ static void qsd_add_deferred(struct qsd_instance *qsd, struct list_head *list,
                if (upd->qur_ver == tmp->qur_ver) {
                        LASSERT(tmp->qur_lqe);
                        LQUOTA_ERROR(tmp->qur_lqe, "Found a conflict record "
-                                    "with ver:"LPU64"", tmp->qur_ver);
+                                    "with ver:%llu", tmp->qur_ver);
                        list_del_init(&tmp->qur_link);
                        qsd_upd_free(tmp);
                } else if (upd->qur_ver < tmp->qur_ver) {
@@ -151,7 +151,7 @@ static void qsd_kickoff_deferred(struct qsd_qtype_info *qqi,
                        /* drop this update */
                        list_del_init(&upd->qur_link);
                        CDEBUG(D_QUOTA, "%s: skipping deferred update ver:"
-                              LPU64"/"LPU64", global:%d, qid:"LPU64"\n",
+                              "%llu/%llu, global:%d, qid:%llu\n",
                               qqi->qqi_qsd->qsd_svname, upd->qur_ver, ver,
                               upd->qur_global, upd->qur_qid.qid_uid);
                        qsd_upd_free(upd);
@@ -165,11 +165,11 @@ static void qsd_kickoff_deferred(struct qsd_qtype_info *qqi,
                RETURN_EXIT;
 
        CDEBUG(D_QUOTA, "%s: found deferred update record. "
-              "version:"LPU64"/"LPU64", global:%d, qid:"LPU64"\n",
+              "version:%llu/%llu, global:%d, qid:%llu\n",
               qqi->qqi_qsd->qsd_svname, upd->qur_ver, ver,
               upd->qur_global, upd->qur_qid.qid_uid);
 
-       LASSERTF(upd->qur_ver > ver, "lur_ver:"LPU64", cur_ver:"LPU64"\n",
+       LASSERTF(upd->qur_ver > ver, "lur_ver:%llu, cur_ver:%llu\n",
                 upd->qur_ver, ver);
 
        /* Kick off the deferred udpate */
@@ -223,7 +223,7 @@ void qsd_upd_schedule(struct qsd_qtype_info *qqi, struct lquota_entry *lqe,
        __u64                    cur_ver;
        ENTRY;
 
-       CDEBUG(D_QUOTA, "%s: schedule update. global:%s, version:"LPU64"\n",
+       CDEBUG(D_QUOTA, "%s: schedule update. global:%s, version:%llu\n",
               qsd->qsd_svname, global ? "true" : "false", ver);
 
        upd = qsd_upd_alloc(qqi, lqe, qid, rec, ver, global);
@@ -248,11 +248,11 @@ void qsd_upd_schedule(struct qsd_qtype_info *qqi, struct lquota_entry *lqe,
                        /* legitimate race between glimpse AST and
                         * reintegration */
                        CDEBUG(D_QUOTA, "%s: discarding glb update from glimpse"
-                              " ver:"LPU64" local ver:"LPU64"\n",
+                              " ver:%llu local ver:%llu\n",
                               qsd->qsd_svname, ver, cur_ver);
                else
-                       CERROR("%s: discard slv update, ver:"LPU64" local ver:"
-                              LPU64"\n", qsd->qsd_svname, ver, cur_ver);
+                       CERROR("%s: discard slv update, ver:%llu local ver:"
+                              "%llu\n", qsd->qsd_svname, ver, cur_ver);
                qsd_upd_free(upd);
        } else if ((ver == cur_ver + 1) && qqi->qqi_glb_uptodate &&
                   qqi->qqi_slv_uptodate) {
@@ -526,8 +526,8 @@ static void qsd_cleanup_deferred(struct qsd_instance *qsd)
                write_lock(&qsd->qsd_lock);
                list_for_each_entry_safe(upd, tmp, &qqi->qqi_deferred_glb,
                                         qur_link) {
-                       CWARN("%s: Free global deferred upd: ID:"LPU64", "
-                             "ver:"LPU64"/"LPU64"\n", qsd->qsd_svname,
+                       CWARN("%s: Free global deferred upd: ID:%llu, "
+                             "ver:%llu/%llu\n", qsd->qsd_svname,
                              upd->qur_qid.qid_uid, upd->qur_ver,
                              qqi->qqi_glb_ver);
                        list_del_init(&upd->qur_link);
@@ -535,8 +535,8 @@ static void qsd_cleanup_deferred(struct qsd_instance *qsd)
                }
                list_for_each_entry_safe(upd, tmp, &qqi->qqi_deferred_slv,
                                         qur_link) {
-                       CWARN("%s: Free slave deferred upd: ID:"LPU64", "
-                             "ver:"LPU64"/"LPU64"\n", qsd->qsd_svname,
+                       CWARN("%s: Free slave deferred upd: ID:%llu, "
+                             "ver:%llu/%llu\n", qsd->qsd_svname,
                              upd->qur_qid.qid_uid, upd->qur_ver,
                              qqi->qqi_slv_ver);
                        list_del_init(&upd->qur_link);
index d9ba4dc..41a3675 100644 (file)
@@ -90,13 +90,12 @@ static inline int out_check_resent(const struct lu_env *env,
                lustre_msg_set_transno(req->rq_repmsg, req->rq_transno);
                lustre_msg_set_status(req->rq_repmsg, req->rq_status);
 
-               DEBUG_REQ(D_RPCTRACE, req, "restoring transno "LPD64"status %d",
-                         req->rq_transno, req->rq_status);
+               DEBUG_REQ(D_RPCTRACE, req, "restoring resent RPC");
 
                reconstruct(env, dt, obj, reply, index);
                return 1;
        }
-       DEBUG_REQ(D_HA, req, "no reply for RESENT req (have "LPD64")",
+       DEBUG_REQ(D_HA, req, "no reply for RESENT req (have %lld)",
                 req->rq_export->exp_target_data.ted_lcd->lcd_last_xid);
        return 0;
 }
index 1b89ff6..a16774b 100644 (file)
@@ -678,7 +678,7 @@ static int out_tx_write_exec(const struct lu_env *env, struct thandle *th,
        struct dt_object *dt_obj = arg->object;
        int rc;
 
-       CDEBUG(D_INFO, "write "DFID" pos "LPU64" buf %p, len %lu\n",
+       CDEBUG(D_INFO, "write "DFID" pos %llu buf %p, len %lu\n",
               PFID(lu_object_fid(&dt_obj->do_lu)), arg->u.write.pos,
               arg->u.write.buf.lb_buf, (unsigned long)arg->u.write.buf.lb_len);
 
index 4ca8be3..8dcb685 100644 (file)
@@ -536,7 +536,7 @@ static int tgt_handle_recovery(struct ptlrpc_request *req, int reply_fail_id)
        if (req_can_reconstruct(req, NULL)) {
                if (!(lustre_msg_get_flags(req->rq_reqmsg) &
                      (MSG_RESENT | MSG_REPLAY))) {
-                       DEBUG_REQ(D_WARNING, req, "rq_xid "LPU64" matches "
+                       DEBUG_REQ(D_WARNING, req, "rq_xid %llu matches "
                                  "saved xid, expected REPLAY or RESENT flag "
                                  "(%x)", req->rq_xid,
                                  lustre_msg_get_flags(req->rq_reqmsg));
@@ -1241,7 +1241,7 @@ static int tgt_blocking_ast(struct ldlm_lock *lock, struct ldlm_lock_desc *desc,
 
                rc = tgt_sync(&env, tgt, obj, start, end);
                if (rc < 0) {
-                       CERROR("%s: syncing "DFID" ("LPU64"-"LPU64") on lock "
+                       CERROR("%s: syncing "DFID" (%llu-%llu) on lock "
                               "cancel: rc = %d\n",
                               tgt_name(tgt), PFID(&fid),
                               lock->l_policy_data.l_extent.start,
@@ -1934,7 +1934,7 @@ static void tgt_warn_on_cksum(struct ptlrpc_request *req,
        }
 
        LCONSOLE_ERROR_MSG(0x168, "BAD WRITE CHECKSUM: %s from %s%s%s inode "
-                          DFID" object "DOSTID" extent ["LPU64"-"LPU64
+                          DFID" object "DOSTID" extent [%llu-%llu"
                           "]: client csum %x, server csum %x\n",
                           exp->exp_obd->obd_name, libcfs_id2str(req->rq_peer),
                           via, router,
index 8b98d61..e44346a 100644 (file)
@@ -464,9 +464,9 @@ int tgt_client_data_read(const struct lu_env *env, struct lu_target *tgt,
                        ptlrpc_status_ntoh(lcd->lcd_last_close_result);
        }
 
-       CDEBUG(D_INFO, "%s: read lcd @%lld uuid = %s, last_transno = "LPU64
-              ", last_xid = "LPU64", last_result = %u, last_data = %u, "
-              "last_close_transno = "LPU64", last_close_xid = "LPU64", "
+       CDEBUG(D_INFO, "%s: read lcd @%lld uuid = %s, last_transno = %llu"
+              ", last_xid = %llu, last_result = %u, last_data = %u, "
+              "last_close_transno = %llu, last_close_xid = %llu, "
               "last_close_result = %u, rc = %d\n", tgt->lut_obd->obd_name,
               *off, lcd->lcd_uuid, lcd->lcd_last_transno, lcd->lcd_last_xid,
               lcd->lcd_last_result, lcd->lcd_last_data,
@@ -550,7 +550,7 @@ out:
        mutex_unlock(&ted->ted_lcd_lock);
        dt_trans_stop(env, tgt->lut_bottom, th);
        CDEBUG(D_INFO, "%s: update last_rcvd client data for UUID = %s, "
-              "last_transno = "LPU64": rc = %d\n", tgt->lut_obd->obd_name,
+              "last_transno = %llu: rc = %d\n", tgt->lut_obd->obd_name,
               tgt->lut_lsd.lsd_uuid, tgt->lut_lsd.lsd_last_transno, rc);
 
        return rc;
@@ -569,7 +569,7 @@ int tgt_server_data_read(const struct lu_env *env, struct lu_target *tgt)
                lsd_le_to_cpu(&tti->tti_lsd, &tgt->lut_lsd);
 
        CDEBUG(D_INFO, "%s: read last_rcvd server data for UUID = %s, "
-              "last_transno = "LPU64": rc = %d\n", tgt->lut_obd->obd_name,
+              "last_transno = %llu: rc = %d\n", tgt->lut_obd->obd_name,
               tgt->lut_lsd.lsd_uuid, tgt->lut_lsd.lsd_last_transno, rc);
         return rc;
 }
@@ -591,7 +591,7 @@ int tgt_server_data_write(const struct lu_env *env, struct lu_target *tgt,
        rc = dt_record_write(env, dto, &tti->tti_buf, &tti->tti_off, th);
 
        CDEBUG(D_INFO, "%s: write last_rcvd server data for UUID = %s, "
-              "last_transno = "LPU64": rc = %d\n", tgt->lut_obd->obd_name,
+              "last_transno = %llu: rc = %d\n", tgt->lut_obd->obd_name,
               tgt->lut_lsd.lsd_uuid, tgt->lut_lsd.lsd_last_transno, rc);
 
        RETURN(rc);
@@ -610,7 +610,7 @@ int tgt_server_data_update(const struct lu_env *env, struct lu_target *tgt,
        ENTRY;
 
        CDEBUG(D_SUPER,
-              "%s: mount_count is "LPU64", last_transno is "LPU64"\n",
+              "%s: mount_count is %llu, last_transno is %llu\n",
               tgt->lut_lsd.lsd_uuid, tgt->lut_obd->u.obt.obt_mount_count,
               tgt->lut_last_transno);
 
@@ -640,7 +640,7 @@ out:
        dt_trans_stop(env, tgt->lut_bottom, th);
 
        CDEBUG(D_INFO, "%s: update last_rcvd server data for UUID = %s, "
-              "last_transno = "LPU64": rc = %d\n", tgt->lut_obd->obd_name,
+              "last_transno = %llu: rc = %d\n", tgt->lut_obd->obd_name,
               tgt->lut_lsd.lsd_uuid, tgt->lut_lsd.lsd_last_transno, rc);
        RETURN(rc);
 }
@@ -807,7 +807,7 @@ static void tgt_cb_last_committed(struct lu_env *env, struct thandle *th,
 out:
        class_export_cb_put(ccb->llcc_exp);
        if (ccb->llcc_transno)
-               CDEBUG(D_HA, "%s: transno "LPD64" is committed\n",
+               CDEBUG(D_HA, "%s: transno %lld is committed\n",
                       ccb->llcc_tgt->lut_obd->obd_name, ccb->llcc_transno);
        OBD_FREE_PTR(ccb);
 }
@@ -1183,7 +1183,7 @@ static int tgt_last_rcvd_update(const struct lu_env *env, struct lu_target *tgt,
        spin_lock(&tgt->lut_translock);
        if (th->th_result != 0) {
                if (tti->tti_transno != 0) {
-                       CERROR("%s: replay transno "LPU64" failed: rc = %d\n",
+                       CERROR("%s: replay transno %llu failed: rc = %d\n",
                               tgt_name(tgt), tti->tti_transno, th->th_result);
                }
        } else if (tti->tti_transno == 0) {
@@ -1202,7 +1202,7 @@ static int tgt_last_rcvd_update(const struct lu_env *env, struct lu_target *tgt,
        }
 
        /* filling reply data */
-       CDEBUG(D_INODE, "transno = "LPU64", last_committed = "LPU64"\n",
+       CDEBUG(D_INODE, "transno = %llu, last_committed = %llu\n",
               tti->tti_transno, tgt->lut_obd->obd_last_committed);
 
        if (req != NULL) {
@@ -1315,7 +1315,7 @@ static int tgt_last_rcvd_update(const struct lu_env *env, struct lu_target *tgt,
                if (*transno_p > tti->tti_transno) {
                        if (!tgt->lut_no_reconstruct) {
                                CERROR("%s: trying to overwrite bigger transno:"
-                                      "on-disk: "LPU64", new: "LPU64" replay: "
+                                      "on-disk: %llu, new: %llu replay: "
                                       "%d. See LU-617.\n", tgt_name(tgt),
                                       *transno_p, tti->tti_transno,
                                       req_is_replay(req));
@@ -1444,8 +1444,8 @@ static int tgt_clients_data_init(const struct lu_env *env,
                /* These exports are cleaned up by disconnect, so they
                 * need to be set up like real exports as connect does.
                 */
-               CDEBUG(D_HA, "RCVRNG CLIENT uuid: %s idx: %d lr: "LPU64
-                      " srv lr: "LPU64" lx: "LPU64" gen %u\n", lcd->lcd_uuid,
+               CDEBUG(D_HA, "RCVRNG CLIENT uuid: %s idx: %d lr: %llu"
+                      " srv lr: %llu lx: %llu gen %u\n", lcd->lcd_uuid,
                       cl_idx, last_transno, lsd->lsd_last_transno,
                       lcd_last_xid(lcd), lcd->lcd_generation);
 
@@ -1499,7 +1499,7 @@ static int tgt_clients_data_init(const struct lu_env *env,
                }
 
                /* Need to check last_rcvd even for duplicated exports. */
-               CDEBUG(D_OTHER, "client at idx %d has last_transno = "LPU64"\n",
+               CDEBUG(D_OTHER, "client at idx %d has last_transno = %llu\n",
                       cl_idx, last_transno);
 
                spin_lock(&tgt->lut_translock);
@@ -1662,9 +1662,9 @@ int tgt_server_data_init(const struct lu_env *env, struct lu_target *tgt)
        lsd->lsd_mount_count++;
 
        CDEBUG(D_INODE, "=======,=BEGIN DUMPING LAST_RCVD========\n");
-       CDEBUG(D_INODE, "%s: server last_transno: "LPU64"\n",
+       CDEBUG(D_INODE, "%s: server last_transno: %llu\n",
               tgt_name(tgt), tgt->lut_last_transno);
-       CDEBUG(D_INODE, "%s: server mount_count: "LPU64"\n",
+       CDEBUG(D_INODE, "%s: server mount_count: %llu\n",
               tgt_name(tgt), lsd->lsd_mount_count);
        CDEBUG(D_INODE, "%s: server data size: %u\n",
               tgt_name(tgt), lsd->lsd_server_size);
@@ -1796,7 +1796,7 @@ int tgt_txn_stop_cb(const struct lu_env *env, struct thandle *th,
 
        if (tti->tti_has_trans && !echo_client) {
                if (tti->tti_mult_trans == 0) {
-                       CDEBUG(D_HA, "More than one transaction "LPU64"\n",
+                       CDEBUG(D_HA, "More than one transaction %llu\n",
                               tti->tti_transno);
                        RETURN(0);
                }
index 87bd7e7..e21b1c3 100644 (file)
@@ -68,7 +68,7 @@ void update_records_dump(const struct update_records *records,
        struct update_params    *params = NULL;
        unsigned int            i;
 
-       CDEBUG(mask, "master transno = "LPU64" batchid = "LPU64" flags = %x"
+       CDEBUG(mask, "master transno = %llu batchid = %llu flags = %x"
               " ops = %d params = %d\n", records->ur_master_transno,
               records->ur_batchid, records->ur_flags, records->ur_update_count,
               records->ur_param_count);
index 85764cf..d1423fe 100644 (file)
@@ -381,14 +381,14 @@ insert_update_records_to_replay_list(struct target_distribute_txn_data *tdtd,
        int rc = 0;
        ENTRY;
 
-       CDEBUG(D_HA, "%s: insert record batchid = "LPU64" transno = "LPU64
+       CDEBUG(D_HA, "%s: insert record batchid = %llu transno = %llu"
               " mdt_index %u\n", tdtd->tdtd_lut->lut_obd->obd_name,
               record->ur_batchid, record->ur_master_transno, mdt_index);
 
        /* Update batchid if necessary */
        spin_lock(&tdtd->tdtd_batchid_lock);
        if (record->ur_batchid >= tdtd->tdtd_batchid) {
-               CDEBUG(D_HA, "%s update batchid from "LPU64 " to "LPU64"\n",
+               CDEBUG(D_HA, "%s update batchid from %llu" " to %llu\n",
                       tdtd->tdtd_lut->lut_obd->obd_name,
                       tdtd->tdtd_batchid, record->ur_batchid);
                tdtd->tdtd_batchid = record->ur_batchid + 1;
@@ -599,7 +599,7 @@ __u64 distribute_txn_get_next_transno(struct target_distribute_txn_data *tdtd)
        }
        spin_unlock(&tdtd->tdtd_replay_list_lock);
 
-       CDEBUG(D_HA, "%s: Next update transno "LPU64"\n",
+       CDEBUG(D_HA, "%s: Next update transno %llu\n",
               tdtd->tdtd_lut->lut_obd->obd_name, transno);
        return transno;
 }
index 3252de4..b45bc3e 100644 (file)
@@ -72,8 +72,7 @@ static void top_multiple_thandle_dump(struct top_multiple_thandle *tmt,
        struct sub_thandle      *st;
 
        LASSERT(tmt->tmt_magic == TOP_THANDLE_MAGIC);
-       CDEBUG(mask, "%s tmt %p refcount %d committed %d result %d "
-              "batchid "LPU64"\n",
+       CDEBUG(mask, "%s tmt %p refcount %d committed %d result %d batchid %llu\n",
               tmt->tmt_master_sub_dt ?
               tmt->tmt_master_sub_dt->dd_lu_dev.ld_obd->obd_name :
               "NULL",
@@ -1446,7 +1445,7 @@ distribute_txn_commit_batchid_update(const struct lu_env *env,
        rc = dt_record_write(env, tdtd->tdtd_batchid_obj, &buf,
                             &off, th);
 
-       CDEBUG(D_INFO, "%s: update batchid "LPU64": rc = %d\n",
+       CDEBUG(D_INFO, "%s: update batchid %llu: rc = %d\n",
               tdtd->tdtd_lut->lut_obd->obd_name, batchid, rc);
 
 stop:
@@ -1563,7 +1562,7 @@ static int distribute_txn_commit_thread(void *_arg)
        wake_up(&thread->t_ctl_waitq);
        INIT_LIST_HEAD(&list);
 
-       CDEBUG(D_HA, "%s: start commit thread committed batchid "LPU64"\n",
+       CDEBUG(D_HA, "%s: start commit thread committed batchid %llu\n",
               tdtd->tdtd_lut->lut_obd->obd_name,
               tdtd->tdtd_committed_batchid);
 
@@ -1583,8 +1582,8 @@ static int distribute_txn_commit_thread(void *_arg)
                                list_move_tail(&tmt->tmt_commit_list, &list);
                        } else if (!tdtd->tdtd_lut->lut_obd->obd_recovering) {
                                LASSERTF(tmt->tmt_batchid >= batchid,
-                                        "tmt %p tmt_batchid: "LPU64", batchid "
-                                         LPU64"\n", tmt, tmt->tmt_batchid,
+                                        "tmt %p tmt_batchid: %llu, batchid "
+                                         "%llu\n", tmt, tmt->tmt_batchid,
                                         batchid);
                                /* There are three types of distribution
                                 * transaction result
@@ -1612,8 +1611,8 @@ static int distribute_txn_commit_thread(void *_arg)
                }
                spin_unlock(&tdtd->tdtd_batchid_lock);
 
-               CDEBUG(D_HA, "%s: batchid: "LPU64" committed batchid "
-                      LPU64"\n", tdtd->tdtd_lut->lut_obd->obd_name, batchid,
+               CDEBUG(D_HA, "%s: batchid: %llu committed batchid "
+                      "%llu\n", tdtd->tdtd_lut->lut_obd->obd_name, batchid,
                       tdtd->tdtd_committed_batchid);
                /* update globally committed on a storage */
                if (batchid > tdtd->tdtd_committed_batchid) {