Whamcloud - gitweb
LU-4423 ptlrpc: use 64-bit time for adaptive timeout
[fs/lustre-release.git] / lustre / include / lustre_import.h
index a26f272..51351a4 100644 (file)
 #define AT_FLG_NOHIST 0x1          /* use last reported value only */
 
 struct adaptive_timeout {
-       time_t          at_binstart;         /* bin start time */
+       time64_t        at_binstart;         /* bin start time */
        unsigned int    at_hist[AT_BINS];    /* timeout history bins */
        unsigned int    at_flags;
        unsigned int    at_current;          /* current timeout value */
        unsigned int    at_worst_ever;       /* worst-ever timeout value */
-       time_t          at_worst_time;       /* worst-ever timeout timestamp */
+       time64_t        at_worst_time;       /* worst-ever timeout timestamp */
        spinlock_t      at_lock;
 };
 
@@ -342,7 +342,7 @@ static inline void at_reset_nolock(struct adaptive_timeout *at, int val)
 {
         at->at_current = val;
         at->at_worst_ever = val;
-        at->at_worst_time = cfs_time_current_sec();
+       at->at_worst_time = ktime_get_real_seconds();
 }
 
 static inline void at_reset(struct adaptive_timeout *at, int val)