7 .Nd configure a built-in Ethernet switch
10 .Op Fl "f control file"
13 .Op Fl "f control file"
15 .Ar phy.register[=value]
17 .Op Fl "f control file"
21 .Op Fl "f control file"
25 .Op Fl "f control file"
31 utility is used to configure an Ethernet switch built into the system.
33 accepts a number of options:
34 .Bl -tag -width ".Fl f" -compact
35 .It Fl "f control file"
38 control file that represents the switch to be configured.
40 .Li /dev/etherswitch0 .
42 When reporting port information, also list available media options for
45 Produce more verbose output.
46 Without this flag, lines that represent inactive or empty configuration
50 The phy command provides access to the registers of the PHYs attached
51 to or integrated into the switch controller.
52 PHY registers are specified as phy.register,
55 is usually the port number, and
57 is the register number.
58 Both can be provided as decimal, octal or hexadecimal numbers in any of the formats
61 To set the register value, use the form instance.register=value.
63 The port command selects one of the ports of the switch.
64 It supports the following commands:
65 .Bl -tag -width ".Ar vlangroup number" -compact
66 .It Ar vlangroup number
67 Sets the VLAN group number that is used to process incoming frames that are not tagged.
68 .It Ar media mediaspec
69 Specifies the physical media configuration to be configured for a port.
70 .It Ar mediaopt mediaoption
71 Specifies a list of media options for a port. See
79 The reg command provides access to the registers of the switch controller.
81 The vlangroup command selects one of the VLAN groups for configuration.
82 It supports the following commands:
83 .Bl -tag -width ".Ar vlangroup" -compact
85 Sets the VLAN ID (802.1q VID) for this VLAN group.
86 Frames transmitted on tagged member ports of this group will be tagged
88 Incoming frames carrying this tag will be forwarded according to the
89 configuration of this VLAN group.
90 .It Ar members port,...
91 Configures which ports are to be a member of this VLAN group.
92 The port numbers are given as a comma-separated list.
93 Each port can optionally be followed by
95 to indicate that frames on this port are tagged.
98 .Bl -tag -width /dev/etherswitch? -compact
99 .It Pa /dev/etherswitch?
100 Control file for the ethernet switch driver.
103 Configure VLAN group 1 with a VID of 2 and makes ports 0 and 5 members,
104 while excluding all other ports.
105 Port 5 will send and receive tagged frames, while port 0 will be untagged.
106 Incoming untagged frames on port 0 are assigned to vlangroup1.
107 .Dl # etherswitchcfg vlangroup1 vlan 2 members 0,5t port0 vlangroup 1