Home
last modified time | relevance | path

Searched refs:indir (Results 1 – 25 of 68) sorted by relevance

123

/Linux-v5.15/drivers/net/ethernet/mellanox/mlx5/core/en/
Drqt.c7 void mlx5e_rss_params_indir_init_uniform(struct mlx5e_rss_params_indir *indir, in mlx5e_rss_params_indir_init_uniform() argument
13 indir->table[i] = i % num_channels; in mlx5e_rss_params_indir_init_uniform()
67 u8 hfunc, struct mlx5e_rss_params_indir *indir) in mlx5e_calc_indir_rqns() argument
77 ix = indir->table[ix]; in mlx5e_calc_indir_rqns()
92 u8 hfunc, struct mlx5e_rss_params_indir *indir) in mlx5e_rqt_init_indir() argument
101 err = mlx5e_calc_indir_rqns(rss_rqns, rqns, num_rqns, hfunc, indir); in mlx5e_rqt_init_indir()
149 u8 hfunc, struct mlx5e_rss_params_indir *indir) in mlx5e_rqt_redirect_indir() argument
161 err = mlx5e_calc_indir_rqns(rss_rqns, rqns, num_rqns, hfunc, indir); in mlx5e_rqt_redirect_indir()
Drqt.h17 void mlx5e_rss_params_indir_init_uniform(struct mlx5e_rss_params_indir *indir,
30 u8 hfunc, struct mlx5e_rss_params_indir *indir);
40 u8 hfunc, struct mlx5e_rss_params_indir *indir);
Drss.c72 struct mlx5e_rss_params_indir indir; member
398 err = mlx5e_rqt_redirect_indir(&rss->rqt, rqns, num_rqns, rss->hash.hfunc, &rss->indir); in mlx5e_rss_apply()
469 int mlx5e_rss_get_rxfh(struct mlx5e_rss *rss, u32 *indir, u8 *key, u8 *hfunc) in mlx5e_rss_get_rxfh() argument
473 if (indir) in mlx5e_rss_get_rxfh()
475 indir[i] = rss->indir.table[i]; in mlx5e_rss_get_rxfh()
487 int mlx5e_rss_set_rxfh(struct mlx5e_rss *rss, const u32 *indir, in mlx5e_rss_set_rxfh() argument
514 if (indir) { in mlx5e_rss_set_rxfh()
520 rss->indir.table[i] = indir[i]; in mlx5e_rss_set_rxfh()
587 mlx5e_rss_params_indir_init_uniform(&rss->indir, nch); in mlx5e_rss_set_indir_uniform()
Drss.h40 int mlx5e_rss_get_rxfh(struct mlx5e_rss *rss, u32 *indir, u8 *key, u8 *hfunc);
41 int mlx5e_rss_set_rxfh(struct mlx5e_rss *rss, const u32 *indir,
Drx_res.h53 u32 *indir, u8 *key, u8 *hfunc);
55 const u32 *indir, const u8 *key, const u8 *hfunc);
/Linux-v5.15/drivers/net/ethernet/mellanox/mlx5/core/esw/
Dindir_table.c56 struct mlx5_esw_indir_table *indir = kvzalloc(sizeof(*indir), GFP_KERNEL); in mlx5_esw_indir_table_init() local
58 if (!indir) in mlx5_esw_indir_table_init()
61 mutex_init(&indir->lock); in mlx5_esw_indir_table_init()
62 hash_init(indir->table); in mlx5_esw_indir_table_init()
63 return indir; in mlx5_esw_indir_table_init()
67 mlx5_esw_indir_table_destroy(struct mlx5_esw_indir_table *indir) in mlx5_esw_indir_table_destroy() argument
69 mutex_destroy(&indir->lock); in mlx5_esw_indir_table_destroy()
70 kvfree(indir); in mlx5_esw_indir_table_destroy()
427 hash_add(esw->fdb_table.offloads.indir->table, &e->hlist, in mlx5_esw_indir_table_entry_create()
450 hash_for_each_possible(esw->fdb_table.offloads.indir->table, e, hlist, key) in mlx5_esw_indir_table_entry_lookup()
[all …]
Dindir_table.h12 mlx5_esw_indir_table_destroy(struct mlx5_esw_indir_table *indir);
40 mlx5_esw_indir_table_destroy(struct mlx5_esw_indir_table *indir) in mlx5_esw_indir_table_destroy() argument
/Linux-v5.15/drivers/net/ethernet/microsoft/mana/
Dmana_ethtool.c127 static int mana_get_rxfh(struct net_device *ndev, u32 *indir, u8 *key, in mana_get_rxfh() argument
136 if (indir) { in mana_get_rxfh()
138 indir[i] = apc->indir_table[i]; in mana_get_rxfh()
147 static int mana_set_rxfh(struct net_device *ndev, const u32 *indir, in mana_set_rxfh() argument
162 if (indir) { in mana_set_rxfh()
164 if (indir[i] >= apc->num_queues) in mana_set_rxfh()
170 apc->indir_table[i] = indir[i]; in mana_set_rxfh()
/Linux-v5.15/drivers/net/ethernet/sfc/
Dethtool_common.h47 int efx_ethtool_get_rxfh(struct net_device *net_dev, u32 *indir, u8 *key,
50 const u32 *indir, const u8 *key, const u8 hfunc);
51 int efx_ethtool_get_rxfh_context(struct net_device *net_dev, u32 *indir,
54 const u32 *indir, const u8 *key,
Dethtool_common.c1171 int efx_ethtool_get_rxfh(struct net_device *net_dev, u32 *indir, u8 *key, in efx_ethtool_get_rxfh() argument
1183 if (indir) in efx_ethtool_get_rxfh()
1184 memcpy(indir, efx->rss_context.rx_indir_table, in efx_ethtool_get_rxfh()
1192 int efx_ethtool_set_rxfh(struct net_device *net_dev, const u32 *indir, in efx_ethtool_set_rxfh() argument
1200 if (!indir && !key) in efx_ethtool_set_rxfh()
1205 if (!indir) in efx_ethtool_set_rxfh()
1206 indir = efx->rss_context.rx_indir_table; in efx_ethtool_set_rxfh()
1208 return efx->type->rx_push_rss_config(efx, true, indir, key); in efx_ethtool_set_rxfh()
1211 int efx_ethtool_get_rxfh_context(struct net_device *net_dev, u32 *indir, in efx_ethtool_get_rxfh_context() argument
1233 if (indir) in efx_ethtool_get_rxfh_context()
[all …]
/Linux-v5.15/drivers/net/ethernet/microchip/
Dlan743x_ethtool.c575 u32 *indir, u8 *key, u8 *hfunc) in lan743x_ethtool_get_rxfh() argument
579 if (indir) { in lan743x_ethtool_get_rxfh()
588 indir[byte_index + 0] = in lan743x_ethtool_get_rxfh()
590 indir[byte_index + 1] = in lan743x_ethtool_get_rxfh()
592 indir[byte_index + 2] = in lan743x_ethtool_get_rxfh()
594 indir[byte_index + 3] = in lan743x_ethtool_get_rxfh()
624 const u32 *indir, const u8 *key, in lan743x_ethtool_set_rxfh() argument
632 if (indir) { in lan743x_ethtool_set_rxfh()
640 (((indir[byte_index + 0] & 0x000000FF) << 0) | in lan743x_ethtool_set_rxfh()
641 ((indir[byte_index + 1] & 0x000000FF) << 8) | in lan743x_ethtool_set_rxfh()
[all …]
/Linux-v5.15/fs/freevxfs/
Dvxfs_bmap.c89 __fs32 *indir; in vxfs_bmap_ext4() local
96 indir = (__fs32 *)buf->b_data; in vxfs_bmap_ext4()
97 bno = fs32_to_cpu(sbi, indir[(bn / indsize) % (indsize * bn)]) + in vxfs_bmap_ext4()
131 vxfs_bmap_indir(struct inode *ip, long indir, int size, long block) in vxfs_bmap_indir() argument
143 indir + (i / VXFS_TYPED_PER_BLOCK(ip->i_sb))); in vxfs_bmap_indir()
/Linux-v5.15/drivers/net/ethernet/intel/fm10k/
Dfm10k_ethtool.c974 void fm10k_write_reta(struct fm10k_intfc *interface, const u32 *indir) in fm10k_write_reta() argument
987 if (indir) in fm10k_write_reta()
988 n = indir[4 * i + j]; in fm10k_write_reta()
1009 static int fm10k_get_reta(struct net_device *netdev, u32 *indir) in fm10k_get_reta() argument
1014 if (!indir) in fm10k_get_reta()
1017 for (i = 0; i < FM10K_RETA_SIZE; i++, indir += 4) { in fm10k_get_reta()
1020 indir[0] = (reta << 24) >> 24; in fm10k_get_reta()
1021 indir[1] = (reta << 16) >> 24; in fm10k_get_reta()
1022 indir[2] = (reta << 8) >> 24; in fm10k_get_reta()
1023 indir[3] = (reta) >> 24; in fm10k_get_reta()
[all …]
/Linux-v5.15/drivers/net/ethernet/amazon/ena/
Dena_ethtool.c695 const u32 *indir) in ena_indirection_table_set() argument
703 ENA_IO_RXQ_IDX(indir[i])); in ena_indirection_table_set()
720 static int ena_indirection_table_get(struct ena_adapter *adapter, u32 *indir) in ena_indirection_table_get() argument
725 if (!indir) in ena_indirection_table_get()
728 rc = ena_com_indirect_table_get(ena_dev, indir); in ena_indirection_table_get()
737 indir[i] = ENA_IO_RXQ_IDX_TO_COMBINED_IDX(indir[i]); in ena_indirection_table_get()
742 static int ena_get_rxfh(struct net_device *netdev, u32 *indir, u8 *key, in ena_get_rxfh() argument
750 rc = ena_indirection_table_get(adapter, indir); in ena_get_rxfh()
788 static int ena_set_rxfh(struct net_device *netdev, const u32 *indir, in ena_set_rxfh() argument
796 if (indir) { in ena_set_rxfh()
[all …]
/Linux-v5.15/net/ethtool/
Dioctl.c1019 static int ethtool_copy_validate_indir(u32 *indir, void __user *useraddr, in ethtool_copy_validate_indir() argument
1025 if (copy_from_user(indir, useraddr, size * sizeof(indir[0]))) in ethtool_copy_validate_indir()
1030 if (indir[i] >= rx_rings->data) in ethtool_copy_validate_indir()
1050 u32 *indir; in ethtool_get_rxfh_indir() local
1076 indir = kcalloc(dev_size, sizeof(indir[0]), GFP_USER); in ethtool_get_rxfh_indir()
1077 if (!indir) in ethtool_get_rxfh_indir()
1080 ret = dev->ethtool_ops->get_rxfh(dev, indir, NULL, NULL); in ethtool_get_rxfh_indir()
1086 indir, dev_size * sizeof(indir[0]))) in ethtool_get_rxfh_indir()
1090 kfree(indir); in ethtool_get_rxfh_indir()
1099 u32 *indir; in ethtool_set_rxfh_indir() local
[all …]
Dcommon.c500 u32 *indir; in ethtool_get_max_rxfh_channel() local
510 indir = kcalloc(dev_size, sizeof(indir[0]), GFP_USER); in ethtool_get_max_rxfh_channel()
511 if (!indir) in ethtool_get_max_rxfh_channel()
514 ret = dev->ethtool_ops->get_rxfh(dev, indir, NULL, NULL); in ethtool_get_max_rxfh_channel()
519 current_max = max(current_max, indir[dev_size]); in ethtool_get_max_rxfh_channel()
524 kfree(indir); in ethtool_get_max_rxfh_channel()
/Linux-v5.15/drivers/net/dsa/
Dbcm_sf2.h152 u32 indir, dir; \
155 indir = reg_readl(priv, REG_DIR_DATA_READ); \
157 return (u64)indir << 32 | dir; \
/Linux-v5.15/drivers/net/ethernet/marvell/octeontx2/nic/
Dotx2_ethtool.c750 static int otx2_set_rxfh_context(struct net_device *dev, const u32 *indir, in otx2_set_rxfh_context() argument
785 if (indir) { in otx2_set_rxfh_context()
788 rss_ctx->ind_tbl[idx] = indir[idx]; in otx2_set_rxfh_context()
795 static int otx2_get_rxfh_context(struct net_device *dev, u32 *indir, in otx2_get_rxfh_context() argument
808 if (!indir) in otx2_get_rxfh_context()
814 indir[idx] = ethtool_rxfh_indir_default(idx, rx_queues); in otx2_get_rxfh_context()
824 if (indir) { in otx2_get_rxfh_context()
826 indir[idx] = rss_ctx->ind_tbl[idx]; in otx2_get_rxfh_context()
835 static int otx2_get_rxfh(struct net_device *dev, u32 *indir, in otx2_get_rxfh() argument
838 return otx2_get_rxfh_context(dev, indir, hkey, hfunc, in otx2_get_rxfh()
[all …]
/Linux-v5.15/include/linux/
Dethtool.h650 int (*get_rxfh)(struct net_device *, u32 *indir, u8 *key,
652 int (*set_rxfh)(struct net_device *, const u32 *indir,
654 int (*get_rxfh_context)(struct net_device *, u32 *indir, u8 *key,
656 int (*set_rxfh_context)(struct net_device *, const u32 *indir,
/Linux-v5.15/drivers/net/ethernet/hisilicon/hns/
Dhns_ae_adapt.c888 static int hns_ae_get_rss(struct hnae_handle *handle, u32 *indir, u8 *key, in hns_ae_get_rss() argument
902 if (indir) in hns_ae_get_rss()
903 memcpy(indir, ppe_cb->rss_indir_table, in hns_ae_get_rss()
904 HNS_PPEV2_RSS_IND_TBL_SIZE * sizeof(*indir)); in hns_ae_get_rss()
909 static int hns_ae_set_rss(struct hnae_handle *handle, const u32 *indir, in hns_ae_set_rss() argument
920 if (indir) { in hns_ae_set_rss()
922 memcpy(ppe_cb->rss_indir_table, indir, in hns_ae_set_rss()
923 HNS_PPEV2_RSS_IND_TBL_SIZE * sizeof(*indir)); in hns_ae_set_rss()
/Linux-v5.15/drivers/net/ethernet/amd/xgbe/
Dxgbe-ethtool.c527 static int xgbe_get_rxfh(struct net_device *netdev, u32 *indir, u8 *key, in xgbe_get_rxfh() argument
533 if (indir) { in xgbe_get_rxfh()
535 indir[i] = XGMAC_GET_BITS(pdata->rss_table[i], in xgbe_get_rxfh()
548 static int xgbe_set_rxfh(struct net_device *netdev, const u32 *indir, in xgbe_set_rxfh() argument
560 if (indir) { in xgbe_set_rxfh()
561 ret = hw_if->set_rss_lookup_table(pdata, indir); in xgbe_set_rxfh()
/Linux-v5.15/drivers/net/ethernet/freescale/enetc/
Denetc_ethtool.c515 static int enetc_get_rxfh(struct net_device *ndev, u32 *indir, u8 *key, in enetc_get_rxfh() argument
532 if (indir) in enetc_get_rxfh()
533 err = enetc_get_rss_table(priv->si, indir, priv->si->num_rss); in enetc_get_rxfh()
546 static int enetc_set_rxfh(struct net_device *ndev, const u32 *indir, in enetc_set_rxfh() argument
558 if (indir) in enetc_set_rxfh()
559 err = enetc_set_rss_table(priv->si, indir, priv->si->num_rss); in enetc_set_rxfh()
/Linux-v5.15/drivers/net/ethernet/aquantia/atlantic/
Daq_ethtool.c440 static int aq_ethtool_get_rss(struct net_device *ndev, u32 *indir, u8 *key, in aq_ethtool_get_rss() argument
451 if (indir) { in aq_ethtool_get_rss()
453 indir[i] = cfg->aq_rss.indirection_table[i]; in aq_ethtool_get_rss()
462 static int aq_ethtool_set_rss(struct net_device *netdev, const u32 *indir, in aq_ethtool_set_rss() argument
478 if (indir) in aq_ethtool_set_rss()
480 cfg->aq_rss.indirection_table[i] = indir[i]; in aq_ethtool_set_rss()
/Linux-v5.15/drivers/net/ethernet/marvell/mvpp2/
Dmvpp2_cls.c1482 mvpp22_rxfh_indir(port, table->indir[i])); in mvpp22_rss_fill_table()
1592 const u32 *indir) in mvpp22_port_rss_ctx_indir_set() argument
1601 memcpy(rss_table->indir, indir, in mvpp22_port_rss_ctx_indir_set()
1602 MVPP22_RSS_TABLE_ENTRIES * sizeof(rss_table->indir[0])); in mvpp22_port_rss_ctx_indir_set()
1610 u32 *indir) in mvpp22_port_rss_ctx_indir_get() argument
1619 memcpy(indir, rss_table->indir, in mvpp22_port_rss_ctx_indir_get()
1620 MVPP22_RSS_TABLE_ENTRIES * sizeof(rss_table->indir[0])); in mvpp22_port_rss_ctx_indir_get()
1729 table->indir[i] = ethtool_rxfh_indir_default(i, port->nrxqs); in mvpp22_port_rss_init()
/Linux-v5.15/drivers/net/ethernet/cavium/thunder/
Dnicvf_ethtool.c652 static int nicvf_get_rxfh(struct net_device *dev, u32 *indir, u8 *hkey, in nicvf_get_rxfh() argument
659 if (indir) { in nicvf_get_rxfh()
661 indir[idx] = rss->ind_tbl[idx]; in nicvf_get_rxfh()
673 static int nicvf_set_rxfh(struct net_device *dev, const u32 *indir, in nicvf_set_rxfh() argument
689 if (indir) { in nicvf_set_rxfh()
691 rss->ind_tbl[idx] = indir[idx]; in nicvf_set_rxfh()

123