From mboxrd@z Thu Jan 1 00:00:00 1970 From: xiubli@redhat.com Subject: [PATCH resend v5 04/11] ceph: add r_end_stamp for the osdc request Date: Wed, 29 Jan 2020 03:27:08 -0500 Message-ID: <20200129082715.5285-5-xiubli@redhat.com> References: <20200129082715.5285-1-xiubli@redhat.com> Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Return-path: Received: from us-smtp-2.mimecast.com ([207.211.31.81]:57188 "EHLO us-smtp-delivery-1.mimecast.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726246AbgA2I17 (ORCPT ); Wed, 29 Jan 2020 03:27:59 -0500 In-Reply-To: <20200129082715.5285-1-xiubli@redhat.com> Sender: ceph-devel-owner@vger.kernel.org List-ID: To: jlayton@kernel.org, idryomov@gmail.com, zyan@redhat.com Cc: sage@redhat.com, pdonnell@redhat.com, ceph-devel@vger.kernel.org, Xiubo Li From: Xiubo Li Grab the osdc requests' end time stamp. Signed-off-by: Xiubo Li --- include/linux/ceph/osd_client.h | 1 + net/ceph/osd_client.c | 2 ++ 2 files changed, 3 insertions(+) diff --git a/include/linux/ceph/osd_client.h b/include/linux/ceph/osd_cli= ent.h index 9d9f745b98a1..00a449cfc478 100644 --- a/include/linux/ceph/osd_client.h +++ b/include/linux/ceph/osd_client.h @@ -213,6 +213,7 @@ struct ceph_osd_request { /* internal */ unsigned long r_stamp; /* jiffies, send or check time */ unsigned long r_start_stamp; /* jiffies */ + unsigned long r_end_stamp; /* jiffies */ int r_attempts; u32 r_map_dne_bound; =20 diff --git a/net/ceph/osd_client.c b/net/ceph/osd_client.c index 8ff2856e2d52..108c9457d629 100644 --- a/net/ceph/osd_client.c +++ b/net/ceph/osd_client.c @@ -2389,6 +2389,8 @@ static void finish_request(struct ceph_osd_request = *req) WARN_ON(lookup_request_mc(&osdc->map_checks, req->r_tid)); dout("%s req %p tid %llu\n", __func__, req, req->r_tid); =20 + req->r_end_stamp =3D jiffies; + if (req->r_osd) unlink_request(req->r_osd, req); atomic_dec(&osdc->num_requests); --=20 2.21.0