Lines Matching refs:mac

41 	struct e1000_mac_info *mac = &hw->mac;  in e1000e_get_bus_info_pcie()  local
58 mac->ops.set_lan_id(hw); in e1000e_get_bus_info_pcie()
146 e1000e_rar_set(hw, hw->mac.addr, 0); in e1000e_init_rx_addrs()
178 if (hw->mac.type == e1000_82573) in e1000_check_alt_mac_addr_generic()
274 hash_mask = (hw->mac.mta_reg_count * 32) - 1; in e1000_hash_mc_addr()
309 switch (hw->mac.mc_filter_type) { in e1000_hash_mc_addr()
346 memset(&hw->mac.mta_shadow, 0, sizeof(hw->mac.mta_shadow)); in e1000e_update_mc_addr_list_generic()
352 hash_reg = (hash_value >> 5) & (hw->mac.mta_reg_count - 1); in e1000e_update_mc_addr_list_generic()
355 hw->mac.mta_shadow[hash_reg] |= (1 << hash_bit); in e1000e_update_mc_addr_list_generic()
360 for (i = hw->mac.mta_reg_count - 1; i >= 0; i--) in e1000e_update_mc_addr_list_generic()
361 E1000_WRITE_REG_ARRAY(hw, E1000_MTA, i, hw->mac.mta_shadow[i]); in e1000e_update_mc_addr_list_generic()
422 struct e1000_mac_info *mac = &hw->mac; in e1000e_check_for_copper_link() local
432 if (!mac->get_link_status) in e1000e_check_for_copper_link()
447 mac->get_link_status = false; in e1000e_check_for_copper_link()
459 if (!mac->autoneg) in e1000e_check_for_copper_link()
467 mac->ops.config_collision_dist(hw); in e1000e_check_for_copper_link()
491 struct e1000_mac_info *mac = &hw->mac; in e1000e_check_for_fiber_link() local
512 if (!mac->autoneg_failed) { in e1000e_check_for_fiber_link()
513 mac->autoneg_failed = true; in e1000e_check_for_fiber_link()
519 ew32(TXCW, (mac->txcw & ~E1000_TXCW_ANE)); in e1000e_check_for_fiber_link()
540 ew32(TXCW, mac->txcw); in e1000e_check_for_fiber_link()
543 mac->serdes_has_link = true; in e1000e_check_for_fiber_link()
558 struct e1000_mac_info *mac = &hw->mac; in e1000e_check_for_serdes_link() local
577 if (!mac->autoneg_failed) { in e1000e_check_for_serdes_link()
578 mac->autoneg_failed = true; in e1000e_check_for_serdes_link()
584 ew32(TXCW, (mac->txcw & ~E1000_TXCW_ANE)); in e1000e_check_for_serdes_link()
605 ew32(TXCW, mac->txcw); in e1000e_check_for_serdes_link()
608 mac->serdes_has_link = true; in e1000e_check_for_serdes_link()
620 mac->serdes_has_link = true; in e1000e_check_for_serdes_link()
624 mac->serdes_has_link = false; in e1000e_check_for_serdes_link()
637 mac->serdes_has_link = true; in e1000e_check_for_serdes_link()
640 mac->serdes_has_link = false; in e1000e_check_for_serdes_link()
644 mac->serdes_has_link = false; in e1000e_check_for_serdes_link()
648 mac->serdes_has_link = false; in e1000e_check_for_serdes_link()
734 ret_val = hw->mac.ops.setup_physical_interface(hw); in e1000e_setup_link_generic()
763 struct e1000_mac_info *mac = &hw->mac; in e1000_commit_fc_settings_generic() local
820 mac->txcw = txcw; in e1000_commit_fc_settings_generic()
834 struct e1000_mac_info *mac = &hw->mac; in e1000_poll_fiber_serdes_link_generic() local
853 mac->autoneg_failed = true; in e1000_poll_fiber_serdes_link_generic()
860 ret_val = mac->ops.check_for_link(hw); in e1000_poll_fiber_serdes_link_generic()
865 mac->autoneg_failed = false; in e1000_poll_fiber_serdes_link_generic()
867 mac->autoneg_failed = false; in e1000_poll_fiber_serdes_link_generic()
891 hw->mac.ops.config_collision_dist(hw); in e1000e_setup_fiber_serdes_link()
1055 struct e1000_mac_info *mac = &hw->mac; in e1000e_config_fc_after_link_up() local
1065 if (mac->autoneg_failed) { in e1000e_config_fc_after_link_up()
1085 if ((hw->phy.media_type == e1000_media_type_copper) && mac->autoneg) { in e1000e_config_fc_after_link_up()
1212 ret_val = mac->ops.get_link_up_info(hw, &speed, &duplex); in e1000e_config_fc_after_link_up()
1407 struct e1000_mac_info *mac = &hw->mac; in e1000e_id_led_init_generic() local
1419 mac->ledctl_default = er32(LEDCTL); in e1000e_id_led_init_generic()
1420 mac->ledctl_mode1 = mac->ledctl_default; in e1000e_id_led_init_generic()
1421 mac->ledctl_mode2 = mac->ledctl_default; in e1000e_id_led_init_generic()
1429 mac->ledctl_mode1 &= ~(ledctl_mask << (i << 3)); in e1000e_id_led_init_generic()
1430 mac->ledctl_mode1 |= ledctl_on << (i << 3); in e1000e_id_led_init_generic()
1435 mac->ledctl_mode1 &= ~(ledctl_mask << (i << 3)); in e1000e_id_led_init_generic()
1436 mac->ledctl_mode1 |= ledctl_off << (i << 3); in e1000e_id_led_init_generic()
1446 mac->ledctl_mode2 &= ~(ledctl_mask << (i << 3)); in e1000e_id_led_init_generic()
1447 mac->ledctl_mode2 |= ledctl_on << (i << 3); in e1000e_id_led_init_generic()
1452 mac->ledctl_mode2 &= ~(ledctl_mask << (i << 3)); in e1000e_id_led_init_generic()
1453 mac->ledctl_mode2 |= ledctl_off << (i << 3); in e1000e_id_led_init_generic()
1475 if (hw->mac.ops.setup_led != e1000e_setup_led_generic) in e1000e_setup_led_generic()
1480 hw->mac.ledctl_default = ledctl; in e1000e_setup_led_generic()
1488 ew32(LEDCTL, hw->mac.ledctl_mode1); in e1000e_setup_led_generic()
1503 ew32(LEDCTL, hw->mac.ledctl_default); in e1000e_cleanup_led_generic()
1527 ledctl_blink = hw->mac.ledctl_mode2; in e1000e_blink_led_generic()
1529 if (((hw->mac.ledctl_mode2 >> (i * 8)) & 0xFF) == in e1000e_blink_led_generic()
1558 ew32(LEDCTL, hw->mac.ledctl_mode2); in e1000e_led_on_generic()
1585 ew32(LEDCTL, hw->mac.ledctl_mode1); in e1000e_led_off_generic()
1656 struct e1000_mac_info *mac = &hw->mac; in e1000e_reset_adaptive() local
1658 if (!mac->adaptive_ifs) { in e1000e_reset_adaptive()
1663 mac->current_ifs_val = 0; in e1000e_reset_adaptive()
1664 mac->ifs_min_val = IFS_MIN; in e1000e_reset_adaptive()
1665 mac->ifs_max_val = IFS_MAX; in e1000e_reset_adaptive()
1666 mac->ifs_step_size = IFS_STEP; in e1000e_reset_adaptive()
1667 mac->ifs_ratio = IFS_RATIO; in e1000e_reset_adaptive()
1669 mac->in_ifs_mode = false; in e1000e_reset_adaptive()
1682 struct e1000_mac_info *mac = &hw->mac; in e1000e_update_adaptive() local
1684 if (!mac->adaptive_ifs) { in e1000e_update_adaptive()
1689 if ((mac->collision_delta * mac->ifs_ratio) > mac->tx_packet_delta) { in e1000e_update_adaptive()
1690 if (mac->tx_packet_delta > MIN_NUM_XMITS) { in e1000e_update_adaptive()
1691 mac->in_ifs_mode = true; in e1000e_update_adaptive()
1692 if (mac->current_ifs_val < mac->ifs_max_val) { in e1000e_update_adaptive()
1693 if (!mac->current_ifs_val) in e1000e_update_adaptive()
1694 mac->current_ifs_val = mac->ifs_min_val; in e1000e_update_adaptive()
1696 mac->current_ifs_val += in e1000e_update_adaptive()
1697 mac->ifs_step_size; in e1000e_update_adaptive()
1698 ew32(AIT, mac->current_ifs_val); in e1000e_update_adaptive()
1702 if (mac->in_ifs_mode && in e1000e_update_adaptive()
1703 (mac->tx_packet_delta <= MIN_NUM_XMITS)) { in e1000e_update_adaptive()
1704 mac->current_ifs_val = 0; in e1000e_update_adaptive()
1705 mac->in_ifs_mode = false; in e1000e_update_adaptive()