Lines Matching refs:drv
442 struct mac_driver *drv; in hns_mac_reset() local
444 drv = hns_mac_get_drv(mac_cb); in hns_mac_reset()
446 drv->mac_init(drv); in hns_mac_reset()
448 if (drv->config_max_frame_length) in hns_mac_reset()
449 drv->config_max_frame_length(drv, mac_cb->max_frm); in hns_mac_reset()
451 if (drv->set_tx_auto_pause_frames) in hns_mac_reset()
452 drv->set_tx_auto_pause_frames(drv, mac_cb->tx_pause_frm_time); in hns_mac_reset()
454 if (drv->set_an_mode) in hns_mac_reset()
455 drv->set_an_mode(drv, 1); in hns_mac_reset()
457 if (drv->mac_pausefrm_cfg) { in hns_mac_reset()
459 drv->mac_pausefrm_cfg(drv, 0, 0); in hns_mac_reset()
461 drv->mac_pausefrm_cfg(drv, 0, 1); in hns_mac_reset()
467 struct mac_driver *drv = hns_mac_get_drv(mac_cb); in hns_mac_set_mtu() local
475 if (!drv->config_max_frame_length) in hns_mac_set_mtu()
482 drv->config_max_frame_length(drv, new_frm); in hns_mac_set_mtu()
631 struct mac_driver *drv; in hns_mac_init_ex() local
639 drv = (struct mac_driver *)hns_gmac_config(mac_cb, ¶m); in hns_mac_init_ex()
641 drv = (struct mac_driver *)hns_xgmac_config(mac_cb, ¶m); in hns_mac_init_ex()
643 if (!drv) in hns_mac_init_ex()
646 mac_cb->priv.mac = (void *)drv; in hns_mac_init_ex()
658 drv->mac_free(mac_cb->priv.mac); in hns_mac_init_ex()
825 struct mac_driver *drv = hns_mac_get_drv(mac_cb); in hns_mac_config_mac_loopback() local
827 if (drv->config_loopback) in hns_mac_config_mac_loopback()
828 ret = drv->config_loopback(drv, loop, en); in hns_mac_config_mac_loopback()