Lines Matching refs:ecmd
121 struct ethtool_cmd *ecmd) in e1000_get_settings() argument
128 ecmd->supported = (SUPPORTED_10baseT_Half | in e1000_get_settings()
136 ecmd->supported &= ~SUPPORTED_1000baseT_Full; in e1000_get_settings()
137 ecmd->advertising = ADVERTISED_TP; in e1000_get_settings()
140 ecmd->advertising |= ADVERTISED_Autoneg; in e1000_get_settings()
142 ecmd->advertising |= hw->phy.autoneg_advertised; in e1000_get_settings()
145 ecmd->port = PORT_TP; in e1000_get_settings()
146 ecmd->phy_address = hw->phy.addr; in e1000_get_settings()
147 ecmd->transceiver = XCVR_INTERNAL; in e1000_get_settings()
150 ecmd->supported = (SUPPORTED_1000baseT_Full | in e1000_get_settings()
154 ecmd->advertising = (ADVERTISED_1000baseT_Full | in e1000_get_settings()
158 ecmd->port = PORT_FIBRE; in e1000_get_settings()
159 ecmd->transceiver = XCVR_EXTERNAL; in e1000_get_settings()
163 ecmd->duplex = DUPLEX_UNKNOWN; in e1000_get_settings()
168 ecmd->duplex = adapter->link_duplex - 1; in e1000_get_settings()
182 ecmd->duplex = DUPLEX_FULL; in e1000_get_settings()
184 ecmd->duplex = DUPLEX_HALF; in e1000_get_settings()
188 ethtool_cmd_speed_set(ecmd, speed); in e1000_get_settings()
189 ecmd->autoneg = ((hw->phy.media_type == e1000_media_type_fiber) || in e1000_get_settings()
195 ecmd->eth_tp_mdix = hw->phy.is_mdix ? ETH_TP_MDI_X : ETH_TP_MDI; in e1000_get_settings()
197 ecmd->eth_tp_mdix = ETH_TP_MDI_INVALID; in e1000_get_settings()
200 ecmd->eth_tp_mdix_ctrl = ETH_TP_MDI_AUTO; in e1000_get_settings()
202 ecmd->eth_tp_mdix_ctrl = hw->phy.mdix; in e1000_get_settings()
258 struct ethtool_cmd *ecmd) in e1000_set_settings() argument
280 if (ecmd->eth_tp_mdix_ctrl) { in e1000_set_settings()
286 if ((ecmd->eth_tp_mdix_ctrl != ETH_TP_MDI_AUTO) && in e1000_set_settings()
287 (ecmd->autoneg != AUTONEG_ENABLE)) { in e1000_set_settings()
297 if (ecmd->autoneg == AUTONEG_ENABLE) { in e1000_set_settings()
303 hw->phy.autoneg_advertised = ecmd->advertising | in e1000_set_settings()
305 ecmd->advertising = hw->phy.autoneg_advertised; in e1000_set_settings()
309 u32 speed = ethtool_cmd_speed(ecmd); in e1000_set_settings()
311 if (e1000_set_spd_dplx(adapter, speed, ecmd->duplex)) { in e1000_set_settings()
318 if (ecmd->eth_tp_mdix_ctrl) { in e1000_set_settings()
322 if (ecmd->eth_tp_mdix_ctrl == ETH_TP_MDI_AUTO) in e1000_set_settings()
325 hw->phy.mdix = ecmd->eth_tp_mdix_ctrl; in e1000_set_settings()