* [PATCH iproute2 v2] bridge link: add support to specify master
@ 2015-02-26 8:12 roopa
2015-02-28 2:58 ` Stephen Hemminger
0 siblings, 1 reply; 2+ messages in thread
From: roopa @ 2015-02-26 8:12 UTC (permalink / raw)
To: netdev, stephen, vyasevic; +Cc: davem, sfeldma
From: Roopa Prabhu <roopa@cumulusnetworks.com>
This patch adds support to specify 'master' keyword,
to target a bridge link command explicitly to the software
bridge driver.
Adds self/master keywords to usage and man page
v2:
fix usage to say (self and master) and not (self or master)
Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com>
---
bridge/link.c | 5 ++++-
man/man8/bridge.8 | 12 +++++++++++-
2 files changed, 15 insertions(+), 2 deletions(-)
diff --git a/bridge/link.c b/bridge/link.c
index c8555f8..33dbca4 100644
--- a/bridge/link.c
+++ b/bridge/link.c
@@ -227,6 +227,7 @@ static void usage(void)
fprintf(stderr, " [ learning_sync {on | off} ]\n");
fprintf(stderr, " [ flood {on | off} ]\n");
fprintf(stderr, " [ hwmode {vepa | veb} ]\n");
+ fprintf(stderr, " [ self ] [ master ]\n");
fprintf(stderr, " bridge link show [dev DEV]\n");
exit(-1);
}
@@ -331,7 +332,9 @@ static int brlink_modify(int argc, char **argv)
exit(-1);
}
} else if (strcmp(*argv, "self") == 0) {
- flags = BRIDGE_FLAGS_SELF;
+ flags |= BRIDGE_FLAGS_SELF;
+ } else if (strcmp(*argv, "master") == 0) {
+ flags |= BRIDGE_FLAGS_MASTER;
} else {
usage();
}
diff --git a/man/man8/bridge.8 b/man/man8/bridge.8
index e344db2..19d925f 100644
--- a/man/man8/bridge.8
+++ b/man/man8/bridge.8
@@ -40,7 +40,8 @@ bridge \- show / manipulate bridge addresses and devices
.BR learning " { " on " | " off " } ] [ "
.BR learning_sync " { " on " | " off " } ] [ "
.BR flood " { " on " | " off " } ] [ "
-.BR hwmode " { " vepa " | " veb " } ] "
+.BR hwmode " { " vepa " | " veb " } ] [ "
+.BR self " ] [ " master " ] "
.ti -8
.BR "bridge link" " [ " show " ] [ "
@@ -284,6 +285,15 @@ switch.
.B veb
- bridging happens in hardware.
+.TP
+.BI self
+link setting is configured on specified physical device
+
+.TP
+.BI master
+link setting is configured on the software bridge (default)
+
+
.SS bridge link show - list bridge port configuration.
This command displays the current bridge port configuration and flags.
--
1.7.10.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH iproute2 v2] bridge link: add support to specify master
2015-02-26 8:12 [PATCH iproute2 v2] bridge link: add support to specify master roopa
@ 2015-02-28 2:58 ` Stephen Hemminger
0 siblings, 0 replies; 2+ messages in thread
From: Stephen Hemminger @ 2015-02-28 2:58 UTC (permalink / raw)
To: roopa; +Cc: netdev, vyasevic, davem, sfeldma
On Thu, 26 Feb 2015 00:12:59 -0800
roopa@cumulusnetworks.com wrote:
> From: Roopa Prabhu <roopa@cumulusnetworks.com>
>
> This patch adds support to specify 'master' keyword,
> to target a bridge link command explicitly to the software
> bridge driver.
>
> Adds self/master keywords to usage and man page
>
> v2:
> fix usage to say (self and master) and not (self or master)
>
> Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Applied
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-02-28 2:58 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-26 8:12 [PATCH iproute2 v2] bridge link: add support to specify master roopa
2015-02-28 2:58 ` Stephen Hemminger
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).