public inbox for netdev@vger.kernel.org 
 help / color / mirror / Atom feed
From: Leon Romanovsky <leon@kernel•org>
To: Dennis Dalessandro <dennis.dalessandro@intel•com>
Cc: Doug Ledford <dledford@redhat•com>,
	linux-rdma@vger•kernel.org,
	Stephen Hemminger <stephen@networkplumber•org>,
	Ariel Almog <ariela@mellanox•com>,
	Linux Netdev <netdev@vger•kernel.org>
Subject: Re: [PATCH rdma-next V2 25/27] RDMA/netlink: Export LID mask counter (LMC)
Date: Mon, 17 Jul 2017 21:32:58 +0300	[thread overview]
Message-ID: <20170717183258.GI3259@mtr-leonro.local> (raw)
In-Reply-To: <04e53968-c2e9-17b0-c51e-80a038e23711@intel.com>

[-- Attachment #1: Type: text/plain, Size: 2311 bytes --]

On Mon, Jul 17, 2017 at 11:14:28AM -0400, Dennis Dalessandro wrote:
> On 7/3/2017 2:28 AM, Leon Romanovsky wrote:
> > From: Leon Romanovsky <leonro@mellanox•com>
> >
> > Signed-off-by: Leon Romanovsky <leonro@mellanox•com>
> > ---
> >   drivers/infiniband/core/nldev.c  | 3 +++
> >   include/uapi/rdma/rdma_netlink.h | 5 +++++
> >   2 files changed, 8 insertions(+)
> >
> > diff --git a/drivers/infiniband/core/nldev.c b/drivers/infiniband/core/nldev.c
> > index ce733bf33ed9..f968a40ef5d3 100644
> > --- a/drivers/infiniband/core/nldev.c
> > +++ b/drivers/infiniband/core/nldev.c
> > @@ -47,6 +47,7 @@ static const struct nla_policy nldev_policy[RDMA_NLDEV_ATTR_MAX] = {
> >   	[RDMA_NLDEV_ATTR_SUBNET_PREFIX]	= { .type = NLA_U64 },
> >   	[RDMA_NLDEV_ATTR_LID]		= { .type = NLA_U32 },
> >   	[RDMA_NLDEV_ATTR_SM_LID]	= { .type = NLA_U32 },
> > +	[RDMA_NLDEV_ATTR_LMC]		= { .type = NLA_U8 },
> >   };
> >   static int fill_dev_info(struct sk_buff *msg, struct ib_device *device)
> > @@ -109,6 +110,8 @@ static int fill_port_info(struct sk_buff *msg,
> >   			return -EMSGSIZE;
> >   		if (nla_put_u32(msg, RDMA_NLDEV_ATTR_SM_LID, attr.sm_lid))
> >   			return -EMSGSIZE;
> > +		if (nla_put_u8(msg, RDMA_NLDEV_ATTR_LMC, attr.lmc))
> > +			return -EMSGSIZE;
> >   	}
> >   	return 0;
> >   }
> > diff --git a/include/uapi/rdma/rdma_netlink.h b/include/uapi/rdma/rdma_netlink.h
> > index 82e0d64346e1..d4b862e8ed15 100644
> > --- a/include/uapi/rdma/rdma_netlink.h
> > +++ b/include/uapi/rdma/rdma_netlink.h
> > @@ -292,6 +292,11 @@ enum rdma_nldev_attr {
> >   	RDMA_NLDEV_ATTR_LID,			/* u32 */
> >   	RDMA_NLDEV_ATTR_SM_LID,			/* u32 */
> > +	/*
> > +	 * LID mask count (LMC)
> > +	 */
> > +	RDMA_NLDEV_ATTR_LMC,			/* u8 */
> > +
> >   	RDMA_NLDEV_ATTR_MAX
> >   };
> >   #endif /* _UAPI_RDMA_NETLINK_H */
> >
>
> LMC = "Counter" or "Control"? I always thought it was the latter.

You are right, it is control.
From spec:
LID Mask Control - A per-port value assigned by the Subnet Manager. The value of the LMC
specifies the number of Path Bits in the Local Identifier.

I don't know why I called it "counter".

It is wrong comment and not something else, so I'll wait till Doug's branches will be ready and send fix after that.

Thanks

>
> -Denny

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  reply	other threads:[~2017-07-17 18:33 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-07-03  6:28 [PATCH rdma-next V2 00/27] RDMA Netlink Device Client Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 02/27] RDMA/netlink: Simplify the put_msg and put_attr Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 03/27] RDMA/netlink: Rename and remove redundant parameter from ibnl_unicast Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 04/27] RDMA/netlink: Rename and remove redundant parameter from ibnl_multicast Leon Romanovsky
     [not found] ` <20170703062830.30361-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2017-07-03  6:28   ` [PATCH rdma-next V2 01/27] RDMA/netlink: Add flag to consolidate common handing Leon Romanovsky
2017-07-03  6:28   ` [PATCH rdma-next V2 05/27] RDMA/netlink: Simplify and rename ibnl_chk_listeners Leon Romanovsky
2017-07-03  6:28   ` [PATCH rdma-next V2 12/27] RDMA/netlink: Update copyright Leon Romanovsky
2017-07-03  6:28   ` [PATCH rdma-next V2 13/27] RDMA/netlink: Add netlink device definitions to UAPI Leon Romanovsky
2017-07-03  6:28   ` [PATCH rdma-next V2 14/27] RDMA/netlink: Add nldev initialization flows Leon Romanovsky
2017-07-03  6:28   ` [PATCH rdma-next V2 15/27] RDMA/netlink: Implement nldev device dumpit calback Leon Romanovsky
2017-07-03  6:28   ` [PATCH rdma-next V2 19/27] RDMA/netlink: Expose device and port capability masks Leon Romanovsky
2017-07-03  6:28   ` [PATCH rdma-next V2 23/27] RDMA/netlink: Advertise IB subnet prefix Leon Romanovsky
2017-07-03  6:28   ` [PATCH rdma-next V2 27/27] RDMA/netlink: Export node_type Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 06/27] RDMA/netlink: Rename netlink callback struct Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 07/27] RDMA/core: Add iterator over ib_devices Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 08/27] RDMA/core: Add and expose static device index Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 09/27] RDMA/netlink: Add and implement doit netlink callback Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 10/27] RDMA/netlink: Reduce indirection access to cb_table Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 11/27] RDMA/netlink: Convert LS to doit callback Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 16/27] RDMA/netlink: Add nldev device doit implementation Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 17/27] RDMA/netlink: Add nldev port dumpit implementation Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 18/27] RDMA/netlink: Implement nldev port doit callback Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 20/27] RDMA: Simplify get firmware interface Leon Romanovsky
     [not found]   ` <20170703062830.30361-21-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2017-07-17 14:48     ` Dennis Dalessandro
2017-07-03  6:28 ` [PATCH rdma-next V2 21/27] RDMA/netlink: Export FW version Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 22/27] RDMA/netlink: Export node_guid and sys_image_guid Leon Romanovsky
2017-07-03  6:28 ` [PATCH rdma-next V2 24/27] RDMA/netink: Export lids and sm_lids Leon Romanovsky
     [not found]   ` <20170703062830.30361-25-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2017-07-17 15:12     ` Dennis Dalessandro
2017-07-03  6:28 ` [PATCH rdma-next V2 25/27] RDMA/netlink: Export LID mask counter (LMC) Leon Romanovsky
2017-07-17 15:14   ` Dennis Dalessandro
2017-07-17 18:32     ` Leon Romanovsky [this message]
2017-07-03  6:28 ` [PATCH rdma-next V2 26/27] RDMA/netlink: Provide port state and physical link state 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=20170717183258.GI3259@mtr-leonro.local \
    --to=leon@kernel$(echo .)org \
    --cc=ariela@mellanox$(echo .)com \
    --cc=dennis.dalessandro@intel$(echo .)com \
    --cc=dledford@redhat$(echo .)com \
    --cc=linux-rdma@vger$(echo .)kernel.org \
    --cc=netdev@vger$(echo .)kernel.org \
    --cc=stephen@networkplumber$(echo .)org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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