From: John Hammond Date: Wed, 21 Sep 2011 19:00:39 +0000 (-0500) Subject: LU-700 osc: Tally BRW_{READ,WRITE}_BYTES by bytes transferred. X-Git-Tag: 2.1.52~32 X-Git-Url: https://git.whamcloud.com/?a=commitdiff_plain;h=a7a34bb4aa0c2db3ece1f51512f7dee645bb8903;p=fs%2Flustre-release.git LU-700 osc: Tally BRW_{READ,WRITE}_BYTES by bytes transferred. Call ptlrpc_lprocfs_brw() in brw_interpret() rather than osc_send_oap_rpc() and tally by the number of bytes transferred rather than the number requested. Change-Id: Ia7191972d9671f01d942a46eba069191f130f516 Signed-off-by: John L. Hammond Reviewed-on: http://review.whamcloud.com/1402 Tested-by: Hudson Reviewed-by: Jinshan Xiong Reviewed-by: Andreas Dilger Reviewed-by: Oleg Drokin --- diff --git a/lustre/osc/osc_request.c b/lustre/osc/osc_request.c index b9499b0..887275b 100644 --- a/lustre/osc/osc_request.c +++ b/lustre/osc/osc_request.c @@ -2279,6 +2279,7 @@ static int brw_interpret(const struct lu_env *env, cl_req_completion(env, aa->aa_clerq, rc < 0 ? rc : req->rq_bulk->bd_nob_transferred); osc_release_ppga(aa->aa_ppga, aa->aa_page_count); + ptlrpc_lprocfs_brw(req, req->rq_bulk->bd_nob_transferred); RETURN(rc); } @@ -2642,7 +2643,6 @@ osc_send_oap_rpc(const struct lu_env *env, struct client_obd *cli, lprocfs_oh_tally_log2(&cli->cl_write_offset_hist, (starting_offset >> CFS_PAGE_SHIFT) + 1); } - ptlrpc_lprocfs_brw(req, aa->aa_requested_nob); client_obd_list_lock(&cli->cl_loi_list_lock);