aboutsummaryrefslogtreecommitdiffstats
path: root/ip/iplink_vlan.c
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2017-03-28 23:19:38 +0200
committerStephen Hemminger <stephen@networkplumber.org>2017-04-04 14:51:29 -0700
commit8b47135474cde4f0f8c9991741132b930bf3e192 (patch)
treede6881c40af0407941eb5975b57ea53677c12fcb /ip/iplink_vlan.c
parente336868e0925e77fe933d83711941cafa6134e25 (diff)
downloadplatform_external_iproute2-8b47135474cde4f0f8c9991741132b930bf3e192.tar.gz
platform_external_iproute2-8b47135474cde4f0f8c9991741132b930bf3e192.tar.bz2
platform_external_iproute2-8b47135474cde4f0f8c9991741132b930bf3e192.zip
ip: link: Unify link type help functions a bit
Take help function in iplink_bridge.c as an example and make other link types' help functions similar: * Use a single fprintf() call (if possible). * Don't state a full command line, just "... type OPTIONS". * Put every option in it's own line, align options by column. * List mandatory options first. link_veth.c is intentionally left untouched because it's 'peer' option eats all kinds of generic link options and the help text points this out without duplicating all the options there again. Signed-off-by: Phil Sutter <phil@nwl.cc>
Diffstat (limited to 'ip/iplink_vlan.c')
-rw-r--r--ip/iplink_vlan.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/ip/iplink_vlan.c b/ip/iplink_vlan.c
index 144c83cb..b47236d8 100644
--- a/ip/iplink_vlan.c
+++ b/ip/iplink_vlan.c
@@ -21,14 +21,17 @@
static void print_explain(FILE *f)
{
fprintf(f,
- "Usage: ... vlan [ protocol VLANPROTO ] id VLANID [ FLAG-LIST ]\n"
- " [ ingress-qos-map QOS-MAP ] [ egress-qos-map QOS-MAP ]\n"
+ "Usage: ... vlan id VLANID\n"
+ " [ protocol VLANPROTO ]\n"
+ " [ reorder_hdr { on | off } ]\n"
+ " [ gvrp { on | off } ]\n"
+ " [ mvrp { on | off } ]\n"
+ " [ loose_binding { on | off } ]\n"
+ " [ ingress-qos-map QOS-MAP ]\n"
+ " [ egress-qos-map QOS-MAP ]\n"
"\n"
- "VLANPROTO: [ 802.1Q / 802.1ad ]\n"
"VLANID := 0-4095\n"
- "FLAG-LIST := [ FLAG-LIST ] FLAG\n"
- "FLAG := [ reorder_hdr { on | off } ] [ gvrp { on | off } ] [ mvrp { on | off } ]\n"
- " [ loose_binding { on | off } ]\n"
+ "VLANPROTO: [ 802.1Q / 802.1ad ]\n"
"QOS-MAP := [ QOS-MAP ] QOS-MAPPING\n"
"QOS-MAPPING := FROM:TO\n"
);