Home
last modified time | relevance | path

Searched refs:num_vfs (Results 1 – 25 of 46) sorted by relevance

12

/freebsd/usr.sbin/iovctl/
H A Dvalidate.c231 uint16_t vf_num, num_vfs; in validate_config() local
238 num_vfs = get_num_vfs(pf); in validate_config()
241 if (num_vfs == 0) in validate_config()
246 for (i = 0; i < num_vfs; i++) { in validate_config()
264 if (vf_num >= num_vfs) in validate_config()
267 vf_num, num_vfs); in validate_config()
/freebsd/sys/dev/ixgbe/
H A Dif_sriov.c210 for (int i = 0; i < sc->num_vfs; i++) { in ixgbe_ping_all_vfs()
655 for (i = 0; i < sc->num_vfs; i++) { in ixgbe_handle_mbx()
672 ixgbe_if_iov_init(if_ctx_t ctx, u16 num_vfs, const nvlist_t *config) in ixgbe_if_iov_init() argument
680 if (num_vfs == 0) { in ixgbe_if_iov_init()
692 if (num_vfs >= IXGBE_32_VM) in ixgbe_if_iov_init()
700 if ((num_vfs > sc->pool) || (num_vfs >= IXGBE_64_VM)) { in ixgbe_if_iov_init()
705 sc->vfs = malloc(sizeof(*sc->vfs) * num_vfs, M_IXGBE_SRIOV, in ixgbe_if_iov_init()
713 sc->num_vfs = num_vfs; in ixgbe_if_iov_init()
722 sc->num_vfs = 0; in ixgbe_if_iov_init()
755 sc->num_vfs = 0; in ixgbe_if_iov_uninit()
[all …]
H A Dixgbe.h430 int num_vfs; member
/freebsd/sys/dev/pci/
H A Dpci_iov_schema.c768 uint16_t num_vfs) in pci_iov_schema_validate_vfs() argument
773 for (i = 0; i < num_vfs; i++) { in pci_iov_schema_validate_vfs()
813 pci_iov_schema_validate_dev_name(const char *name, uint16_t num_vfs) in pci_iov_schema_validate_dev_name() argument
848 if (vf_num >= num_vfs) in pci_iov_schema_validate_dev_name()
860 pci_iov_schema_validate_device_names(const nvlist_t *config, uint16_t num_vfs) in pci_iov_schema_validate_device_names() argument
869 error = pci_iov_schema_validate_dev_name(name, num_vfs); in pci_iov_schema_validate_device_names()
891 uint16_t num_vfs; in pci_iov_schema_validate_config() local
898 num_vfs = pci_iov_config_get_num_vfs(config); in pci_iov_schema_validate_config()
900 error = pci_iov_schema_validate_vfs(schema, config, num_vfs); in pci_iov_schema_validate_config()
904 return (pci_iov_schema_validate_device_names(config, num_vfs)); in pci_iov_schema_validate_config()
H A Dpci_iov.c514 pci_iov_init(device_t dev, uint16_t num_vfs, const nvlist_t *config) in pci_iov_init() argument
520 return (PCI_IOV_INIT(dev, num_vfs, driver_config)); in pci_iov_init()
687 uint16_t num_vfs, total_vfs; in pci_iov_config() local
709 num_vfs = pci_iov_config_get_num_vfs(config); in pci_iov_config()
711 if (num_vfs > total_vfs) { in pci_iov_config()
724 error = pci_iov_init(dev, num_vfs, config); in pci_iov_config()
729 IOV_WRITE(dinfo, PCIR_SRIOV_NUM_VFS, num_vfs, 2); in pci_iov_config()
735 last_rid = first_rid + (num_vfs - 1) * rid_stride; in pci_iov_config()
757 iov->iov_num_vfs = num_vfs; in pci_iov_config()
H A Dpci_iov_if.m39 uint16_t num_vfs;
/freebsd/sys/dev/mlx4/mlx4_core/
H A Dmlx4_port.c1120 dev->persist->num_vfs + 1); in mlx4_get_slave_num_gids()
1122 vfs = bitmap_weight(slaves_pport.slaves, dev->persist->num_vfs + 1) - 1; in mlx4_get_slave_num_gids()
1157 dev->persist->num_vfs + 1); in mlx4_get_base_gid_ix()
1160 vfs = bitmap_weight(slaves_pport.slaves, dev->persist->num_vfs + 1) - 1; in mlx4_get_base_gid_ix()
1211 if (slave < 0 || slave > dev->persist->num_vfs) in mlx4_reset_roce_gids()
1752 unsigned num_vfs; in mlx4_get_slave_from_roce_gid() local
1759 num_vfs = bitmap_weight(slaves_pport.slaves, in mlx4_get_slave_from_roce_gid()
1760 dev->persist->num_vfs + 1) - 1; in mlx4_get_slave_from_roce_gid()
1776 else if (found_ix < MLX4_ROCE_PF_GIDS + (vf_gids % num_vfs) * in mlx4_get_slave_from_roce_gid()
1777 (vf_gids / num_vfs + 1)) in mlx4_get_slave_from_roce_gid()
[all …]
H A Dmlx4_eq.c167 for (i = 0; i <= dev->persist->num_vfs; i++) { in mlx4_gen_slave_eqe()
228 if (slave < 0 || slave > dev->persist->num_vfs || in mlx4_slave_event()
273 if (dev->persist->num_vfs < slave) in mlx4_gen_guid_change_eqe()
292 if (dev->persist->num_vfs < slave) in mlx4_gen_port_state_change_eqe()
347 for (i = 0; i < dev->persist->num_vfs + 1; i++) in set_all_slave_state()
602 for (i = 0; i < dev->persist->num_vfs + 1; in mlx4_eq_int()
645 i < dev->persist->num_vfs + 1; in mlx4_eq_int()
H A Dmlx4_main.c86 static uint8_t num_vfs[3] = {0, 0, 0}; variable
88 module_param_array(num_vfs, byte , &num_vfs_argc, 0444);
89 MODULE_PARM_DESC(num_vfs, "enable #num_vfs functions if num_vfs > 0\n"
1304 dev->persist->num_vfs + 1); in mlx4_mf_bond()
1307 if (bitmap_weight(slaves_port_1_2, dev->persist->num_vfs + 1) > 1) { in mlx4_mf_bond()
1315 nvfs = bitmap_weight(slaves_port1.slaves, dev->persist->num_vfs + 1) + in mlx4_mf_bond()
1316 bitmap_weight(slaves_port2.slaves, dev->persist->num_vfs + 1) - 2; in mlx4_mf_bond()
2106 (dev->persist->num_vfs + 1))) && in choose_steering_mode()
3147 dev->persist->num_vfs = total_vfs; in mlx4_enable_sriov()
3154 dev->persist->num_vfs = 0; in mlx4_enable_sriov()
[all …]
H A Dmlx4_cmd.c1955 int num_vfs; in mlx4_allocate_port_vpps() local
1968 num_vfs = (availible_vpp / in mlx4_allocate_port_vpps()
1973 vpp_param[i] = num_vfs; in mlx4_allocate_port_vpps()
1989 port_qos->num_of_qos_vfs = num_vfs; in mlx4_allocate_port_vpps()
2724 if ((vf < 0) || (vf >= dev->persist->num_vfs)) { in mlx4_get_slave_indx()
2726 vf, dev->persist->num_vfs); in mlx4_get_slave_indx()
2735 if (slave < 1 || slave > dev->persist->num_vfs) { in mlx4_get_vf_indx()
2826 for (i = 0; i < dev->persist->num_vfs + 1; i++) { in mlx4_phys_to_slaves_pport()
2846 for (i = 0; i < dev->persist->num_vfs + 1; i++) { in mlx4_phys_to_slaves_pport_actv()
H A Dmlx4_resource_tracker.c316 if (slave > dev->persist->num_vfs) in mlx4_grant_resource()
322 (dev->persist->num_vfs + 1) + slave] : in mlx4_grant_resource()
361 (dev->persist->num_vfs + 1) + slave] += count; in mlx4_grant_resource()
385 if (slave > dev->persist->num_vfs) in mlx4_release_resource()
392 (dev->persist->num_vfs + 1) + slave] : in mlx4_release_resource()
408 (dev->persist->num_vfs + 1) + slave] -= count; in mlx4_release_resource()
427 (2 * (dev->persist->num_vfs + 1)); in initialize_res_quotas()
508 res_alloc->quota = kmalloc((dev->persist->num_vfs + 1) * in mlx4_init_resource_tracker()
510 res_alloc->guaranteed = kmalloc((dev->persist->num_vfs + 1) * in mlx4_init_resource_tracker()
514 (dev->persist->num_vfs in mlx4_init_resource_tracker()
[all …]
/freebsd/sys/net/
H A Difdi_if.m98 null_iov_init(if_ctx_t _ctx __unused, uint16_t num_vfs __unused, const nvlist_t *params __unused)
104 null_vf_add(if_ctx_t _ctx __unused, uint16_t num_vfs __unused, const nvlist_t *params __unused)
268 uint16_t num_vfs;
278 uint16_t num_vfs;
/freebsd/sys/dev/ixl/
H A Dixl_pf_iov.c1407 for (i = 0; i < pf->num_vfs; i++) in ixl_broadcast_link_state()
1424 if (vf_num >= pf->num_vfs) { in ixl_handle_vf_msg()
1540 for (i = 0; i < pf->num_vfs; i++) { in ixl_handle_vflr()
1648 ixl_if_iov_init(if_ctx_t ctx, uint16_t num_vfs, const nvlist_t *params) in ixl_if_iov_init() argument
1660 pf->vfs = malloc(sizeof(struct ixl_vf) * num_vfs, M_IXL, M_NOWAIT | in ixl_if_iov_init()
1690 pf->num_vfs = num_vfs; in ixl_if_iov_init()
1705 int i, num_vfs; in ixl_if_iov_uninit() local
1709 for (i = 0; i < pf->num_vfs; i++) { in ixl_if_iov_uninit()
1728 num_vfs = pf->num_vfs; in ixl_if_iov_uninit()
1731 pf->num_vfs = 0; in ixl_if_iov_uninit()
[all …]
H A Dixl_pf_iov.h49 int ixl_if_iov_init(if_ctx_t ctx, uint16_t num_vfs, const nvlist_t *params);
H A Dixl_pf.h172 int num_vfs; member
/freebsd/sys/dev/bnxt/bnxt_en/
H A Dbnxt_ulp.h152 void bnxt_ulp_sriov_cfg(struct bnxt_softc *bp, int num_vfs);
H A Dbnxt_ulp.c273 void bnxt_ulp_sriov_cfg(struct bnxt_softc *bp, int num_vfs) in bnxt_ulp_sriov_cfg() argument
293 ops->ulp_sriov_config(ulp->handle, num_vfs); in bnxt_ulp_sriov_cfg()
/freebsd/sys/dev/mlx5/mlx5_core/
H A Dmlx5_main.c1412 int num_vfs, sriov_pos; in init_one() local
1720 num_vfs = pci_read_config(bsddev, sriov_pos + in init_one()
1724 num_vfs = 0; in init_one()
1726 err = mlx5_eswitch_init(dev, 1 + num_vfs); in init_one()
1910 mlx5_iov_init(device_t dev, uint16_t num_vfs, const nvlist_t *pf_config) in mlx5_iov_init() argument
1923 if (priv->eswitch->total_vports < num_vfs + 1) in mlx5_iov_init()
1924 num_vfs = priv->eswitch->total_vports - 1; in mlx5_iov_init()
1925 err = mlx5_eswitch_enable_sriov(priv->eswitch, num_vfs); in mlx5_iov_init()
/freebsd/sys/dev/qlnx/qlnxe/
H A Decore_sriov.c417 &iov->num_vfs); in ecore_iov_pci_cfg_info()
418 if (iov->num_vfs) { in ecore_iov_pci_cfg_info()
424 iov->num_vfs = 0; in ecore_iov_pci_cfg_info()
458 if (iov->num_vfs > NUM_OF_VFS(p_dev) || in ecore_iov_pci_cfg_info()
465 iov->num_vfs); in ecore_iov_pci_cfg_info()
467 iov->num_vfs = 0; in ecore_iov_pci_cfg_info()
536 u16 num_vfs = 0; in ecore_iov_allocate_vfdb() local
538 num_vfs = p_hwfn->p_dev->p_iov_info->total_vfs; in ecore_iov_allocate_vfdb()
541 "ecore_iov_allocate_vfdb for %d VFs\n", num_vfs); in ecore_iov_allocate_vfdb()
544 p_iov_info->mbx_msg_size = sizeof(union vfpf_tlvs) * num_vfs; in ecore_iov_allocate_vfdb()
[all …]
H A Dqlnx_os.c171 static int qlnx_iov_init(device_t dev, uint16_t num_vfs, const nvlist_t *params);
7992 qlnx_iov_init(device_t dev, uint16_t num_vfs, const nvlist_t *nvlist_params) in qlnx_iov_init() argument
8013 dev, num_vfs, max_vfs); in qlnx_iov_init()
8015 if (num_vfs >= max_vfs) { in qlnx_iov_init()
8021 ha->vf_attr = malloc(((sizeof (qlnx_vf_attr_t) * num_vfs)), M_QLNXBUF, in qlnx_iov_init()
8036 (FEAT_NUM(hwfn, ECORE_VF_L2_QUE) / num_vfs), in qlnx_iov_init()
8044 for (i = 0; i < num_vfs; i++) { in qlnx_iov_init()
8062 ha->num_vfs = num_vfs; in qlnx_iov_init()
8065 QL_DPRINT2(ha," dev = %p exit num_vfs = %d\n", dev, num_vfs); in qlnx_iov_init()
8074 ha->num_vfs = 0; in qlnx_iov_init()
[all …]
/freebsd/usr.sbin/pciconf/
H A Dcap.c1082 uint16_t iov_ctl, total_vfs, num_vfs, vf_offset, vf_stride, vf_did;
1095 num_vfs = read_config(fd, &p->pc_sel, ptr + PCIR_SRIOV_NUM_VFS, 2);
1097 printf("%d VFs configured out of %d supported\n", num_vfs, total_vfs);
967 uint16_t iov_ctl, total_vfs, num_vfs, vf_offset, vf_stride, vf_did; ecap_sriov() local
/freebsd/sys/dev/cxgbe/
H A Dt4_iov.c322 t4iov_iov_init(device_t dev, uint16_t num_vfs, const struct nvlist *config) in t4iov_iov_init() argument
/freebsd/sys/dev/mlx4/mlx4_ib/
H A Dmlx4_ib_alias_GUID.c221 if (slave_id >= dev->dev->persist->num_vfs + 1) in mlx4_ib_notify_slaves_on_guid_change()
594 if (!entry || entry > dev->dev->persist->num_vfs || in mlx4_ib_guid_port_init()
H A Dmlx4_ib_sysfs.c778 for (i = 0; i <= device->dev->persist->num_vfs; ++i) in register_pkey_tree()
793 for (slave = device->dev->persist->num_vfs; slave >= 0; --slave) { in unregister_pkey_tree()
/freebsd/sys/dev/vnic/
H A Dnic_main.c280 nicpf_iov_init(device_t dev, uint16_t num_vfs, const nvlist_t *params) in nicpf_iov_init() argument
286 if (num_vfs == 0) in nicpf_iov_init()

12