]> git.ipfire.org Git - thirdparty/iproute2.git/commit
rdma: Fix SRQ resource tracking information json
authorNeta Ostrovsky <netao@nvidia.com>
Mon, 25 Oct 2021 10:37:07 +0000 (13:37 +0300)
committerStephen Hemminger <stephen@networkplumber.org>
Fri, 29 Oct 2021 22:04:45 +0000 (15:04 -0700)
commitad3a118f885382f03f975d70e5d607e70befc7dd
tree775d4376c4130c09931e9c652033d8634ab122e3
parent7a235a101b326156305c9a593d1f9f12f1465d04
rdma: Fix SRQ resource tracking information json

Fix the json output for the QPs that are associated with the SRQ -
The qpn are now displayed in a json array.

Sample output before the fix:
$ rdma res show srq lqpn 126-141 -j -p
[ {
        "ifindex":0,
"ifname":"ibp8s0f0",
"srqn":4,
"type":"BASIC",
"lqpn":["126-128,130-140"],
"pdn":9,
"pid":3581,
"comm":"ibv_srq_pingpon"
    },{
"ifindex":0,
"ifname":"ibp8s0f0",
"srqn":5,
"type":"BASIC",
"lqpn":["141"],
"pdn":10,
"pid":3584,
"comm":"ibv_srq_pingpon"
    } ]

Sample output after the fix:
$ rdma res show srq lqpn 126-141 -j -p
[ {
        "ifindex":0,
"ifname":"ibp8s0f0",
"srqn":4,
"type":"BASIC",
"lqpn":["126-128","130-140"],
"pdn":9,
"pid":3581,
"comm":"ibv_srq_pingpon"
    },{
"ifindex":0,
"ifname":"ibp8s0f0",
"srqn":5,
"type":"BASIC",
"lqpn":["141"],
"pdn":10,
"pid":3584,
"comm":"ibv_srq_pingpon"
    } ]

Fixes: 9b272e138d23 ("rdma: Add SRQ resource tracking information")
Signed-off-by: Neta Ostrovsky <netao@nvidia.com>
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
rdma/res-srq.c