Lines Matching refs:mac

50 	struct e1000_mac_info *mac = &hw->mac;
54 mac->ops.init_params = e1000_null_ops_generic;
55 mac->ops.init_hw = e1000_null_ops_generic;
56 mac->ops.reset_hw = e1000_null_ops_generic;
57 mac->ops.setup_physical_interface = e1000_null_ops_generic;
58 mac->ops.get_bus_info = e1000_null_ops_generic;
59 mac->ops.set_lan_id = e1000_set_lan_id_multi_port_pcie;
60 mac->ops.read_mac_addr = e1000_read_mac_addr_generic;
61 mac->ops.config_collision_dist = e1000_config_collision_dist_generic;
62 mac->ops.clear_hw_cntrs = e1000_null_mac_generic;
64 mac->ops.cleanup_led = e1000_null_ops_generic;
65 mac->ops.setup_led = e1000_null_ops_generic;
66 mac->ops.blink_led = e1000_null_ops_generic;
67 mac->ops.led_on = e1000_null_ops_generic;
68 mac->ops.led_off = e1000_null_ops_generic;
70 mac->ops.setup_link = e1000_null_ops_generic;
71 mac->ops.get_link_up_info = e1000_null_link_info;
72 mac->ops.check_for_link = e1000_null_ops_generic;
73 mac->ops.set_obff_timer = e1000_null_set_obff_timer;
75 mac->ops.check_mng_mode = e1000_null_mng_mode;
77 mac->ops.update_mc_addr_list = e1000_null_update_mc;
78 mac->ops.clear_vfta = e1000_null_mac_generic;
79 mac->ops.write_vfta = e1000_null_write_vfta;
80 mac->ops.rar_set = e1000_rar_set_generic;
81 mac->ops.validate_mdi_setting = e1000_validate_mdi_setting_generic;
179 struct e1000_mac_info *mac = &hw->mac;
219 mac->ops.set_lan_id(hw);
234 struct e1000_mac_info *mac = &hw->mac;
265 mac->ops.set_lan_id(hw);
380 hw->mac.ops.rar_set(hw, hw->mac.addr, 0);
385 hw->mac.ops.rar_set(hw, mac_addr, i);
414 if ((hw->mac.type < e1000_82571) || (hw->mac.type == e1000_82573))
420 if (hw->mac.type >= e1000_82580)
464 hw->mac.ops.rar_set(hw, alt_mac_addr, 0);
524 hash_mask = (hw->mac.mta_reg_count * 32) - 1;
557 switch (hw->mac.mc_filter_type) {
596 memset(&hw->mac.mta_shadow, 0, sizeof(hw->mac.mta_shadow));
602 hash_reg = (hash_value >> 5) & (hw->mac.mta_reg_count - 1);
605 hw->mac.mta_shadow[hash_reg] |= (1 << hash_bit);
610 for (i = hw->mac.mta_reg_count - 1; i >= 0; i--)
611 E1000_WRITE_REG_ARRAY(hw, E1000_MTA, i, hw->mac.mta_shadow[i]);
711 struct e1000_mac_info *mac = &hw->mac;
722 if (!mac->get_link_status)
736 mac->get_link_status = FALSE;
746 if (!mac->autoneg)
753 mac->ops.config_collision_dist(hw);
776 struct e1000_mac_info *mac = &hw->mac;
798 if (!mac->autoneg_failed) {
799 mac->autoneg_failed = TRUE;
805 E1000_WRITE_REG(hw, E1000_TXCW, (mac->txcw & ~E1000_TXCW_ANE));
825 E1000_WRITE_REG(hw, E1000_TXCW, mac->txcw);
828 mac->serdes_has_link = TRUE;
843 struct e1000_mac_info *mac = &hw->mac;
863 if (!mac->autoneg_failed) {
864 mac->autoneg_failed = TRUE;
870 E1000_WRITE_REG(hw, E1000_TXCW, (mac->txcw & ~E1000_TXCW_ANE));
890 E1000_WRITE_REG(hw, E1000_TXCW, mac->txcw);
893 mac->serdes_has_link = TRUE;
904 mac->serdes_has_link = TRUE;
908 mac->serdes_has_link = FALSE;
921 mac->serdes_has_link = TRUE;
924 mac->serdes_has_link = FALSE;
928 mac->serdes_has_link = FALSE;
932 mac->serdes_has_link = FALSE;
963 if (hw->mac.type == e1000_i350) {
1032 ret_val = hw->mac.ops.setup_physical_interface(hw);
1060 struct e1000_mac_info *mac = &hw->mac;
1115 mac->txcw = txcw;
1129 struct e1000_mac_info *mac = &hw->mac;
1149 mac->autoneg_failed = TRUE;
1151 * mac->check_for_link. This routine will force the
1155 ret_val = mac->ops.check_for_link(hw);
1160 mac->autoneg_failed = FALSE;
1162 mac->autoneg_failed = FALSE;
1188 hw->mac.ops.config_collision_dist(hw);
1353 struct e1000_mac_info *mac = &hw->mac;
1365 if (mac->autoneg_failed) {
1384 if ((hw->phy.media_type == e1000_media_type_copper) && mac->autoneg) {
1504 ret_val = mac->ops.get_link_up_info(hw, &speed, &duplex);
1529 mac->autoneg) {
1839 struct e1000_mac_info *mac = &hw->mac;
1853 mac->ledctl_default = E1000_READ_REG(hw, E1000_LEDCTL);
1854 mac->ledctl_mode1 = mac->ledctl_default;
1855 mac->ledctl_mode2 = mac->ledctl_default;
1863 mac->ledctl_mode1 &= ~(ledctl_mask << (i << 3));
1864 mac->ledctl_mode1 |= ledctl_on << (i << 3);
1869 mac->ledctl_mode1 &= ~(ledctl_mask << (i << 3));
1870 mac->ledctl_mode1 |= ledctl_off << (i << 3);
1880 mac->ledctl_mode2 &= ~(ledctl_mask << (i << 3));
1881 mac->ledctl_mode2 |= ledctl_on << (i << 3);
1886 mac->ledctl_mode2 &= ~(ledctl_mask << (i << 3));
1887 mac->ledctl_mode2 |= ledctl_off << (i << 3);
1911 if (hw->mac.ops.setup_led != e1000_setup_led_generic)
1916 hw->mac.ledctl_default = ledctl;
1924 E1000_WRITE_REG(hw, E1000_LEDCTL, hw->mac.ledctl_mode1);
1941 E1000_WRITE_REG(hw, E1000_LEDCTL, hw->mac.ledctl_default);
1969 ledctl_blink = hw->mac.ledctl_mode2;
1971 u32 mode = (hw->mac.ledctl_mode2 >> i) &
1973 u32 led_default = hw->mac.ledctl_default >> i;
2012 E1000_WRITE_REG(hw, E1000_LEDCTL, hw->mac.ledctl_mode2);
2041 E1000_WRITE_REG(hw, E1000_LEDCTL, hw->mac.ledctl_mode1);
2124 struct e1000_mac_info *mac = &hw->mac;
2128 if (!mac->adaptive_ifs) {
2133 mac->current_ifs_val = 0;
2134 mac->ifs_min_val = IFS_MIN;
2135 mac->ifs_max_val = IFS_MAX;
2136 mac->ifs_step_size = IFS_STEP;
2137 mac->ifs_ratio = IFS_RATIO;
2139 mac->in_ifs_mode = FALSE;
2152 struct e1000_mac_info *mac = &hw->mac;
2156 if (!mac->adaptive_ifs) {
2161 if ((mac->collision_delta * mac->ifs_ratio) > mac->tx_packet_delta) {
2162 if (mac->tx_packet_delta > MIN_NUM_XMITS) {
2163 mac->in_ifs_mode = TRUE;
2164 if (mac->current_ifs_val < mac->ifs_max_val) {
2165 if (!mac->current_ifs_val)
2166 mac->current_ifs_val = mac->ifs_min_val;
2168 mac->current_ifs_val +=
2169 mac->ifs_step_size;
2171 mac->current_ifs_val);
2175 if (mac->in_ifs_mode &&
2176 (mac->tx_packet_delta <= MIN_NUM_XMITS)) {
2177 mac->current_ifs_val = 0;
2178 mac->in_ifs_mode = FALSE;
2195 if (!hw->mac.autoneg && (hw->phy.mdix == 0 || hw->phy.mdix == 3)) {