瀏覽代碼

SUNRPC: Fix bytes-per-op accounting for RPC over UDP

NFS performance metrics reported zero bytes sent per op when mounting with
UDP.  The UDP socket transport wasn't properly counting the number of bytes
sent.

Signed-off-by: Chuck Lever <chuck.lever@oracle.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Chuck Lever 18 年之前
父節點
當前提交
1321d8d971
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. 1 0
      net/sunrpc/xprtsock.c

+ 1 - 0
net/sunrpc/xprtsock.c

@@ -587,6 +587,7 @@ static int xs_udp_send_request(struct rpc_task *task)
 	dprintk("RPC:       xs_udp_send_request(%u) = %d\n",
 			xdr->len - req->rq_bytes_sent, status);
 
+	task->tk_bytes_sent += status;
 	if (likely(status >= (int) req->rq_slen))
 		return 0;