All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jiri Pirko <jiri@resnulli.us>
To: Leon Romanovsky <leon@kernel.org>
Cc: Stephen Hemminger <stephen@networkplumber.org>,
	Daniel Borkmann <daniel@iogearbox.net>,
	netdev@vger.kernel.org
Subject: Re: [RFC] iproute: Add support for extended ack to rtnl_talk
Date: Sat, 6 May 2017 12:36:04 +0200	[thread overview]
Message-ID: <20170506103604.GA2017@nanopsycho> (raw)
In-Reply-To: <20170504175556.GZ22833@mtr-leonro.local>

Thu, May 04, 2017 at 07:55:56PM CEST, leon@kernel.org wrote:
>On Thu, May 04, 2017 at 09:45:58AM -0700, Stephen Hemminger wrote:
>> On Thu, 4 May 2017 17:37:38 +0300
>> Leon Romanovsky <leon@kernel.org> wrote:
>>
>> > On Thu, May 04, 2017 at 11:36:36AM +0200, Daniel Borkmann wrote:
>> > > On 05/04/2017 01:56 AM, Stephen Hemminger wrote:
>> > > > Add support for extended ack error reporting via libmnl. This
>> > > > is a better alternative to use existing library and not copy/paste
>> > > > code from the kernel. Also make arguments const where possible.
>> > > >
>> > > > Add a new function rtnl_talk_extack that takes a callback as an input
>> > > > arg. If a netlink response contains extack attributes, the callback is
>> > > > is invoked with the the err string, offset in the message and a pointer
>> > > > to the message returned by the kernel.
>> > > >
>> > > > Adding a new function allows commands to be moved over to the
>> > > > extended error reporting over time.
>> > > >
>> > > > For feedback, compile tested only.
>> > >
>> > > Just out of curiosity, what is the plan regarding converting iproute2
>> > > over to libmnl (ip, tc, ss, ...)? In 2015, tipc tool was the first
>> > > user merged that requires libmnl, the only other user today in the
>> > > tree is devlink, which even seems to define its own libmnl library
>> > > helpers. What is the clear benefit/rationale of outsourcing this to
>> > > libmnl? I always was the impression we should strive for as little
>> > > dependencies as possible?
>> >
>> > And I would like to get direction for the RDMA tool [1] which I'm
>> > working on it now.
>> >
>> > The overall decision was to use netlink and put it under iproute2
>> > umbrella. Currently, I have working RFC which is based on
>> > legacy sysfs interface to ensure that we are converging on
>> > user-experience even before moving to actual netlink defines.
>> >
>> > An I would like to continue to work on netlink interface, but which lib interface
>> > should I need to base rdmatool's netlink code?
>> >
>> > [1] https://www.mail-archive.com/netdev@vger.kernel.org/msg148523.html
>> >
>> > >
>> > > I don't really like that we make extended ack reporting now dependent
>> > > on libmnl, which further diverts from iproute's native nl library vs
>> > > requiring to install another nl library, making the current status
>> > > quo even worse ... :/
>> > >
>> > > Thanks,
>> > > Daniel
>>
>> I would prefer new code use libmnl, but using libnetlink would also be ok.
>> Any later conversion to libmnl would be mostly automated anyway.
>
>Thanks, I'm copy/pasting devlink variation of libmnl :)

I needed couple of small helpers for generic netlink support. I believe
they could be pushed to upstream libmnl so we can avoid having them in
iproute2


>
>>
>> The real objection was copy/pasting in the kernel netlink parser.
>> That was unnecessary bloat.
>
>

  reply	other threads:[~2017-05-06 10:36 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-03 23:56 [RFC] iproute: Add support for extended ack to rtnl_talk Stephen Hemminger
2017-05-04  9:36 ` Daniel Borkmann
2017-05-04 14:27   ` David Ahern
2017-05-04 14:41     ` David Miller
2017-05-04 15:50       ` Jamal Hadi Salim
2017-05-04 16:43       ` Stephen Hemminger
2017-05-04 20:43         ` Phil Sutter
2017-05-14  1:29           ` David Ahern
2017-05-16 16:36             ` Stephen Hemminger
2017-05-18 10:02               ` Daniel Borkmann
2017-05-18 14:55                 ` Stephen Hemminger
2017-05-19  4:24                 ` David Ahern
2017-08-03 20:26                   ` David Ahern
2017-08-04 11:31                     ` Simon Horman
2017-08-04 16:47                       ` Stephen Hemminger
2017-08-07 16:48                         ` David Ahern
2017-08-07 18:06                           ` Stephen Hemminger
2017-08-07 18:09                             ` David Ahern
2017-08-07 18:45                               ` David Miller
2017-08-07 19:12                                 ` Stephen Hemminger
2017-08-07 20:26                                   ` David Miller
2017-08-07 21:21                                     ` Stephen Hemminger
2017-05-04 14:37   ` Leon Romanovsky
2017-05-04 16:45     ` Stephen Hemminger
2017-05-04 17:55       ` Leon Romanovsky
2017-05-06 10:36         ` Jiri Pirko [this message]
2017-05-04 16:42   ` Stephen Hemminger

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=20170506103604.GA2017@nanopsycho \
    --to=jiri@resnulli.us \
    --cc=daniel@iogearbox.net \
    --cc=leon@kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=stephen@networkplumber.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.