summaryrefslogtreecommitdiff
path: root/fs/ceph/mds_client.h
diff options
context:
space:
mode:
authorXiubo Li <xiubli@redhat.com>2020-03-20 06:45:02 +0300
committerIlya Dryomov <idryomov@gmail.com>2020-06-01 14:22:51 +0300
commit70c948206f0616c7e46130a26165b6a5d98bade4 (patch)
treee494d909a6cff5bbffd2404ba5188ed46af2fbd8 /fs/ceph/mds_client.h
parent97e27aaa9a2cbd6238c66b3251d397e0eacc9968 (diff)
downloadlinux-70c948206f0616c7e46130a26165b6a5d98bade4.tar.xz
ceph: add metadata perf metric support
Add a new "r_ended" field to struct ceph_mds_request and use that to maintain the average latency of MDS requests. URL: https://tracker.ceph.com/issues/43215 Signed-off-by: Xiubo Li <xiubli@redhat.com> Reviewed-by: Jeff Layton <jlayton@kernel.org> Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to 'fs/ceph/mds_client.h')
-rw-r--r--fs/ceph/mds_client.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/ceph/mds_client.h b/fs/ceph/mds_client.h
index 605995ae3718..cceeb33f2ff9 100644
--- a/fs/ceph/mds_client.h
+++ b/fs/ceph/mds_client.h
@@ -10,6 +10,7 @@
#include <linux/spinlock.h>
#include <linux/refcount.h>
#include <linux/utsname.h>
+#include <linux/ktime.h>
#include <linux/ceph/types.h>
#include <linux/ceph/messenger.h>
@@ -299,6 +300,8 @@ struct ceph_mds_request {
unsigned long r_timeout; /* optional. jiffies, 0 is "wait forever" */
unsigned long r_started; /* start time to measure timeout against */
+ unsigned long r_start_latency; /* start time to measure latency */
+ unsigned long r_end_latency; /* finish time to measure latency */
unsigned long r_request_started; /* start time for mds request only,
used to measure lease durations */