summaryrefslogtreecommitdiffstats
path: root/sbin/etherswitchcfg/etherswitchcfg.8
diff options
context:
space:
mode:
Diffstat (limited to 'sbin/etherswitchcfg/etherswitchcfg.8')
-rw-r--r--sbin/etherswitchcfg/etherswitchcfg.859
1 files changed, 52 insertions, 7 deletions
diff --git a/sbin/etherswitchcfg/etherswitchcfg.8 b/sbin/etherswitchcfg/etherswitchcfg.8
index 4f3bc92..a8b8d1a 100644
--- a/sbin/etherswitchcfg/etherswitchcfg.8
+++ b/sbin/etherswitchcfg/etherswitchcfg.8
@@ -11,12 +11,16 @@
.Ar info
.Nm
.Op Fl "f control file"
+.Ar config
+.Ar command parameter
+.Nm
+.Op Fl "f control file"
.Ar phy
.Ar phy.register[=value]
.Nm
.Op Fl "f control file"
.Ar port%d
-.Ar command parameter
+.Ar [flags] command parameter
.Nm
.Op Fl "f control file"
.Ar reg
@@ -46,6 +50,14 @@ Produce more verbose output.
Without this flag, lines that represent inactive or empty configuration
options are omitted.
.El
+.Ss config
+The config command provides access to global switch configuration
+parameters.
+It support the following commands:
+.Bl -tag -width ".Ar vlan_mode mode" -compact
+.It Ar vlan_mode mode
+Sets the switch VLAN mode (depends on the hardware).
+.El
.Ss phy
The phy command provides access to the registers of the PHYs attached
to or integrated into the switch controller.
@@ -57,24 +69,57 @@ is usually the port number, and
is the register number.
Both can be provided as decimal, octal or hexadecimal numbers in any of the formats
understood by
-.Xr strtol 4 .
+.Xr strtol 3 .
To set the register value, use the form instance.register=value.
.Ss port
The port command selects one of the ports of the switch.
It supports the following commands:
-.Bl -tag -width ".Ar vlangroup number" -compact
-.It Ar vlangroup number
-Sets the VLAN group number that is used to process incoming frames that are not tagged.
+.Bl -tag -width ".Ar pvid number" -compact
+.It Ar pvid number
+Sets the default port VID that is used to process incoming frames that are not tagged.
.It Ar media mediaspec
Specifies the physical media configuration to be configured for a port.
.It Ar mediaopt mediaoption
-Specifies a list of media options for a port. See
+Specifies a list of media options for a port.
+See
.Xr ifconfig 8
for details on
.Ar media
and
.Ar mediaopt .
.El
+And the following flags (please note that not all flags
+are supporterd by all switch drivers):
+.Bl -tag -width ".Ar addtag" -compact
+.It Ar addtag
+Add VLAN tag to each packet sent by the port.
+.It Ar -addtag
+Disable the add VLAN tag option.
+.It Ar striptag
+Strip the VLAN tags from the packets sent by the port.
+.It Ar -striptag
+Disable the strip VLAN tag option.
+.It Ar firstlock
+This options makes the switch port lock on the first MAC address it seems.
+After that, usually you need to reset the switch to learn different
+MAC addresses.
+.It Ar -firstlock
+Disable the first lock option.
+Note that sometimes you need to reset the
+switch to really disable this option.
+.It Ar dropuntagged
+Drop packets without a VLAN tag.
+.It Ar -dropuntagged
+Disable the drop untagged packets option.
+.It Ar doubletag
+Enable QinQ for the port.
+.It Ar -doubletag
+Disable QinQ for the port.
+.It Ar ingress
+Enable the ingress filter on the port.
+.It Ar -ingress
+Disable the ingress filter.
+.El
.Ss reg
The reg command provides access to the registers of the switch controller.
.Ss vlangroup
@@ -104,7 +149,7 @@ Configure VLAN group 1 with a VID of 2 and makes ports 0 and 5 members,
while excluding all other ports.
Port 5 will send and receive tagged frames, while port 0 will be untagged.
Incoming untagged frames on port 0 are assigned to vlangroup1.
-.Dl # etherswitchcfg vlangroup1 vlan 2 members 0,5t port0 vlangroup 1
+.Dl # etherswitchcfg vlangroup1 vlan 2 members 0,5t port0 pvid 2
.Sh SEE ALSO
.Xr etherswitch 4
.Sh HISTORY
OpenPOWER on IntegriCloud