staging: lustre: remove LPX64 define
[deliverable/linux.git] / drivers / staging / lustre / lustre / ptlrpc / import.c
index b4def8a20e251a5886a3492434c897cddff57ad8..f522fc5d3a93fb8868fb41a4b929f8fc654b3dbd 100644 (file)
 
 #define DEBUG_SUBSYSTEM S_RPC
 
-#include <obd_support.h>
-#include <lustre_ha.h>
-#include <lustre_net.h>
-#include <lustre_import.h>
-#include <lustre_export.h>
-#include <obd.h>
-#include <obd_cksum.h>
-#include <obd_class.h>
+#include "../include/obd_support.h"
+#include "../include/lustre_ha.h"
+#include "../include/lustre_net.h"
+#include "../include/lustre_import.h"
+#include "../include/lustre_export.h"
+#include "../include/obd.h"
+#include "../include/obd_cksum.h"
+#include "../include/obd_class.h"
 
 #include "ptlrpc_internal.h"
 
@@ -66,7 +66,7 @@ static void __import_set_state(struct obd_import *imp,
        imp->imp_state = state;
        imp->imp_state_hist[imp->imp_state_hist_idx].ish_state = state;
        imp->imp_state_hist[imp->imp_state_hist_idx].ish_time =
-               cfs_time_current_sec();
+               get_seconds();
        imp->imp_state_hist_idx = (imp->imp_state_hist_idx + 1) %
                IMP_STATE_HIST_LEN;
 }
@@ -242,7 +242,7 @@ ptlrpc_inflight_deadline(struct ptlrpc_request *req, time_t now)
 
 static unsigned int ptlrpc_inflight_timeout(struct obd_import *imp)
 {
-       time_t now = cfs_time_current_sec();
+       time_t now = get_seconds();
        struct list_head *tmp, *n;
        struct ptlrpc_request *req;
        unsigned int timeout = 0;
@@ -494,7 +494,7 @@ static int import_select_connection(struct obd_import *imp)
        }
 
        list_for_each_entry(conn, &imp->imp_conn_list, oic_item) {
-               CDEBUG(D_HA, "%s: connect to NID %s last attempt "LPU64"\n",
+               CDEBUG(D_HA, "%s: connect to NID %s last attempt %llu\n",
                       imp->imp_obd->obd_name,
                       libcfs_nid2str(conn->oic_conn->c_peer.nid),
                       conn->oic_last_attempt);
@@ -842,8 +842,7 @@ static int ptlrpc_connect_interpret(const struct lu_env *env,
        /* check that server granted subset of flags we asked for. */
        if ((ocd->ocd_connect_flags & imp->imp_connect_flags_orig) !=
            ocd->ocd_connect_flags) {
-               CERROR("%s: Server didn't granted asked subset of flags: "
-                      "asked="LPX64" grranted="LPX64"\n",
+               CERROR("%s: Server didn't granted asked subset of flags: asked=%#llx grranted=%#llx\n",
                       imp->imp_obd->obd_name,imp->imp_connect_flags_orig,
                       ocd->ocd_connect_flags);
                GOTO(out, rc = -EPROTO);
@@ -901,8 +900,7 @@ static int ptlrpc_connect_interpret(const struct lu_env *env,
                memset(&old_hdl, 0, sizeof(old_hdl));
                if (!memcmp(&old_hdl, lustre_msg_get_handle(request->rq_repmsg),
                            sizeof(old_hdl))) {
-                       LCONSOLE_WARN("Reconnect to %s (at @%s) failed due "
-                                     "bad handle "LPX64"\n",
+                       LCONSOLE_WARN("Reconnect to %s (at @%s) failed due bad handle %#llx\n",
                                      obd2cli_tgt(imp->imp_obd),
                                      imp->imp_connection->c_remote_uuid.uuid,
                                      imp->imp_dlm_handle.cookie);
@@ -923,9 +921,7 @@ static int ptlrpc_connect_interpret(const struct lu_env *env,
                         * participate since we can reestablish all of our state
                         * with server again */
                        if ((MSG_CONNECT_RECOVERING & msg_flags)) {
-                               CDEBUG(level,"%s@%s changed server handle from "
-                                      LPX64" to "LPX64
-                                      " but is still in recovery\n",
+                               CDEBUG(level,"%s@%s changed server handle from %#llx to %#llx but is still in recovery\n",
                                       obd2cli_tgt(imp->imp_obd),
                                       imp->imp_connection->c_remote_uuid.uuid,
                                       imp->imp_remote_handle.cookie,
@@ -933,8 +929,7 @@ static int ptlrpc_connect_interpret(const struct lu_env *env,
                                       request->rq_repmsg)->cookie);
                        } else {
                                LCONSOLE_WARN("Evicted from %s (at %s) "
-                                             "after server handle changed from "
-                                             LPX64" to "LPX64"\n",
+                                             "after server handle changed from %#llx to %#llx\n",
                                              obd2cli_tgt(imp->imp_obd),
                                              imp->imp_connection-> \
                                              c_remote_uuid.uuid,
@@ -998,8 +993,8 @@ static int ptlrpc_connect_interpret(const struct lu_env *env,
        if (lustre_msg_get_last_committed(request->rq_repmsg) > 0 &&
            lustre_msg_get_last_committed(request->rq_repmsg) <
            aa->pcaa_peer_committed) {
-               CERROR("%s went back in time (transno "LPD64
-                      " was previously committed, server now claims "LPD64
+               CERROR("%s went back in time (transno %lld"
+                      " was previously committed, server now claims %lld"
                       ")!  See https://bugzilla.lustre.org/show_bug.cgi?"
                       "id=9646\n",
                       obd2cli_tgt(imp->imp_obd), aa->pcaa_peer_committed,
@@ -1117,9 +1112,8 @@ finish:
                 * disable lru_resize, etc. */
                if (old_connect_flags != exp_connect_flags(exp) ||
                    aa->pcaa_initial_connect) {
-                       CDEBUG(D_HA, "%s: Resetting ns_connect_flags to server "
-                              "flags: "LPX64"\n", imp->imp_obd->obd_name,
-                             ocd->ocd_connect_flags);
+                       CDEBUG(D_HA, "%s: Resetting ns_connect_flags to server flags: %#llx\n",
+                              imp->imp_obd->obd_name, ocd->ocd_connect_flags);
                        imp->imp_obd->obd_namespace->ns_connect_flags =
                                ocd->ocd_connect_flags;
                        imp->imp_obd->obd_namespace->ns_orig_connect_flags =
@@ -1454,7 +1448,7 @@ int ptlrpc_disconnect_import(struct obd_import *imp, int noclose)
 
        if (ptlrpc_import_in_recovery(imp)) {
                struct l_wait_info lwi;
-               cfs_duration_t timeout;
+               long timeout;
 
                if (AT_OFF) {
                        if (imp->imp_server_timeout)
@@ -1537,7 +1531,7 @@ extern unsigned int at_min, at_max, at_history;
 int at_measured(struct adaptive_timeout *at, unsigned int val)
 {
        unsigned int old = at->at_current;
-       time_t now = cfs_time_current_sec();
+       time_t now = get_seconds();
        time_t binlimit = max_t(time_t, at_history / AT_BINS, 1);
 
        LASSERT(at);
This page took 0.033295 seconds and 5 git commands to generate.