• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /freebsd-13-stable/sys/dev/vnic/

Lines Matching refs:vf

391 nic_clear_mbx_intr(struct nicpf *nic, int vf, int mbx_reg)
394 nic_reg_write(nic, NIC_PF_MAILBOX_INT + (mbx_reg << 3), (1UL << vf));
398 nic_get_mbx_addr(int vf)
401 return (NIC_PF_VF_0_127_MAILBOX_0_1 + (vf << NIC_VF_NUM_SHIFT));
406 * @vf: vf to which this message to be sent
410 nic_send_msg_to_vf(struct nicpf *nic, int vf, union nic_mbx *mbx)
412 bus_space_handle_t mbx_addr = nic_get_mbx_addr(vf);
432 * @vf: VF which sent READY message
435 nic_mbx_send_ready(struct nicpf *nic, int vf)
442 mbx.nic_cfg.vf_id = vf;
449 if (vf < MAX_LMAC) {
450 bgx_idx = NIC_GET_BGX_FROM_VF_LMAC_MAP(nic->vf_lmac_map[vf]);
451 lmac = NIC_GET_LMAC_FROM_VF_LMAC_MAP(nic->vf_lmac_map[vf]);
461 mbx.nic_cfg.loopback_supported = vf < MAX_LMAC;
463 nic_send_msg_to_vf(nic, vf, &mbx);
468 * @vf: VF to which ACK to be sent
471 nic_mbx_send_ack(struct nicpf *nic, int vf)
476 nic_send_msg_to_vf(nic, vf, &mbx);
482 * @vf: VF to which ACK to be sent
485 nic_mbx_send_nack(struct nicpf *nic, int vf)
490 nic_send_msg_to_vf(nic, vf, &mbx);
543 nic_update_hw_frs(struct nicpf *nic, int new_frs, int vf)
550 vf, NIC_HW_MIN_FRS, NIC_HW_MAX_FRS);
761 nic_send_rss_size(struct nicpf *nic, int vf)
767 nic_send_msg_to_vf(nic, vf, &mbx);
879 nic_handle_mbx_intr(struct nicpf *nic, int vf)
890 nic->mbx_lock[vf] = TRUE;
892 mbx_addr = nic_get_mbx_addr(vf);
903 nic_mbx_send_ready(nic, vf);
904 if (vf < MAX_LMAC) {
905 nic->link[vf] = 0;
906 nic->duplex[vf] = 0;
907 nic->speed[vf] = 0;
958 nic_send_rss_size(nic, vf);
966 nic->vf_info[vf].vf_enabled = TRUE;
970 nic->vf_info[vf].vf_enabled = FALSE;
980 "Invalid msg from VF%d, msg 0x%x\n", vf, mbx.msg.msg);
985 nic_mbx_send_ack(nic, vf);
987 nic_mbx_send_nack(nic, vf);
989 nic->mbx_lock[vf] = FALSE;
996 uint8_t vf, vf_per_mbx_reg = 64;
999 for (vf = 0; vf < vf_per_mbx_reg; vf++) {
1000 if (intr & (1UL << vf)) {
1001 nic_handle_mbx_intr(nic, vf + (mbx * vf_per_mbx_reg));
1002 nic_clear_mbx_intr(nic, vf, mbx);
1195 uint8_t vf, bgx, lmac;
1201 for (vf = 0; vf < nic->num_vf_en; vf++) {
1203 if (!nic->vf_info[vf].vf_enabled)
1207 bgx = NIC_GET_BGX_FROM_VF_LMAC_MAP(nic->vf_lmac_map[vf]);
1208 lmac = NIC_GET_LMAC_FROM_VF_LMAC_MAP(nic->vf_lmac_map[vf]);
1213 if (nic->link[vf] == link.link_up)
1216 if (!nic->mbx_lock[vf]) {
1217 nic->link[vf] = link.link_up;
1218 nic->duplex[vf] = link.duplex;
1219 nic->speed[vf] = link.speed;
1225 nic_send_msg_to_vf(nic, vf, &mbx);