From: Leon Romanovsky <leon@kernel.org>
To: David Ahern <dsahern@gmail.com>
Cc: Patrisious Haddad <phaddad@nvidia.com>,
Doug Ledford <dledford@redhat.com>,
Jason Gunthorpe <jgg@nvidia.com>,
linux-netdev <netdev@vger.kernel.org>,
RDMA mailing list <linux-rdma@vger.kernel.org>
Subject: Re: [PATCH iproute2-next] rdma: Add support for the netlink extack
Date: Sun, 3 Jan 2021 07:56:50 +0200 [thread overview]
Message-ID: <20210103055650.GA4436@unreal> (raw)
In-Reply-To: <8d59994a-0c08-8c62-d23d-da3f74f57af5@gmail.com>
On Thu, Dec 31, 2020 at 09:18:52AM -0700, David Ahern wrote:
> On 12/30/20 10:42 PM, Leon Romanovsky wrote:
> > diff --git a/rdma/utils.c b/rdma/utils.c
> > index 2a201aa4..927e2107 100644
> > --- a/rdma/utils.c
> > +++ b/rdma/utils.c
> > @@ -664,7 +664,7 @@ void rd_prepare_msg(struct rd *rd, uint32_t cmd, uint32_t *seq, uint16_t flags)
> >
> > int rd_send_msg(struct rd *rd)
> > {
> > - int ret;
> > + int ret, one;
> >
> > rd->nl = mnl_socket_open(NETLINK_RDMA);
> > if (!rd->nl) {
> > @@ -672,6 +672,12 @@ int rd_send_msg(struct rd *rd)
> > return -ENODEV;
> > }
> >
> > + ret = mnl_socket_setsockopt(rd->nl, NETLINK_EXT_ACK, &one, sizeof(one));
> > + if (ret < 0) {
> > + pr_err("Failed to set socket option with err %d\n", ret);
> > + goto err;
> > + }
> > +
> > ret = mnl_socket_bind(rd->nl, 0, MNL_SOCKET_AUTOPID);
> > if (ret < 0) {
> > pr_err("Failed to bind socket with err %d\n", ret);
>
> you should be able to use mnlu_socket_open in ./lib/mnl_utils.c
Thanks, I'll change.
>
prev parent reply other threads:[~2021-01-03 5:57 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-31 5:42 [PATCH iproute2-next] rdma: Add support for the netlink extack Leon Romanovsky
2020-12-31 16:18 ` David Ahern
2021-01-03 5:56 ` Leon Romanovsky [this message]
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=20210103055650.GA4436@unreal \
--to=leon@kernel.org \
--cc=dledford@redhat.com \
--cc=dsahern@gmail.com \
--cc=jgg@nvidia.com \
--cc=linux-rdma@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=phaddad@nvidia.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;
as well as URLs for NNTP newsgroup(s).