On Mon, Feb 03, 2020 at 12:52:04PM -0500, Devesh Sharma wrote: > It becomes difficult to make out from the output of ibv_devinfo > if a particular gid index is RoCE v2 or not. > > Adding a string to the output of ibv_devinfo -v to display the > gid type at the end of gid. > > The output would look something like below: > $ ibv_devinfo -v -d bnxt_re2 > hca_id: bnxt_re2 > transport: InfiniBand (0) > fw_ver: 216.0.220.0 > node_guid: b226:28ff:fed3:b0f0 > sys_image_guid: b226:28ff:fed3:b0f0 > . > . > . > . > phys_state: LINK_UP (5) > GID[ 0]: fe80::b226:28ff:fed3:b0f0, IB/RoCE v1 > GID[ 1]: fe80::b226:28ff:fed3:b0f0, RoCE v2 > GID[ 2]: ::ffff:192.170.1.101, IB/RoCE v1 > GID[ 3]: ::ffff:192.170.1.101, RoCE v2 > $ > $ > > Reviewed-by: Jason Gunthrope <jgg@xxxxxxxx> > Reviewed-by: Leon Romanovsky <leon@xxxxxxxxxx> > Reviewed-by: Gal Pressman <galpress@xxxxxxxxxx> > Reviewed-by: Parav Pandit <parav@xxxxxxxxxxxx> > Signed-off-by: Devesh Sharma <devesh.sharma@xxxxxxxxxxxx> > --- > libibverbs/driver.h | 1 + > libibverbs/examples/devinfo.c | 35 ++++++++++++++++++++++++----------- > 2 files changed, 25 insertions(+), 11 deletions(-) > > diff --git a/libibverbs/driver.h b/libibverbs/driver.h > index a0e6f89..fc0699d 100644 > --- a/libibverbs/driver.h > +++ b/libibverbs/driver.h > @@ -84,6 +84,7 @@ enum verbs_qp_mask { > enum ibv_gid_type { > IBV_GID_TYPE_IB_ROCE_V1, > IBV_GID_TYPE_ROCE_V2, > + IBV_GID_TYPE_INVALID > }; > Agree with Gal, this hunk shouldn't be in the patch at all. Thanks