Lines Matching refs:mac

179 bna_bfi_ucast_req(struct bna_rxf *rxf, struct bna_mac *mac,  in bna_bfi_ucast_req()  argument
187 ether_addr_copy(req->mac_addr, mac->addr); in bna_bfi_ucast_req()
194 bna_bfi_mcast_add_req(struct bna_rxf *rxf, struct bna_mac *mac) in bna_bfi_mcast_add_req() argument
203 ether_addr_copy(req->mac_addr, mac->addr); in bna_bfi_mcast_add_req()
350 struct bna_mac *mac; in bna_rxf_mcmac_get() local
352 list_for_each_entry(mac, &rxf->mcast_active_q, qe) in bna_rxf_mcmac_get()
353 if (ether_addr_equal(mac->addr, mac_addr)) in bna_rxf_mcmac_get()
354 return mac; in bna_rxf_mcmac_get()
356 list_for_each_entry(mac, &rxf->mcast_pending_del_q, qe) in bna_rxf_mcmac_get()
357 if (ether_addr_equal(mac->addr, mac_addr)) in bna_rxf_mcmac_get()
358 return mac; in bna_rxf_mcmac_get()
394 bna_rxf_mcast_del(struct bna_rxf *rxf, struct bna_mac *mac, in bna_rxf_mcast_del() argument
400 mchandle = mac->handle; in bna_rxf_mcast_del()
413 mac->handle = NULL; in bna_rxf_mcast_del()
421 struct bna_mac *mac = NULL; in bna_rxf_mcast_cfg_apply() local
426 mac = list_first_entry(&rxf->mcast_pending_del_q, in bna_rxf_mcast_cfg_apply()
428 ret = bna_rxf_mcast_del(rxf, mac, BNA_HARD_CLEANUP); in bna_rxf_mcast_cfg_apply()
429 list_move_tail(&mac->qe, bna_mcam_mod_del_q(rxf->rx->bna)); in bna_rxf_mcast_cfg_apply()
436 mac = list_first_entry(&rxf->mcast_pending_add_q, in bna_rxf_mcast_cfg_apply()
438 list_move_tail(&mac->qe, &rxf->mcast_active_q); in bna_rxf_mcast_cfg_apply()
439 bna_bfi_mcast_add_req(rxf, mac); in bna_rxf_mcast_cfg_apply()
469 struct bna_mac *mac; in bna_rxf_mcast_cfg_reset() local
474 mac = list_first_entry(&rxf->mcast_pending_del_q, in bna_rxf_mcast_cfg_reset()
476 ret = bna_rxf_mcast_del(rxf, mac, cleanup); in bna_rxf_mcast_cfg_reset()
477 list_move_tail(&mac->qe, bna_mcam_mod_del_q(rxf->rx->bna)); in bna_rxf_mcast_cfg_reset()
484 mac = list_first_entry(&rxf->mcast_active_q, in bna_rxf_mcast_cfg_reset()
486 list_move_tail(&mac->qe, &rxf->mcast_pending_add_q); in bna_rxf_mcast_cfg_reset()
487 if (bna_rxf_mcast_del(rxf, mac, cleanup)) in bna_rxf_mcast_cfg_reset()
653 struct bna_mac *mac; in bna_rxf_uninit() local
659 mac = list_first_entry(&rxf->ucast_pending_add_q, in bna_rxf_uninit()
661 list_move_tail(&mac->qe, bna_ucam_mod_free_q(rxf->rx->bna)); in bna_rxf_uninit()
671 mac = list_first_entry(&rxf->mcast_pending_add_q, in bna_rxf_uninit()
673 list_move_tail(&mac->qe, bna_mcam_mod_free_q(rxf->rx->bna)); in bna_rxf_uninit()
750 struct bna_mac *mac; in bna_rx_mcast_add() local
760 mac = bna_cam_mod_mac_get(bna_mcam_mod_free_q(rxf->rx->bna)); in bna_rx_mcast_add()
761 if (mac == NULL) in bna_rx_mcast_add()
763 ether_addr_copy(mac->addr, addr); in bna_rx_mcast_add()
764 list_add_tail(&mac->qe, &rxf->mcast_pending_add_q); in bna_rx_mcast_add()
781 struct bna_mac *mac, *del_mac; in bna_rx_ucast_listset() local
786 mac = list_first_entry(&rxf->ucast_pending_add_q, in bna_rx_ucast_listset()
788 list_move_tail(&mac->qe, &ucam_mod->free_q); in bna_rx_ucast_listset()
793 mac = list_first_entry(&rxf->ucast_active_q, in bna_rx_ucast_listset()
796 ether_addr_copy(del_mac->addr, mac->addr); in bna_rx_ucast_listset()
797 del_mac->handle = mac->handle; in bna_rx_ucast_listset()
799 list_move_tail(&mac->qe, &ucam_mod->free_q); in bna_rx_ucast_listset()
805 mac = bna_cam_mod_mac_get(&ucam_mod->free_q); in bna_rx_ucast_listset()
806 if (mac == NULL) in bna_rx_ucast_listset()
808 ether_addr_copy(mac->addr, mcaddr); in bna_rx_ucast_listset()
809 list_add_tail(&mac->qe, &list_head); in bna_rx_ucast_listset()
815 mac = list_first_entry(&list_head, struct bna_mac, qe); in bna_rx_ucast_listset()
816 list_move_tail(&mac->qe, &rxf->ucast_pending_add_q); in bna_rx_ucast_listset()
825 mac = list_first_entry(&list_head, struct bna_mac, qe); in bna_rx_ucast_listset()
826 list_move_tail(&mac->qe, &ucam_mod->free_q); in bna_rx_ucast_listset()
839 struct bna_mac *mac, *del_mac; in bna_rx_mcast_listset() local
844 mac = list_first_entry(&rxf->mcast_pending_add_q, in bna_rx_mcast_listset()
846 list_move_tail(&mac->qe, &mcam_mod->free_q); in bna_rx_mcast_listset()
851 mac = list_first_entry(&rxf->mcast_active_q, in bna_rx_mcast_listset()
854 ether_addr_copy(del_mac->addr, mac->addr); in bna_rx_mcast_listset()
855 del_mac->handle = mac->handle; in bna_rx_mcast_listset()
857 mac->handle = NULL; in bna_rx_mcast_listset()
858 list_move_tail(&mac->qe, &mcam_mod->free_q); in bna_rx_mcast_listset()
864 mac = bna_cam_mod_mac_get(&mcam_mod->free_q); in bna_rx_mcast_listset()
865 if (mac == NULL) in bna_rx_mcast_listset()
867 ether_addr_copy(mac->addr, mcaddr); in bna_rx_mcast_listset()
868 list_add_tail(&mac->qe, &list_head); in bna_rx_mcast_listset()
875 mac = list_first_entry(&list_head, struct bna_mac, qe); in bna_rx_mcast_listset()
876 list_move_tail(&mac->qe, &rxf->mcast_pending_add_q); in bna_rx_mcast_listset()
885 mac = list_first_entry(&list_head, struct bna_mac, qe); in bna_rx_mcast_listset()
886 list_move_tail(&mac->qe, &mcam_mod->free_q); in bna_rx_mcast_listset()
896 struct bna_mac *mac, *del_mac; in bna_rx_mcast_delall() local
901 mac = list_first_entry(&rxf->mcast_pending_add_q, in bna_rx_mcast_delall()
903 list_move_tail(&mac->qe, bna_mcam_mod_free_q(rxf->rx->bna)); in bna_rx_mcast_delall()
908 mac = list_first_entry(&rxf->mcast_active_q, in bna_rx_mcast_delall()
910 list_del(&mac->qe); in bna_rx_mcast_delall()
912 memcpy(del_mac, mac, sizeof(*del_mac)); in bna_rx_mcast_delall()
914 mac->handle = NULL; in bna_rx_mcast_delall()
915 list_add_tail(&mac->qe, bna_mcam_mod_free_q(rxf->rx->bna)); in bna_rx_mcast_delall()
956 struct bna_mac *mac = NULL; in bna_rxf_ucast_cfg_apply() local
960 mac = list_first_entry(&rxf->ucast_pending_del_q, in bna_rxf_ucast_cfg_apply()
962 bna_bfi_ucast_req(rxf, mac, BFI_ENET_H2I_MAC_UCAST_DEL_REQ); in bna_rxf_ucast_cfg_apply()
963 list_move_tail(&mac->qe, bna_ucam_mod_del_q(rxf->rx->bna)); in bna_rxf_ucast_cfg_apply()
980 mac = list_first_entry(&rxf->ucast_pending_add_q, in bna_rxf_ucast_cfg_apply()
982 list_move_tail(&mac->qe, &rxf->ucast_active_q); in bna_rxf_ucast_cfg_apply()
983 bna_bfi_ucast_req(rxf, mac, BFI_ENET_H2I_MAC_UCAST_ADD_REQ); in bna_rxf_ucast_cfg_apply()
993 struct bna_mac *mac; in bna_rxf_ucast_cfg_reset() local
997 mac = list_first_entry(&rxf->ucast_pending_del_q, in bna_rxf_ucast_cfg_reset()
1000 list_move_tail(&mac->qe, in bna_rxf_ucast_cfg_reset()
1003 bna_bfi_ucast_req(rxf, mac, in bna_rxf_ucast_cfg_reset()
1005 list_move_tail(&mac->qe, in bna_rxf_ucast_cfg_reset()
1013 mac = list_first_entry(&rxf->ucast_active_q, in bna_rxf_ucast_cfg_reset()
1015 list_move_tail(&mac->qe, &rxf->ucast_pending_add_q); in bna_rxf_ucast_cfg_reset()
1017 bna_bfi_ucast_req(rxf, mac, in bna_rxf_ucast_cfg_reset()