From: Petr Machata <me@pmachata.org>
To: netdev@vger.kernel.org, dsahern@gmail.com, stephen@networkplumber.org
Cc: Petr Machata <me@pmachata.org>
Subject: [PATCH iproute2 3/3] dcb: Change --Netns/-N to --netns/-n
Date: Sat, 2 Jan 2021 00:25:52 +0100 [thread overview]
Message-ID: <5288d48567203a91e26df6ea94b59d1eb253c222.1609543363.git.me@pmachata.org> (raw)
In-Reply-To: <cover.1609543363.git.me@pmachata.org>
This to keep compatible with the major tools, ip and tc. Also
document the option in the man page, which was neglected.
Signed-off-by: Petr Machata <me@pmachata.org>
---
dcb/dcb.c | 8 ++++----
man/man8/dcb.8 | 7 +++++++
2 files changed, 11 insertions(+), 4 deletions(-)
diff --git a/dcb/dcb.c b/dcb/dcb.c
index 0e3c87484f2a..6640deef5688 100644
--- a/dcb/dcb.c
+++ b/dcb/dcb.c
@@ -332,7 +332,7 @@ static void dcb_help(void)
{
fprintf(stderr,
"Usage: dcb [ OPTIONS ] OBJECT { COMMAND | help }\n"
- " dcb [ -f | --force ] { -b | --batch } filename [ -N | --Netns ] netnsname\n"
+ " dcb [ -f | --force ] { -b | --batch } filename [ -n | --netns ] netnsname\n"
"where OBJECT := { buffer | ets | maxrate | pfc }\n"
" OPTIONS := [ -V | --Version | -i | --iec | -j | --json\n"
" | -p | --pretty | -s | --statistics | -v | --verbose]\n");
@@ -379,7 +379,7 @@ int main(int argc, char **argv)
{ "json", no_argument, NULL, 'j' },
{ "pretty", no_argument, NULL, 'p' },
{ "statistics", no_argument, NULL, 's' },
- { "Netns", required_argument, NULL, 'N' },
+ { "netns", required_argument, NULL, 'n' },
{ "help", no_argument, NULL, 'h' },
{ NULL, 0, NULL, 0 }
};
@@ -396,7 +396,7 @@ int main(int argc, char **argv)
return EXIT_FAILURE;
}
- while ((opt = getopt_long(argc, argv, "b:fhijpsvN:V",
+ while ((opt = getopt_long(argc, argv, "b:fhijn:psvV",
long_options, NULL)) >= 0) {
switch (opt) {
@@ -419,7 +419,7 @@ int main(int argc, char **argv)
case 's':
dcb->stats = true;
break;
- case 'N':
+ case 'n':
if (netns_switch(optarg)) {
ret = EXIT_FAILURE;
goto dcb_free;
diff --git a/man/man8/dcb.8 b/man/man8/dcb.8
index 5964f25d386d..7293bb303577 100644
--- a/man/man8/dcb.8
+++ b/man/man8/dcb.8
@@ -27,6 +27,13 @@ dcb \- show / manipulate DCB (Data Center Bridging) settings
.SH OPTIONS
+.TP
+.BR "\-n" , " \--netns " <NETNS>
+switches
+.B dcb
+to the specified network namespace
+.IR NETNS .
+
.TP
.BR "\-V" , " --Version"
Print the version of the
--
2.26.2
prev parent reply other threads:[~2021-01-01 23:28 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-01-01 23:25 [PATCH iproute2 0/3] dcb: Fixes Petr Machata
2021-01-01 23:25 ` [PATCH iproute2 1/3] dcb: Set values with RTM_SETDCB type Petr Machata
2021-01-02 17:34 ` Stephen Hemminger
2021-01-03 10:47 ` Petr Machata
2021-01-03 18:22 ` Stephen Hemminger
2021-01-01 23:25 ` [PATCH iproute2 2/3] dcb: Plug a leaking DCB socket buffer Petr Machata
2021-01-01 23:25 ` Petr Machata [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=5288d48567203a91e26df6ea94b59d1eb253c222.1609543363.git.me@pmachata.org \
--to=me@pmachata.org \
--cc=dsahern@gmail.com \
--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 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).