Linux RDMA and InfiniBand development
 help / color / mirror / Atom feed
From: Leon Romanovsky <leon@kernel.org>
To: Junxian Huang <huangjunxian6@hisilicon.com>
Cc: jgg@ziepe.ca, linux-rdma@vger.kernel.org, linuxarm@huawei.com,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH for-next 3/3] RDMA/hns: Support SW stats with debugfs
Date: Wed, 15 Nov 2023 16:26:13 +0200	[thread overview]
Message-ID: <20231115142613.GD51912@unreal> (raw)
In-Reply-To: <20231114123449.1106162-4-huangjunxian6@hisilicon.com>

On Tue, Nov 14, 2023 at 08:34:49PM +0800, Junxian Huang wrote:
> Support SW stats with debugfs.
> 
> Query output:
> $ cat /sys/kernel/debug/hns_roce/hns_0/sw_stat/sw_stat
> aeqe                 --- 3341
> ceqe                 --- 0
> cmds                 --- 6764
> cmds_err             --- 0
> posted_mbx           --- 3344
> polled_mbx           --- 3
> mbx_event            --- 3341
> qp_create_err        --- 0
> qp_modify_err        --- 0
> cq_create_err        --- 0
> cq_modify_err        --- 0
> srq_create_err       --- 0
> srq_modify_err       --- 0
> xrcd_alloc_err       --- 0
> mr_reg_err           --- 0
> mr_rereg_err         --- 0
> ah_create_err        --- 0
> mmap_err             --- 0
> uctx_alloc_err       --- 0

From one side, 
Everything will be much easier if you use one file == one value. It will
remove the need in seq_* calls. Your "cat ../sw_stat" is not atomic and
doesn't present snapshot anyway.

From another,
It is debugfs and it is upto you.

Let's wait a couple of days more and if no one complains, I'll apply it as is.

Thanks

  reply	other threads:[~2023-11-15 14:26 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-14 12:34 [PATCH for-next 0/3] Support SW stats with debugfs Junxian Huang
2023-11-14 12:34 ` [PATCH for-next 1/3] RDMA/hns: Fix inappropriate err code for unsupported operations Junxian Huang
2023-11-14 12:34 ` [PATCH for-next 2/3] RDMA/hns: Add debugfs to hns RoCE Junxian Huang
2023-11-14 12:34 ` [PATCH for-next 3/3] RDMA/hns: Support SW stats with debugfs Junxian Huang
2023-11-15 14:26   ` Leon Romanovsky [this message]
2023-11-19 12:56 ` [PATCH for-next 0/3] " 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=20231115142613.GD51912@unreal \
    --to=leon@kernel.org \
    --cc=huangjunxian6@hisilicon.com \
    --cc=jgg@ziepe.ca \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=linuxarm@huawei.com \
    /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