netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Leon Romanovsky <leon@kernel.org>
To: Doug Ledford <dledford@redhat.com>,
	Jason Gunthorpe <jgg@mellanox.com>,
	David Ahern <dsahern@gmail.com>
Cc: RDMA mailing list <linux-rdma@vger.kernel.org>,
	Leon Romanovsky <leon@kernel.org>,
	netdev <netdev@vger.kernel.org>,
	Stephen Hemminger <stephen@networkplumber.org>
Subject: [PATCH iproute2-next v1 0/9] RDMA resource tracking
Date: Thu,  4 Jan 2018 09:01:41 +0200	[thread overview]
Message-ID: <20180104070150.15625-1-leon@kernel.org> (raw)

Changelog:
 v0 -> v1:
   * Fixed subject title in patch #1: rdam -> rdma.
   * Added newline between variable declaration and the code.
   * Add check to failure in strdup() call in rd_check_is_string_filtered().
   * Rewrote res_qp_parse_cb() to avoid long lines and extra indentation.

------------------------------------------------------------------------
Hi,

This is supplementary (user-space) part of RDMA resource tracking posted
to the RDMA mailing list for the review [1].

The main goal of this new functionality in RDMAtool is to provide debug visibility
of running applications in RDMA stack.

The current series adds new command object (resource) which provides
short summary if it is called without arguments or more detailed
information while it is called with request to present QPs.

1) Summary information:
$ rdma res
1: mlx5_0: curr/max: pd 3/16777216 cq 5/16777216 qp 4/262144
2: mlx5_1: curr/max: pd 3/16777216 cq 5/16777216 qp 4/262144
3: mlx5_2: curr/max: pd 3/16777216 cq 5/16777216 qp 4/262144
4: mlx5_3: curr/max: pd 2/16777216 cq 3/16777216 qp 2/262144
5: mlx5_4: curr/max: pd 3/16777216 cq 5/16777216 qp 4/262144

2) Summary information of specific device:
$ rdma res show mlx5_4
5: mlx5_4: curr/max: pd 3/16777216 cq 5/16777216 qp 4/262144

3) Detailed information of specific device:
$ rdma res show qp link mlx5_4
DEV/PORT  LQPN       TYPE  STATE  PID        COMM
mlx5_4/-  8          UD    RESET  0          [ipoib-verbs]
mlx5_4/1  7          UD    RTS    0          [mlx5-gsi]
mlx5_4/1  1          GSI   RTS    0          [rdma-mad]
mlx5_4/1  0          SMI   RTS    0          [rdma-mad]

$ rdma res show qp link mlx5_4/
DEV/PORT  LQPN       TYPE  STATE  PID        COMM
mlx5_4/-  8          UD    RESET  0          [ipoib-verbs]
mlx5_4/1  7          UD    RTS    0          [mlx5-gsi]
mlx5_4/1  1          GSI   RTS    0          [rdma-mad]
mlx5_4/1  0          SMI   RTS    0          [rdma-mad]

4) Wrong port (it can be 1 or 2):
$ rdma res show qp link mlx5_4/0
Wrong device name

5) Detailed information of specific device and port:
$ rdma res show qp link mlx5_4/1
DEV/PORT  LQPN       TYPE  STATE  PID        COMM
mlx5_4/1  7          UD    RTS    0          [mlx5-gsi]
mlx5_4/1  1          GSI   RTS    0          [rdma-mad]
mlx5_4/1  0          SMI   RTS    0          [rdma-mad]

6) Detailed information of QPs not-connected to port yet:
$ rdma res show qp link mlx5_4/-
DEV/PORT  LQPN       TYPE  STATE  PID        COMM
mlx5_4/-  8          UD    RESET  0          [ipoib-verbs]

7) Very detailed view:
$ rdma res show qp link mlx5_4/- -d
DEV/PORT  LQPN       RQPN       TYPE  STATE  PID        COMM            SQ-PSN     RQ-PSN     PATH-MIG
mlx5_4/-  8          ---        UD    RESET  0          [ipoib-verbs]   0          ---        ---

8) Limit display to specific columns:
$ rdma res show qp link mlx5_4/1 display pid,lqpn,comm
DEV/PORT  LQPN       PID        COMM
mlx5_4/1  7          0          [mlx5-gsi]
mlx5_4/1  1          0          [rdma-mad]
mlx5_4/1  0          0          [rdma-mad]

9) Filter specific LQPNs:
$ rdma res show qp link mlx5_4/1 display pid,lqpn,comm lqpn 0,4-7
DEV/PORT  LQPN       PID        COMM
mlx5_4/1  7          0          [mlx5-gsi]
mlx5_4/1  0          0          [rdma-mad]

Thanks

Leon Romanovsky (9):
  rdma: Add option to provide "-" sign for the port number
  rdma: Make visible the number of arguments
  rdma: Add filtering infrastructure
  rdma: Set pointer to device name position
  rdma: Allow external usage of compare string routine
  rdma: Update kernel header file
  rdma: Add resource tracking summary
  rdma: Add QP resource tracking information
  rdma: Document resource tracking

 include/uapi/rdma/rdma_netlink.h |  58 ++++-
 man/man8/rdma-resource.8         |  91 +++++++
 rdma/Makefile                    |   2 +-
 rdma/link.c                      |   2 +-
 rdma/rdma.c                      |   4 +-
 rdma/rdma.h                      |  23 +-
 rdma/res.c                       | 535 +++++++++++++++++++++++++++++++++++++++
 rdma/utils.c                     | 309 +++++++++++++++++++++-
 8 files changed, 1007 insertions(+), 17 deletions(-)
 create mode 100644 man/man8/rdma-resource.8
 create mode 100644 rdma/res.c

             reply	other threads:[~2018-01-04  7:01 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-04  7:01 Leon Romanovsky [this message]
2018-01-04  7:01 ` [PATCH iproute2-next v1 1/9] rdma: Add option to provide "-" sign for the port number Leon Romanovsky
2018-01-04  7:01 ` [PATCH iproute2-next v1 2/9] rdma: Make visible the number of arguments Leon Romanovsky
     [not found] ` <20180104070150.15625-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2018-01-04  7:01   ` [PATCH iproute2-next v1 3/9] rdma: Add filtering infrastructure Leon Romanovsky
2018-01-05  3:29     ` David Ahern
2018-01-07  7:44       ` Leon Romanovsky
2018-01-04  7:01   ` [PATCH iproute2-next v1 4/9] rdma: Set pointer to device name position Leon Romanovsky
2018-01-04  7:01   ` [PATCH iproute2-next v1 8/9] rdma: Add QP resource tracking information Leon Romanovsky
2018-01-04  7:01 ` [PATCH iproute2-next v1 5/9] rdma: Allow external usage of compare string routine Leon Romanovsky
2018-01-04  7:01 ` [PATCH iproute2-next v1 6/9] rdma: Update kernel header file Leon Romanovsky
2018-01-04  7:01 ` [PATCH iproute2-next v1 7/9] rdma: Add resource tracking summary Leon Romanovsky
2018-01-04  7:01 ` [PATCH iproute2-next v1 9/9] rdma: Document resource tracking Leon Romanovsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20180104070150.15625-1-leon@kernel.org \
    --to=leon@kernel.org \
    --cc=dledford@redhat.com \
    --cc=dsahern@gmail.com \
    --cc=jgg@mellanox.com \
    --cc=linux-rdma@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=stephen@networkplumber.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).