| |
By default, the bge driver performs auto-negotiation
to select the link speed and mode. Link speed and mode can be any one of the
following, (as described in the IEEE803.2 standards):
- 1000 Mbps, full-duplex
- 1000 Mbps, half-duplex
- 100 Mbps, full-duplex
- 100 Mbps, half-duplex
- 10 Mbps, full-duplex
- 10 Mbps, half-duplex
The auto-negotiation protocol automatically selects:
- Speed (1000 Mbps, 100 Mbps, or 10 Mbps)
- Operation mode (full-duplex or half-duplex)
as the highest common denominator supported by both link partners. Because
the bge device supports all modes, the effect is to select
the highest throughput mode supported by the other device.
Alternatively, you can set the capabilities advertised by the bge device using ndd(1M).
The driver supports a number of parameters whose names begin with adv_ (see below). Each of these parameters contains a boolean value
that determines whether the device advertises that mode of operation. In addition,
the adv_autoneg_cap parameter controls whether autonegotiation
is performed. If adv_autoneg_cap is set to 0, the driver
forces the mode of operation selected by the first non-zero parameter in priority
order as listed below:
| |
(highest priority/greatest throughput)
adv_1000fdx_cap 1000Mbps full duplex
adv_1000hdx_cap 1000Mpbs half duplex
adv_100fdx_cap 100Mpbs full duplex
adv_100hdx_cap 100Mpbs half duplex
adv_10fdx_cap 10Mpbs full duplex
adv_10hdx_cap 10Mpbs half duplex
(lowest priority/least throughput)
|
For example, to prevent the device 'bge2' from advertising gigabit capabilities,
enter (as super-user):
| |
# ndd -set /dev/bge2 adv_1000hdx_cap 0
# ndd -set /dev/bge2 adv_1000fdx_cap 0
|
All capabilities default to enabled. Note that changing any capability
parameter will cause the link to go down while the link partners renegotiate
the link speed/duplex using the newly changed capabilities.
The current settings of the parameters may be found using ndd -get. In addition, the driver exports the current
state, speed, and duplex setting of the link via ndd parameters
(these are read only and may not be changed). For example, to check link
state of device bge0:
| |
# ndd -get /dev/bge0 link_status
1
# ndd -get /dev/bge0 link_speed
100
# ndd -get /dev/bge0 link_duplex
1
|
The output above indicates that the link is up and running at 100Mbps
full-duplex.
|