From: Stephen Hemminger <stephen@networkplumber.org>
To: Martin Varghese <martinvarghesenokia@gmail.com>
Cc: netdev@vger.kernel.org, scott.drennan@nokia.com,
jbenc@redhat.com, martin.varghese@nokia.com
Subject: Re: [PATCH iproute2] Bareudp device support
Date: Tue, 8 Oct 2019 09:00:03 -0700 [thread overview]
Message-ID: <20191008090003.59a347eb@hermes.lan> (raw)
In-Reply-To: <1570532361-15163-1-git-send-email-martinvarghesenokia@gmail.com>
On Tue, 8 Oct 2019 16:29:21 +0530
Martin Varghese <martinvarghesenokia@gmail.com> wrote:
Overall ok, but where is man page?
> +
> + if (tb[IFLA_BAREUDP_PORT])
> + print_uint(PRINT_ANY,
> + "port",
> + "dstport %u ",
> + rta_getattr_be16(tb[IFLA_BAREUDP_PORT]));
nit. these can be combined to be less lines.
> + if (tb[IFLA_BAREUDP_EXTMODE]) {
> + print_bool(PRINT_ANY, "extmode", "extmode ", true);
> + return;
> + }
One of the unwritten rules of ip commands is that the show format
should match the command line arguments. In this case extmode is
really a presence flag not a boolean. best to print that with
json null command.
Also why the short circuit return.
next prev parent reply other threads:[~2019-10-08 16:00 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-10-08 10:59 [PATCH iproute2] Bareudp device support Martin Varghese
2019-10-08 16:00 ` Stephen Hemminger [this message]
2019-10-09 3:19 ` 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=20191008090003.59a347eb@hermes.lan \
--to=stephen@networkplumber.org \
--cc=jbenc@redhat.com \
--cc=martin.varghese@nokia.com \
--cc=martinvarghesenokia@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=scott.drennan@nokia.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).