Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752212AbdHHNUI (ORCPT ); Tue, 8 Aug 2017 09:20:08 -0400 Received: from mail-pf0-f195.google.com ([209.85.192.195]:33089 "EHLO mail-pf0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752003AbdHHNUG (ORCPT ); Tue, 8 Aug 2017 09:20:06 -0400 Date: Tue, 8 Aug 2017 09:20:02 -0400 From: Shamir Rabinovitch To: =?iso-8859-1?Q?H=E5kon?= Bugge Cc: Santosh Shilimkar , "David S . Miller" , netdev@vger.kernel.org, linux-rdma@vger.kernel.org, rds-devel@oss.oracle.com, linux-kernel@vger.kernel.org, knut.omang@oracle.com, wei.lin-guay@oracle.com Subject: Re: [PATCH net] rds: Reintroduce statistics counting Message-ID: <20170808132002.GA9848@shamir-net-srv.us.oracle.com> References: <20170808091332.5413-1-Haakon.Bugge@oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20170808091332.5413-1-Haakon.Bugge@oracle.com> User-Agent: Mutt/1.5.20 (2009-12-10) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1766 Lines: 50 On Tue, Aug 08, 2017 at 11:13:32AM +0200, H?kon Bugge wrote: > In commit 7e3f2952eeb1 ("rds: don't let RDS shutdown a connection > while senders are present"), refilling the receive queue was removed > from rds_ib_recv(), along with the increment of > s_ib_rx_refill_from_thread. > > Commit 73ce4317bf98 ("RDS: make sure we post recv buffers") > re-introduces filling the receive queue from rds_ib_recv(), but does > not add the statistics counter. rds_ib_recv() was later renamed to > rds_ib_recv_path(). > > This commit reintroduces the statistics counting of > s_ib_rx_refill_from_thread and s_ib_rx_refill_from_cq. > > Signed-off-by: H?kon Bugge > Reviewed-by: Knut Omang > Reviewed-by: Wei Lin Guay > --- > net/rds/ib_recv.c | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > > diff --git a/net/rds/ib_recv.c b/net/rds/ib_recv.c > index e10624a..9722bf8 100644 > --- a/net/rds/ib_recv.c > +++ b/net/rds/ib_recv.c > @@ -1015,8 +1015,10 @@ void rds_ib_recv_cqe_handler(struct rds_ib_connection *ic, > if (rds_ib_ring_empty(&ic->i_recv_ring)) > rds_ib_stats_inc(s_ib_rx_ring_empty); > > - if (rds_ib_ring_low(&ic->i_recv_ring)) > + if (rds_ib_ring_low(&ic->i_recv_ring)) { > rds_ib_recv_refill(conn, 0, GFP_NOWAIT); > + rds_ib_stats_inc(s_ib_rx_refill_from_cq); > + } > } > > int rds_ib_recv_path(struct rds_conn_path *cp) > @@ -1029,6 +1031,7 @@ int rds_ib_recv_path(struct rds_conn_path *cp) > if (rds_conn_up(conn)) { > rds_ib_attempt_ack(ic); > rds_ib_recv_refill(conn, 0, GFP_KERNEL); > + rds_ib_stats_inc(s_ib_rx_refill_from_thread); > } > > return ret; > -- > 2.9.3 > Reviewed-by: Shamir Rabinovitch