Lines Matching +full:mac +full:- +full:address
2 SPDX-License-Identifier: BSD-3-Clause
4 Copyright (c) 2001-2020, Intel Corporation
42 * ixgbe_init_ops_vf - Initialize the pointers for vf
45 * This will assign function pointers, adapter-specific functions can
47 * their own adapter-specific function pointers.
54 /* MAC */
55 hw->mac.ops.init_hw = ixgbe_init_hw_vf;
56 hw->mac.ops.reset_hw = ixgbe_reset_hw_vf;
57 hw->mac.ops.start_hw = ixgbe_start_hw_vf;
59 hw->mac.ops.clear_hw_cntrs = NULL;
60 hw->mac.ops.get_media_type = NULL;
61 hw->mac.ops.get_mac_addr = ixgbe_get_mac_addr_vf;
62 hw->mac.ops.stop_adapter = ixgbe_stop_adapter_vf;
63 hw->mac.ops.get_bus_info = NULL;
64 hw->mac.ops.negotiate_api_version = ixgbevf_negotiate_api_version;
67 hw->mac.ops.setup_link = ixgbe_setup_mac_link_vf;
68 hw->mac.ops.check_link = ixgbe_check_mac_link_vf;
69 hw->mac.ops.get_link_capabilities = NULL;
72 hw->mac.ops.set_rar = ixgbe_set_rar_vf;
73 hw->mac.ops.set_uc_addr = ixgbevf_set_uc_addr_vf;
74 hw->mac.ops.init_rx_addrs = NULL;
75 hw->mac.ops.update_mc_addr_list = ixgbe_update_mc_addr_list_vf;
76 hw->mac.ops.update_xcast_mode = ixgbevf_update_xcast_mode;
77 hw->mac.ops.get_link_state = ixgbe_get_link_state_vf;
78 hw->mac.ops.enable_mc = NULL;
79 hw->mac.ops.disable_mc = NULL;
80 hw->mac.ops.clear_vfta = NULL;
81 hw->mac.ops.set_vfta = ixgbe_set_vfta_vf;
82 hw->mac.ops.set_rlpml = ixgbevf_rlpml_set_vf;
84 hw->mac.max_tx_queues = 1;
85 hw->mac.max_rx_queues = 1;
88 hw->mbx.ops[i].init_params = ixgbe_init_mbx_params_vf;
93 /* ixgbe_virt_clr_reg - Set register to default (power on) state.
137 * ixgbe_start_hw_vf - Prepare hardware for Tx/Rx
141 * all on chip counters, initializes receive address registers, multicast
148 hw->adapter_stopped = false;
154 * ixgbe_init_hw_vf - virtual function hardware initialization
162 s32 status = hw->mac.ops.start_hw(hw);
164 hw->mac.ops.get_mac_addr(hw, hw->mac.addr);
170 * ixgbe_reset_hw_vf - Performs hardware reset
178 struct ixgbe_mbx_info *mbx = &hw->mbx;
187 hw->mac.ops.stop_adapter(hw);
190 hw->api_version = ixgbe_mbox_api_10;
193 DEBUGOUT("Issuing a function level reset to MAC\n");
201 while (!mbx->ops[0].check_for_rst(hw, 0) && timeout) {
202 timeout--;
213 mbx->timeout = IXGBE_VF_MBX_INIT_TIMEOUT;
223 * on the mac address in word 3
235 memcpy(hw->mac.perm_addr, addr, IXGBE_ETH_LENGTH_OF_ADDRESS);
237 hw->mac.mc_filter_type = msgbuf[IXGBE_VF_MC_TYPE_WORD];
243 * ixgbe_stop_adapter_vf - Generic stop Tx/Rx units
260 hw->adapter_stopped = true;
269 for (i = 0; i < hw->mac.max_tx_queues; i++)
273 for (i = 0; i < hw->mac.max_rx_queues; i++) {
289 * ixgbe_mta_vector - Determines bit-vector in multicast table to set
291 * @mc_addr: the multicast address
293 * Extracts the 12 bits, from a multicast address, to determine which
294 * bit-vector to set in the multicast table. The hardware uses 12 bits, from
295 * incoming rx multicast addresses, to determine the bit-vector to check in
296 * the MTA. Which of the 4 combination, of 12-bits, the hardware uses is set
304 switch (hw->mac.mc_filter_type) {
305 case 0: /* use bits [47:36] of the address */
308 case 1: /* use bits [46:35] of the address */
311 case 2: /* use bits [45:34] of the address */
314 case 3: /* use bits [43:32] of the address */
323 /* vector can only be 12-bits or boundary will be exceeded */
340 * ixgbe_set_rar_vf - set device MAC address
342 * @index: Receive address register to write
343 * @addr: Address to put into receive address register
345 * @enable_addr: set flag that address is active
362 /* if we had failure, the address was rejected, use "perm_addr" */
365 ixgbe_get_mac_addr_vf(hw, hw->mac.addr);
373 * ixgbe_update_mc_addr_list_vf - Update Multicast addresses
377 * @next: caller supplied function to return next address in list
401 * It would be unusual for a server to request that many multi-cast
421 * ixgbevf_update_xcast_mode - Update Multicast mode
432 switch (hw->api_version) {
459 * ixgbe_get_link_state_vf - Get VF link state from PF
487 * ixgbe_set_vfta_vf - Set/Unset vlan filter table address
516 * ixgbe_get_num_of_tx_queues_vf - Get number of TX queues
528 * ixgbe_get_num_of_rx_queues_vf - Get number of RX queues
540 * ixgbe_get_mac_addr_vf - Read device MAC address
542 * @mac_addr: the MAC address
549 mac_addr[i] = hw->mac.perm_addr[i];
585 * ixgbe_setup_mac_link_vf - Setup MAC link settings
600 * ixgbe_check_mac_link_vf - Get link/speed status
611 struct ixgbe_mbx_info *mbx = &hw->mbx;
612 struct ixgbe_mac_info *mac = &hw->mac;
620 if (!mbx->ops[0].check_for_rst(hw, 0) || !mbx->timeout)
621 mac->get_link_status = true;
623 if (!mac->get_link_status)
634 if (mac->type == ixgbe_mac_82599_vf) {
649 if (hw->mac.type >= ixgbe_mac_X550_vf) {
659 if (hw->mac.type == ixgbe_mac_X550_vf) {
666 /* Since Reserved in older MAC's */
667 if (hw->mac.type >= ixgbe_mac_X550_vf)
678 if (hw->api_version >= ixgbe_mbox_api_15)
679 mac->get_link_status = false;
691 if (!mbx->timeout) {
699 mac->get_link_status = false;
702 *link_up = !mac->get_link_status;
707 * ixgbevf_rlpml_set_vf - Set the maximum receive packet length
730 * ixgbevf_negotiate_api_version - Negotiate supported API version
750 hw->api_version = api;
767 switch (hw->api_version) {
794 hw->mac.max_tx_queues = msg[IXGBE_VF_TX_QUEUES];
795 if (hw->mac.max_tx_queues == 0 ||
796 hw->mac.max_tx_queues > IXGBE_VF_MAX_TX_QUEUES)
797 hw->mac.max_tx_queues = IXGBE_VF_MAX_TX_QUEUES;
799 hw->mac.max_rx_queues = msg[IXGBE_VF_RX_QUEUES];
800 if (hw->mac.max_rx_queues == 0 ||
801 hw->mac.max_rx_queues > IXGBE_VF_MAX_RX_QUEUES)
802 hw->mac.max_rx_queues = IXGBE_VF_MAX_RX_QUEUES;
806 if (*num_tcs > hw->mac.max_rx_queues)
810 /* default to queue 0 on out-of-bounds queue number */
811 if (*default_tc >= hw->mac.max_tx_queues)