src/dpdk/drivers/net/hinic/hinic_pmd_ethdev.c
static void hinic_mac_addr_remove(struct rte_eth_dev *dev, uint32_t index)
{
	struct hinic_nic_dev *nic_dev = HINIC_ETH_DEV_TO_PRIVATE_NIC_DEV(dev);
	u16 func_id;
	int ret;

	if (index >= HINIC_MAX_UC_MAC_ADDRS) {
		PMD_DRV_LOG(INFO, "Remove mac index(%u) is out of range",
			    index);
		return;
	}

	func_id = hinic_global_func_id(nic_dev->hwdev);
	ret = hinic_del_mac(nic_dev->hwdev,
			    dev->data->mac_addrs[index].addr_bytes, 0, func_id);
	if (ret)
		return;

	memset(&dev->data->mac_addrs[index], 0, sizeof(struct rte_ether_addr));
}
/**
 * DPDK callback to remove a MAC address.
 *
 * @param dev
 *   Pointer to Ethernet device structure.
 * @param index
 *   MAC address index, should less than 128.
 */
DPDK callback to remove a MAC address.
@param dev
Pointer to Ethernet device structure.
@param index
MAC address index, should less than 128.
DPDK callback to remove a MAC address . @param dev Pointer to Ethernet device structure . @param index MAC address index should less than 128 .
static void hinic_mac_addr_remove(struct rte_eth_dev *dev, uint32_t index)
{
	struct hinic_nic_dev *nic_dev = HINIC_ETH_DEV_TO_PRIVATE_NIC_DEV(dev);
	u16 func_id;
	int ret;
	if (index >= HINIC_MAX_UC_MAC_ADDRS) {
		PMD_DRV_LOG(INFO, "Remove mac index(%u) is out of range",
			    index);
		return;
	}
	func_id = hinic_global_func_id(nic_dev->hwdev);
	ret = hinic_del_mac(nic_dev->hwdev,
			    dev->data->mac_addrs[index].addr_bytes, 0, func_id);
	if (ret)
		return;
	memset(&dev->data->mac_addrs[index], 0, sizeof(struct rte_ether_addr));
}
static void hinic_mac_addr_remove ( struct rte_eth_dev * dev , uint32_t index ) { struct hinic_nic_dev * nic_dev = HINIC_ETH_DEV_TO_PRIVATE_NIC_DEV ( dev ) ; u16 func_id ; int ret ; if ( index >= HINIC_MAX_UC_MAC_ADDRS ) { PMD_DRV_LOG ( INFO , " " , index ) ; return ; } func_id = hinic_global_func_id ( nic_dev -> hwdev ) ; ret = hinic_del_mac ( nic_dev -> hwdev , dev -> data -> mac_addrs [ index ] . addr_bytes , 0 , func_id ) ; if ( ret ) return ; memset ( & dev -> data -> mac_addrs [ index ] , 0 , sizeof ( struct rte_ether_addr ) ) ; }
DPDK callback to remove a MAC address.
DPDK callback to remove a MAC address .