Lines Matching refs:mac_mode
2007 u32 mac_mode, lcl_adv, rmt_adv; in tg3_adjust_link() local
2013 mac_mode = tp->mac_mode & ~(MAC_MODE_PORT_MODE_MASK | in tg3_adjust_link()
2023 mac_mode |= MAC_MODE_PORT_MODE_MII; in tg3_adjust_link()
2026 mac_mode |= MAC_MODE_PORT_MODE_GMII; in tg3_adjust_link()
2028 mac_mode |= MAC_MODE_PORT_MODE_MII; in tg3_adjust_link()
2031 mac_mode |= MAC_MODE_HALF_DUPLEX; in tg3_adjust_link()
2044 mac_mode |= MAC_MODE_PORT_MODE_GMII; in tg3_adjust_link()
2046 if (mac_mode != tp->mac_mode) { in tg3_adjust_link()
2047 tp->mac_mode = mac_mode; in tg3_adjust_link()
2048 tw32_f(MAC_MODE, tp->mac_mode); in tg3_adjust_link()
4131 u32 mac_mode; in tg3_power_down_prepare() local
4145 mac_mode = MAC_MODE_PORT_MODE_GMII; in tg3_power_down_prepare()
4149 mac_mode = MAC_MODE_PORT_MODE_GMII; in tg3_power_down_prepare()
4151 mac_mode = MAC_MODE_PORT_MODE_MII; in tg3_power_down_prepare()
4153 mac_mode = MAC_MODE_PORT_MODE_MII; in tg3_power_down_prepare()
4155 mac_mode |= tp->mac_mode & MAC_MODE_LINK_POLARITY; in tg3_power_down_prepare()
4160 mac_mode |= MAC_MODE_LINK_POLARITY; in tg3_power_down_prepare()
4162 mac_mode &= ~MAC_MODE_LINK_POLARITY; in tg3_power_down_prepare()
4165 mac_mode = MAC_MODE_PORT_MODE_TBI; in tg3_power_down_prepare()
4171 mac_mode |= MAC_MODE_MAGIC_PKT_ENABLE; in tg3_power_down_prepare()
4174 mac_mode |= MAC_MODE_KEEP_FRAME_IN_WOL; in tg3_power_down_prepare()
4177 mac_mode |= MAC_MODE_APE_TX_EN | in tg3_power_down_prepare()
4181 tw32_f(MAC_MODE, mac_mode); in tg3_power_down_prepare()
4990 (tp->mac_mode & MAC_MODE_PORT_INT_LPBACK)) in tg3_setup_copper_phy()
4994 tp->mac_mode &= ~MAC_MODE_PORT_MODE_MASK; in tg3_setup_copper_phy()
4998 tp->mac_mode |= MAC_MODE_PORT_MODE_MII; in tg3_setup_copper_phy()
5000 tp->mac_mode |= MAC_MODE_PORT_MODE_GMII; in tg3_setup_copper_phy()
5002 tp->mac_mode |= MAC_MODE_PORT_MODE_MII; in tg3_setup_copper_phy()
5004 tp->mac_mode |= MAC_MODE_PORT_MODE_GMII; in tg3_setup_copper_phy()
5026 tp->mac_mode &= ~MAC_MODE_HALF_DUPLEX; in tg3_setup_copper_phy()
5028 tp->mac_mode |= MAC_MODE_HALF_DUPLEX; in tg3_setup_copper_phy()
5033 tp->mac_mode |= MAC_MODE_LINK_POLARITY; in tg3_setup_copper_phy()
5035 tp->mac_mode &= ~MAC_MODE_LINK_POLARITY; in tg3_setup_copper_phy()
5048 tw32_f(MAC_MODE, tp->mac_mode); in tg3_setup_copper_phy()
5235 tp->mac_mode |= MAC_MODE_SEND_CONFIGS; in tg3_fiber_aneg_smachine()
5236 tw32_f(MAC_MODE, tp->mac_mode); in tg3_fiber_aneg_smachine()
5264 tp->mac_mode |= MAC_MODE_SEND_CONFIGS; in tg3_fiber_aneg_smachine()
5265 tw32_f(MAC_MODE, tp->mac_mode); in tg3_fiber_aneg_smachine()
5279 tp->mac_mode |= MAC_MODE_SEND_CONFIGS; in tg3_fiber_aneg_smachine()
5280 tw32_f(MAC_MODE, tp->mac_mode); in tg3_fiber_aneg_smachine()
5365 tp->mac_mode &= ~MAC_MODE_SEND_CONFIGS; in tg3_fiber_aneg_smachine()
5366 tw32_f(MAC_MODE, tp->mac_mode); in tg3_fiber_aneg_smachine()
5417 tmp = tp->mac_mode & ~MAC_MODE_PORT_MODE_MASK; in fiber_autoneg()
5421 tw32_f(MAC_MODE, tp->mac_mode | MAC_MODE_SEND_CONFIGS); in fiber_autoneg()
5437 tp->mac_mode &= ~MAC_MODE_SEND_CONFIGS; in fiber_autoneg()
5438 tw32_f(MAC_MODE, tp->mac_mode); in fiber_autoneg()
5701 tw32_f(MAC_MODE, (tp->mac_mode | MAC_MODE_SEND_CONFIGS)); in tg3_setup_fiber_by_hand()
5704 tw32_f(MAC_MODE, tp->mac_mode); in tg3_setup_fiber_by_hand()
5743 tp->mac_mode &= ~(MAC_MODE_PORT_MODE_MASK | MAC_MODE_HALF_DUPLEX); in tg3_setup_fiber_phy()
5744 tp->mac_mode |= MAC_MODE_PORT_MODE_TBI; in tg3_setup_fiber_phy()
5745 tw32_f(MAC_MODE, tp->mac_mode); in tg3_setup_fiber_phy()
5783 tw32_f(MAC_MODE, (tp->mac_mode | in tg3_setup_fiber_phy()
5786 tw32_f(MAC_MODE, tp->mac_mode); in tg3_setup_fiber_phy()
5832 tp->mac_mode &= ~MAC_MODE_PORT_MODE_MASK; in tg3_setup_fiber_mii_phy()
5835 tp->mac_mode |= MAC_MODE_PORT_MODE_GMII; in tg3_setup_fiber_mii_phy()
5840 tp->mac_mode |= MAC_MODE_PORT_MODE_GMII; in tg3_setup_fiber_mii_phy()
5843 tp->mac_mode |= MAC_MODE_PORT_MODE_MII; in tg3_setup_fiber_mii_phy()
5846 tp->mac_mode |= MAC_MODE_PORT_MODE_MII; in tg3_setup_fiber_mii_phy()
5855 tw32_f(MAC_MODE, tp->mac_mode); in tg3_setup_fiber_mii_phy()
5863 tp->mac_mode |= MAC_MODE_PORT_MODE_GMII; in tg3_setup_fiber_mii_phy()
5864 tw32_f(MAC_MODE, tp->mac_mode); in tg3_setup_fiber_mii_phy()
5993 tp->mac_mode &= ~MAC_MODE_HALF_DUPLEX; in tg3_setup_fiber_mii_phy()
5995 tp->mac_mode |= MAC_MODE_HALF_DUPLEX; in tg3_setup_fiber_mii_phy()
5997 tw32_f(MAC_MODE, tp->mac_mode); in tg3_setup_fiber_mii_phy()
8170 tp->mac_mode &= ~(MAC_MODE_HALF_DUPLEX | in tg3_mac_loopback()
8173 tp->mac_mode |= MAC_MODE_PORT_INT_LPBACK; in tg3_mac_loopback()
8176 tp->mac_mode |= MAC_MODE_LINK_POLARITY; in tg3_mac_loopback()
8179 tp->mac_mode |= MAC_MODE_PORT_MODE_MII; in tg3_mac_loopback()
8181 tp->mac_mode |= MAC_MODE_PORT_MODE_GMII; in tg3_mac_loopback()
8183 tp->mac_mode &= ~MAC_MODE_PORT_INT_LPBACK; in tg3_mac_loopback()
8188 tp->mac_mode &= ~MAC_MODE_LINK_POLARITY; in tg3_mac_loopback()
8191 tw32(MAC_MODE, tp->mac_mode); in tg3_mac_loopback()
8197 u32 val, bmcr, mac_mode, ptest = 0; in tg3_phy_lpbk_set() local
8263 mac_mode = tp->mac_mode & in tg3_phy_lpbk_set()
8266 mac_mode |= MAC_MODE_PORT_MODE_GMII; in tg3_phy_lpbk_set()
8268 mac_mode |= MAC_MODE_PORT_MODE_MII; in tg3_phy_lpbk_set()
8274 mac_mode &= ~MAC_MODE_LINK_POLARITY; in tg3_phy_lpbk_set()
8276 mac_mode |= MAC_MODE_LINK_POLARITY; in tg3_phy_lpbk_set()
8282 tw32(MAC_MODE, mac_mode); in tg3_phy_lpbk_set()
8293 if (tp->mac_mode & MAC_MODE_PORT_INT_LPBACK) in tg3_set_loopback()
8302 if (!(tp->mac_mode & MAC_MODE_PORT_INT_LPBACK)) in tg3_set_loopback()
8884 tp->mac_mode &= ~MAC_MODE_TDE_ENABLE; in tg3_abort_hw()
8908 tp->mac_mode &= ~MAC_MODE_TDE_ENABLE; in tg3_abort_hw()
8909 tw32_f(MAC_MODE, tp->mac_mode); in tg3_abort_hw()
9272 tp->mac_mode = MAC_MODE_PORT_MODE_TBI; in tg3_chip_reset()
9273 val = tp->mac_mode; in tg3_chip_reset()
9275 tp->mac_mode = MAC_MODE_PORT_MODE_GMII; in tg3_chip_reset()
9276 val = tp->mac_mode; in tg3_chip_reset()
10425 tp->mac_mode |= MAC_MODE_TXSTAT_ENABLE | MAC_MODE_RXSTAT_ENABLE | in tg3_reset_hw()
10429 tp->mac_mode |= MAC_MODE_APE_TX_EN | MAC_MODE_APE_RX_EN; in tg3_reset_hw()
10433 tp->mac_mode |= MAC_MODE_LINK_POLARITY; in tg3_reset_hw()
10434 tw32_f(MAC_MODE, tp->mac_mode | MAC_MODE_RXSTAT_CLEAR | MAC_MODE_TXSTAT_CLEAR); in tg3_reset_hw()
11059 (tp->mac_mode & in tg3_timer()
11062 tw32_f(MAC_MODE, tp->mac_mode); in tg3_timer()
16900 tp->mac_mode = MAC_MODE_APE_TX_EN | MAC_MODE_APE_RX_EN; in tg3_get_invariants()
16902 tp->mac_mode = 0; in tg3_get_invariants()