Lines Matching refs:vf

43 			mv_list[i].vf = -1;  in ixgbe_alloc_vf_macvlans()
129 int vf = 0; in ixgbe_get_vfs() local
144 if (vf >= adapter->num_vfs) in ixgbe_get_vfs()
147 adapter->vfinfo[vf].vfdev = vfdev; in ixgbe_get_vfs()
148 ++vf; in ixgbe_get_vfs()
208 unsigned int num_vfs = adapter->num_vfs, vf; in ixgbe_disable_sriov() local
218 for (vf = 0; vf < num_vfs; ++vf) { in ixgbe_disable_sriov()
219 struct pci_dev *vfdev = adapter->vfinfo[vf].vfdev; in ixgbe_disable_sriov()
223 adapter->vfinfo[vf].vfdev = NULL; in ixgbe_disable_sriov()
364 u32 *msgbuf, u32 vf) in ixgbe_set_vf_multicasts() argument
368 struct vf_data_storage *vfinfo = &adapter->vfinfo[vf]; in ixgbe_set_vf_multicasts()
374 u32 vmolr = IXGBE_READ_REG(hw, IXGBE_VMOLR(vf)); in ixgbe_set_vf_multicasts()
402 IXGBE_WRITE_REG(hw, IXGBE_VMOLR(vf), vmolr); in ixgbe_set_vf_multicasts()
442 u32 vf) in ixgbe_set_vf_vlan() argument
458 err = hw->mac.ops.set_vfta(hw, vid, vf, !!add, false); in ixgbe_set_vf_vlan()
474 static int ixgbe_set_vf_lpe(struct ixgbe_adapter *adapter, u32 max_frame, u32 vf) in ixgbe_set_vf_lpe() argument
503 switch (adapter->vfinfo[vf].vf_api) { in ixgbe_set_vf_lpe()
527 vf_shift = vf % 32; in ixgbe_set_vf_lpe()
528 reg_offset = vf / 32; in ixgbe_set_vf_lpe()
559 static void ixgbe_set_vmolr(struct ixgbe_hw *hw, u32 vf, bool aupe) in ixgbe_set_vmolr() argument
561 u32 vmolr = IXGBE_READ_REG(hw, IXGBE_VMOLR(vf)); in ixgbe_set_vmolr()
567 IXGBE_WRITE_REG(hw, IXGBE_VMOLR(vf), vmolr); in ixgbe_set_vmolr()
570 static void ixgbe_clear_vmvir(struct ixgbe_adapter *adapter, u32 vf) in ixgbe_clear_vmvir() argument
574 IXGBE_WRITE_REG(hw, IXGBE_VMVIR(vf), 0); in ixgbe_clear_vmvir()
577 static void ixgbe_clear_vf_vlans(struct ixgbe_adapter *adapter, u32 vf) in ixgbe_clear_vf_vlans() argument
584 vlvfb_mask = BIT(vf % 32); in ixgbe_clear_vf_vlans()
589 u32 word = i * 2 + vf / 32; in ixgbe_clear_vf_vlans()
639 int vf, int index, unsigned char *mac_addr) in ixgbe_set_vf_macvlan() argument
647 if (entry->vf == vf) { in ixgbe_set_vf_macvlan()
648 entry->vf = -1; in ixgbe_set_vf_macvlan()
652 entry->vf_macvlan, vf); in ixgbe_set_vf_macvlan()
682 retval = ixgbe_add_mac_filter(adapter, mac_addr, vf); in ixgbe_set_vf_macvlan()
688 entry->vf = vf; in ixgbe_set_vf_macvlan()
694 static inline void ixgbe_vf_reset_event(struct ixgbe_adapter *adapter, u32 vf) in ixgbe_vf_reset_event() argument
698 struct vf_data_storage *vfinfo = &adapter->vfinfo[vf]; in ixgbe_vf_reset_event()
705 ixgbe_clear_vf_vlans(adapter, vf); in ixgbe_vf_reset_event()
708 ixgbe_set_vf_vlan(adapter, true, vfinfo->pf_vlan, vf); in ixgbe_vf_reset_event()
711 ixgbe_set_vmolr(hw, vf, !vfinfo->pf_vlan); in ixgbe_vf_reset_event()
715 ixgbe_clear_vmvir(adapter, vf); in ixgbe_vf_reset_event()
719 vfinfo->pf_qos, vf); in ixgbe_vf_reset_event()
722 adapter->default_up, vf); in ixgbe_vf_reset_event()
725 hw->mac.ops.set_vlan_anti_spoofing(hw, true, vf); in ixgbe_vf_reset_event()
726 hw->mac.ops.set_mac_anti_spoofing(hw, true, vf); in ixgbe_vf_reset_event()
731 adapter->vfinfo[vf].num_vf_mc_hashes = 0; in ixgbe_vf_reset_event()
734 ixgbe_ipsec_vf_clear(adapter, vf); in ixgbe_vf_reset_event()
739 ixgbe_del_mac_filter(adapter, adapter->vfinfo[vf].vf_mac_addresses, vf); in ixgbe_vf_reset_event()
740 ixgbe_set_vf_macvlan(adapter, vf, 0, NULL); in ixgbe_vf_reset_event()
743 adapter->vfinfo[vf].vf_api = ixgbe_mbox_api_10; in ixgbe_vf_reset_event()
747 unsigned int reg_idx = (vf * q_per_pool) + queue; in ixgbe_vf_reset_event()
763 static void ixgbe_vf_clear_mbx(struct ixgbe_adapter *adapter, u32 vf) in ixgbe_vf_clear_mbx() argument
770 IXGBE_WRITE_REG_ARRAY(hw, IXGBE_PFMBMEM(vf), word, 0); in ixgbe_vf_clear_mbx()
776 int vf, unsigned char *mac_addr) in ixgbe_set_vf_mac() argument
780 ixgbe_del_mac_filter(adapter, adapter->vfinfo[vf].vf_mac_addresses, vf); in ixgbe_set_vf_mac()
781 retval = ixgbe_add_mac_filter(adapter, mac_addr, vf); in ixgbe_set_vf_mac()
783 memcpy(adapter->vfinfo[vf].vf_mac_addresses, mac_addr, in ixgbe_set_vf_mac()
786 eth_zero_addr(adapter->vfinfo[vf].vf_mac_addresses); in ixgbe_set_vf_mac()
804 static inline void ixgbe_write_qde(struct ixgbe_adapter *adapter, u32 vf, in ixgbe_write_qde() argument
812 for (i = vf * q_per_pool; i < ((vf + 1) * q_per_pool); i++) { in ixgbe_write_qde()
832 static void ixgbe_set_vf_rx_tx(struct ixgbe_adapter *adapter, int vf) in ixgbe_set_vf_rx_tx() argument
838 vf_shift = vf % 32; in ixgbe_set_vf_rx_tx()
839 reg_offset = vf / 32; in ixgbe_set_vf_rx_tx()
844 if (adapter->vfinfo[vf].link_enable) { in ixgbe_set_vf_rx_tx()
876 static int ixgbe_vf_reset_msg(struct ixgbe_adapter *adapter, u32 vf) in ixgbe_vf_reset_msg() argument
880 unsigned char *vf_mac = adapter->vfinfo[vf].vf_mac_addresses; in ixgbe_vf_reset_msg()
887 e_info(probe, "VF Reset msg received from vf %d\n", vf); in ixgbe_vf_reset_msg()
890 ixgbe_vf_reset_event(adapter, vf); in ixgbe_vf_reset_msg()
892 ixgbe_vf_clear_mbx(adapter, vf); in ixgbe_vf_reset_msg()
896 ixgbe_set_vf_mac(adapter, vf, vf_mac); in ixgbe_vf_reset_msg()
898 vf_shift = vf % 32; in ixgbe_vf_reset_msg()
899 reg_offset = vf / 32; in ixgbe_vf_reset_msg()
903 if (adapter->vfinfo[vf].pf_vlan) in ixgbe_vf_reset_msg()
906 ixgbe_write_qde(adapter, vf, reg); in ixgbe_vf_reset_msg()
908 ixgbe_set_vf_rx_tx(adapter, vf); in ixgbe_vf_reset_msg()
911 adapter->vfinfo[vf].clear_to_send = true; in ixgbe_vf_reset_msg()
923 IXGBE_WRITE_REG(hw, IXGBE_PVFTDWBAHn(q_per_pool, vf, i), 0); in ixgbe_vf_reset_msg()
924 IXGBE_WRITE_REG(hw, IXGBE_PVFTDWBALn(q_per_pool, vf, i), 0); in ixgbe_vf_reset_msg()
929 if (!is_zero_ether_addr(vf_mac) && adapter->vfinfo[vf].pf_set_mac) { in ixgbe_vf_reset_msg()
941 ixgbe_write_mbx(hw, msgbuf, IXGBE_VF_PERMADDR_MSG_LEN, vf); in ixgbe_vf_reset_msg()
947 u32 *msgbuf, u32 vf) in ixgbe_set_vf_mac_addr() argument
952 e_warn(drv, "VF %d attempted to set invalid mac\n", vf); in ixgbe_set_vf_mac_addr()
956 if (adapter->vfinfo[vf].pf_set_mac && !adapter->vfinfo[vf].trusted && in ixgbe_set_vf_mac_addr()
957 !ether_addr_equal(adapter->vfinfo[vf].vf_mac_addresses, new_mac)) { in ixgbe_set_vf_mac_addr()
961 vf); in ixgbe_set_vf_mac_addr()
965 return ixgbe_set_vf_mac(adapter, vf, new_mac) < 0; in ixgbe_set_vf_mac_addr()
969 u32 *msgbuf, u32 vf) in ixgbe_set_vf_vlan_msg() argument
975 if (adapter->vfinfo[vf].pf_vlan || tcs) { in ixgbe_set_vf_vlan_msg()
979 vf); in ixgbe_set_vf_vlan_msg()
987 return ixgbe_set_vf_vlan(adapter, add, vid, vf); in ixgbe_set_vf_vlan_msg()
991 u32 *msgbuf, u32 vf) in ixgbe_set_vf_macvlan_msg() argument
997 if (adapter->vfinfo[vf].pf_set_mac && !adapter->vfinfo[vf].trusted && in ixgbe_set_vf_macvlan_msg()
1001 vf); in ixgbe_set_vf_macvlan_msg()
1008 e_warn(drv, "VF %d attempted to set invalid mac\n", vf); in ixgbe_set_vf_macvlan_msg()
1016 if (adapter->vfinfo[vf].spoofchk_enabled) { in ixgbe_set_vf_macvlan_msg()
1019 hw->mac.ops.set_mac_anti_spoofing(hw, false, vf); in ixgbe_set_vf_macvlan_msg()
1020 hw->mac.ops.set_vlan_anti_spoofing(hw, false, vf); in ixgbe_set_vf_macvlan_msg()
1024 err = ixgbe_set_vf_macvlan(adapter, vf, index, new_mac); in ixgbe_set_vf_macvlan_msg()
1028 vf); in ixgbe_set_vf_macvlan_msg()
1034 u32 *msgbuf, u32 vf) in ixgbe_negotiate_vf_api() argument
1044 adapter->vfinfo[vf].vf_api = api; in ixgbe_negotiate_vf_api()
1050 e_info(drv, "VF %d requested invalid api version %u\n", vf, api); in ixgbe_negotiate_vf_api()
1056 u32 *msgbuf, u32 vf) in ixgbe_get_vf_queues() argument
1064 switch (adapter->vfinfo[vf].vf_api) { in ixgbe_get_vf_queues()
1086 else if (adapter->vfinfo[vf].pf_vlan || adapter->vfinfo[vf].pf_qos) in ixgbe_get_vf_queues()
1097 static int ixgbe_get_vf_reta(struct ixgbe_adapter *adapter, u32 *msgbuf, u32 vf) in ixgbe_get_vf_reta() argument
1105 if (!adapter->vfinfo[vf].rss_query_enabled) in ixgbe_get_vf_reta()
1109 switch (adapter->vfinfo[vf].vf_api) { in ixgbe_get_vf_reta()
1133 u32 *msgbuf, u32 vf) in ixgbe_get_vf_rss_key() argument
1138 if (!adapter->vfinfo[vf].rss_query_enabled) in ixgbe_get_vf_rss_key()
1142 switch (adapter->vfinfo[vf].vf_api) { in ixgbe_get_vf_rss_key()
1157 u32 *msgbuf, u32 vf) in ixgbe_update_vf_xcast_mode() argument
1164 switch (adapter->vfinfo[vf].vf_api) { in ixgbe_update_vf_xcast_mode()
1178 !adapter->vfinfo[vf].trusted) { in ixgbe_update_vf_xcast_mode()
1182 if (adapter->vfinfo[vf].xcast_mode == xcast_mode) in ixgbe_update_vf_xcast_mode()
1219 vmolr = IXGBE_READ_REG(hw, IXGBE_VMOLR(vf)); in ixgbe_update_vf_xcast_mode()
1222 IXGBE_WRITE_REG(hw, IXGBE_VMOLR(vf), vmolr); in ixgbe_update_vf_xcast_mode()
1224 adapter->vfinfo[vf].xcast_mode = xcast_mode; in ixgbe_update_vf_xcast_mode()
1233 u32 *msgbuf, u32 vf) in ixgbe_get_vf_link_state() argument
1238 switch (adapter->vfinfo[vf].vf_api) { in ixgbe_get_vf_link_state()
1247 *link_state = adapter->vfinfo[vf].link_enable; in ixgbe_get_vf_link_state()
1252 static int ixgbe_rcv_msg_from_vf(struct ixgbe_adapter *adapter, u32 vf) in ixgbe_rcv_msg_from_vf() argument
1259 retval = ixgbe_read_mbx(hw, msgbuf, mbx_size, vf); in ixgbe_rcv_msg_from_vf()
1274 return ixgbe_vf_reset_msg(adapter, vf); in ixgbe_rcv_msg_from_vf()
1280 if (!adapter->vfinfo[vf].clear_to_send) { in ixgbe_rcv_msg_from_vf()
1282 ixgbe_write_mbx(hw, msgbuf, 1, vf); in ixgbe_rcv_msg_from_vf()
1288 retval = ixgbe_set_vf_mac_addr(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1291 retval = ixgbe_set_vf_multicasts(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1294 retval = ixgbe_set_vf_vlan_msg(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1297 retval = ixgbe_set_vf_lpe(adapter, msgbuf[1], vf); in ixgbe_rcv_msg_from_vf()
1300 retval = ixgbe_set_vf_macvlan_msg(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1303 retval = ixgbe_negotiate_vf_api(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1306 retval = ixgbe_get_vf_queues(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1309 retval = ixgbe_get_vf_reta(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1312 retval = ixgbe_get_vf_rss_key(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1315 retval = ixgbe_update_vf_xcast_mode(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1318 retval = ixgbe_get_vf_link_state(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1321 retval = ixgbe_ipsec_vf_add_sa(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1324 retval = ixgbe_ipsec_vf_del_sa(adapter, msgbuf, vf); in ixgbe_rcv_msg_from_vf()
1340 ixgbe_write_mbx(hw, msgbuf, mbx_size, vf); in ixgbe_rcv_msg_from_vf()
1345 static void ixgbe_rcv_ack_from_vf(struct ixgbe_adapter *adapter, u32 vf) in ixgbe_rcv_ack_from_vf() argument
1351 if (!adapter->vfinfo[vf].clear_to_send) in ixgbe_rcv_ack_from_vf()
1352 ixgbe_write_mbx(hw, &msg, 1, vf); in ixgbe_rcv_ack_from_vf()
1359 u32 vf; in ixgbe_msg_task() local
1362 for (vf = 0; vf < adapter->num_vfs; vf++) { in ixgbe_msg_task()
1364 if (!ixgbe_check_for_rst(hw, vf)) in ixgbe_msg_task()
1365 ixgbe_vf_reset_event(adapter, vf); in ixgbe_msg_task()
1368 if (!ixgbe_check_for_msg(hw, vf)) in ixgbe_msg_task()
1369 ixgbe_rcv_msg_from_vf(adapter, vf); in ixgbe_msg_task()
1372 if (!ixgbe_check_for_ack(hw, vf)) in ixgbe_msg_task()
1373 ixgbe_rcv_ack_from_vf(adapter, vf); in ixgbe_msg_task()
1378 static inline void ixgbe_ping_vf(struct ixgbe_adapter *adapter, int vf) in ixgbe_ping_vf() argument
1384 if (adapter->vfinfo[vf].clear_to_send) in ixgbe_ping_vf()
1386 ixgbe_write_mbx(hw, &ping, 1, vf); in ixgbe_ping_vf()
1418 int ixgbe_ndo_set_vf_mac(struct net_device *netdev, int vf, u8 *mac) in ixgbe_ndo_set_vf_mac() argument
1423 if (vf >= adapter->num_vfs) in ixgbe_ndo_set_vf_mac()
1428 mac, vf); in ixgbe_ndo_set_vf_mac()
1431 retval = ixgbe_set_vf_mac(adapter, vf, mac); in ixgbe_ndo_set_vf_mac()
1433 adapter->vfinfo[vf].pf_set_mac = true; in ixgbe_ndo_set_vf_mac()
1444 adapter->vfinfo[vf].vf_mac_addresses; in ixgbe_ndo_set_vf_mac()
1450 dev_info(&adapter->pdev->dev, "removing MAC on VF %d\n", vf); in ixgbe_ndo_set_vf_mac()
1452 retval = ixgbe_del_mac_filter(adapter, vf_mac_addr, vf); in ixgbe_ndo_set_vf_mac()
1454 adapter->vfinfo[vf].pf_set_mac = false; in ixgbe_ndo_set_vf_mac()
1466 static int ixgbe_enable_port_vlan(struct ixgbe_adapter *adapter, int vf, in ixgbe_enable_port_vlan() argument
1472 err = ixgbe_set_vf_vlan(adapter, true, vlan, vf); in ixgbe_enable_port_vlan()
1477 ixgbe_set_vf_vlan(adapter, false, 0, vf); in ixgbe_enable_port_vlan()
1479 ixgbe_set_vmvir(adapter, vlan, qos, vf); in ixgbe_enable_port_vlan()
1480 ixgbe_set_vmolr(hw, vf, false); in ixgbe_enable_port_vlan()
1484 ixgbe_write_qde(adapter, vf, IXGBE_QDE_ENABLE | in ixgbe_enable_port_vlan()
1487 adapter->vfinfo[vf].pf_vlan = vlan; in ixgbe_enable_port_vlan()
1488 adapter->vfinfo[vf].pf_qos = qos; in ixgbe_enable_port_vlan()
1490 "Setting VLAN %d, QOS 0x%x on VF %d\n", vlan, qos, vf); in ixgbe_enable_port_vlan()
1502 static int ixgbe_disable_port_vlan(struct ixgbe_adapter *adapter, int vf) in ixgbe_disable_port_vlan() argument
1508 adapter->vfinfo[vf].pf_vlan, vf); in ixgbe_disable_port_vlan()
1510 ixgbe_set_vf_vlan(adapter, true, 0, vf); in ixgbe_disable_port_vlan()
1511 ixgbe_clear_vmvir(adapter, vf); in ixgbe_disable_port_vlan()
1512 ixgbe_set_vmolr(hw, vf, true); in ixgbe_disable_port_vlan()
1516 ixgbe_write_qde(adapter, vf, IXGBE_QDE_ENABLE); in ixgbe_disable_port_vlan()
1518 adapter->vfinfo[vf].pf_vlan = 0; in ixgbe_disable_port_vlan()
1519 adapter->vfinfo[vf].pf_qos = 0; in ixgbe_disable_port_vlan()
1524 int ixgbe_ndo_set_vf_vlan(struct net_device *netdev, int vf, u16 vlan, in ixgbe_ndo_set_vf_vlan() argument
1530 if ((vf >= adapter->num_vfs) || (vlan > 4095) || (qos > 7)) in ixgbe_ndo_set_vf_vlan()
1542 if (adapter->vfinfo[vf].pf_vlan) in ixgbe_ndo_set_vf_vlan()
1543 err = ixgbe_disable_port_vlan(adapter, vf); in ixgbe_ndo_set_vf_vlan()
1546 err = ixgbe_enable_port_vlan(adapter, vf, vlan, qos); in ixgbe_ndo_set_vf_vlan()
1548 err = ixgbe_disable_port_vlan(adapter, vf); in ixgbe_ndo_set_vf_vlan()
1569 static void ixgbe_set_vf_rate_limit(struct ixgbe_adapter *adapter, int vf) in ixgbe_set_vf_rate_limit() argument
1575 u16 tx_rate = adapter->vfinfo[vf].tx_rate; in ixgbe_set_vf_rate_limit()
1614 unsigned int reg_idx = (vf * queues_per_pool) + queue; in ixgbe_set_vf_rate_limit()
1643 int ixgbe_ndo_set_vf_bw(struct net_device *netdev, int vf, int min_tx_rate, in ixgbe_ndo_set_vf_bw() argument
1650 if (vf >= adapter->num_vfs) in ixgbe_ndo_set_vf_bw()
1671 adapter->vfinfo[vf].tx_rate = max_tx_rate; in ixgbe_ndo_set_vf_bw()
1674 ixgbe_set_vf_rate_limit(adapter, vf); in ixgbe_ndo_set_vf_bw()
1679 int ixgbe_ndo_set_vf_spoofchk(struct net_device *netdev, int vf, bool setting) in ixgbe_ndo_set_vf_spoofchk() argument
1684 if (vf >= adapter->num_vfs) in ixgbe_ndo_set_vf_spoofchk()
1687 adapter->vfinfo[vf].spoofchk_enabled = setting; in ixgbe_ndo_set_vf_spoofchk()
1690 hw->mac.ops.set_mac_anti_spoofing(hw, setting, vf); in ixgbe_ndo_set_vf_spoofchk()
1693 hw->mac.ops.set_vlan_anti_spoofing(hw, setting, vf); in ixgbe_ndo_set_vf_spoofchk()
1709 hw->mac.ops.set_ethertype_anti_spoofing(hw, setting, vf); in ixgbe_ndo_set_vf_spoofchk()
1723 void ixgbe_set_vf_link_state(struct ixgbe_adapter *adapter, int vf, int state) in ixgbe_set_vf_link_state() argument
1725 adapter->vfinfo[vf].link_state = state; in ixgbe_set_vf_link_state()
1730 adapter->vfinfo[vf].link_enable = false; in ixgbe_set_vf_link_state()
1732 adapter->vfinfo[vf].link_enable = true; in ixgbe_set_vf_link_state()
1735 adapter->vfinfo[vf].link_enable = true; in ixgbe_set_vf_link_state()
1738 adapter->vfinfo[vf].link_enable = false; in ixgbe_set_vf_link_state()
1742 ixgbe_set_vf_rx_tx(adapter, vf); in ixgbe_set_vf_link_state()
1745 adapter->vfinfo[vf].clear_to_send = false; in ixgbe_set_vf_link_state()
1746 ixgbe_ping_vf(adapter, vf); in ixgbe_set_vf_link_state()
1757 int ixgbe_ndo_set_vf_link_state(struct net_device *netdev, int vf, int state) in ixgbe_ndo_set_vf_link_state() argument
1762 if (vf < 0 || vf >= adapter->num_vfs) { in ixgbe_ndo_set_vf_link_state()
1764 "NDO set VF link - invalid VF identifier %d\n", vf); in ixgbe_ndo_set_vf_link_state()
1772 vf, state); in ixgbe_ndo_set_vf_link_state()
1776 "NDO set VF %d link state disable\n", vf); in ixgbe_ndo_set_vf_link_state()
1777 ixgbe_set_vf_link_state(adapter, vf, state); in ixgbe_ndo_set_vf_link_state()
1781 "NDO set VF %d link state auto\n", vf); in ixgbe_ndo_set_vf_link_state()
1782 ixgbe_set_vf_link_state(adapter, vf, state); in ixgbe_ndo_set_vf_link_state()
1786 "NDO set VF %d - invalid link state %d\n", vf, state); in ixgbe_ndo_set_vf_link_state()
1793 int ixgbe_ndo_set_vf_rss_query_en(struct net_device *netdev, int vf, in ixgbe_ndo_set_vf_rss_query_en() argument
1805 if (vf >= adapter->num_vfs) in ixgbe_ndo_set_vf_rss_query_en()
1808 adapter->vfinfo[vf].rss_query_enabled = setting; in ixgbe_ndo_set_vf_rss_query_en()
1813 int ixgbe_ndo_set_vf_trust(struct net_device *netdev, int vf, bool setting) in ixgbe_ndo_set_vf_trust() argument
1817 if (vf >= adapter->num_vfs) in ixgbe_ndo_set_vf_trust()
1821 if (adapter->vfinfo[vf].trusted == setting) in ixgbe_ndo_set_vf_trust()
1824 adapter->vfinfo[vf].trusted = setting; in ixgbe_ndo_set_vf_trust()
1827 adapter->vfinfo[vf].clear_to_send = false; in ixgbe_ndo_set_vf_trust()
1828 ixgbe_ping_vf(adapter, vf); in ixgbe_ndo_set_vf_trust()
1830 e_info(drv, "VF %u is %strusted\n", vf, setting ? "" : "not "); in ixgbe_ndo_set_vf_trust()
1836 int vf, struct ifla_vf_info *ivi) in ixgbe_ndo_get_vf_config() argument
1839 if (vf >= adapter->num_vfs) in ixgbe_ndo_get_vf_config()
1841 ivi->vf = vf; in ixgbe_ndo_get_vf_config()
1842 memcpy(&ivi->mac, adapter->vfinfo[vf].vf_mac_addresses, ETH_ALEN); in ixgbe_ndo_get_vf_config()
1843 ivi->max_tx_rate = adapter->vfinfo[vf].tx_rate; in ixgbe_ndo_get_vf_config()
1845 ivi->vlan = adapter->vfinfo[vf].pf_vlan; in ixgbe_ndo_get_vf_config()
1846 ivi->qos = adapter->vfinfo[vf].pf_qos; in ixgbe_ndo_get_vf_config()
1847 ivi->spoofchk = adapter->vfinfo[vf].spoofchk_enabled; in ixgbe_ndo_get_vf_config()
1848 ivi->rss_query_en = adapter->vfinfo[vf].rss_query_enabled; in ixgbe_ndo_get_vf_config()
1849 ivi->trusted = adapter->vfinfo[vf].trusted; in ixgbe_ndo_get_vf_config()
1850 ivi->linkstate = adapter->vfinfo[vf].link_state; in ixgbe_ndo_get_vf_config()