Home
last modified time | relevance | path

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

123

/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()
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()
470 int mlx5e_rss_get_rxfh(struct mlx5e_rss *rss, u32 *indir, u8 *key, u8 *hfunc) in mlx5e_rss_get_rxfh() argument
474 if (indir) in mlx5e_rss_get_rxfh()
476 indir[i] = rss->indir.table[i]; in mlx5e_rss_get_rxfh()
488 int mlx5e_rss_set_rxfh(struct mlx5e_rss *rss, const u32 *indir, in mlx5e_rss_set_rxfh() argument
515 if (indir) { in mlx5e_rss_set_rxfh()
521 rss->indir.table[i] = indir[i]; in mlx5e_rss_set_rxfh()
588 mlx5e_rss_params_indir_init_uniform(&rss->indir, nch); in mlx5e_rss_set_indir_uniform()
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.h41 int mlx5e_rss_get_rxfh(struct mlx5e_rss *rss, u32 *indir, u8 *key, u8 *hfunc);
42 int mlx5e_rss_set_rxfh(struct mlx5e_rss *rss, const u32 *indir,
Drx_res.h50 u32 *indir, u8 *key, u8 *hfunc);
52 const u32 *indir, const u8 *key, const u8 *hfunc);
Drx_res.c195 u32 *indir, u8 *key, u8 *hfunc) in mlx5e_rx_res_rss_get_rxfh() argument
206 return mlx5e_rss_get_rxfh(rss, indir, key, hfunc); in mlx5e_rx_res_rss_get_rxfh()
210 const u32 *indir, const u8 *key, const u8 *hfunc) in mlx5e_rx_res_rss_set_rxfh() argument
221 return mlx5e_rss_set_rxfh(rss, indir, key, hfunc, res->rss_rqns, res->rss_nch); in mlx5e_rx_res_rss_set_rxfh()
/drivers/net/ethernet/mellanox/mlx5/core/esw/
Dindir_table.c57 struct mlx5_esw_indir_table *indir = kvzalloc(sizeof(*indir), GFP_KERNEL); in mlx5_esw_indir_table_init() local
59 if (!indir) in mlx5_esw_indir_table_init()
62 mutex_init(&indir->lock); in mlx5_esw_indir_table_init()
63 hash_init(indir->table); in mlx5_esw_indir_table_init()
64 return indir; in mlx5_esw_indir_table_init()
68 mlx5_esw_indir_table_destroy(struct mlx5_esw_indir_table *indir) in mlx5_esw_indir_table_destroy() argument
70 mutex_destroy(&indir->lock); in mlx5_esw_indir_table_destroy()
71 kvfree(indir); in mlx5_esw_indir_table_destroy()
428 hash_add(esw->fdb_table.offloads.indir->table, &e->hlist, in mlx5_esw_indir_table_entry_create()
451 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
/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()
/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.c1165 int efx_ethtool_get_rxfh(struct net_device *net_dev, u32 *indir, u8 *key, in efx_ethtool_get_rxfh() argument
1177 if (indir) in efx_ethtool_get_rxfh()
1178 memcpy(indir, efx->rss_context.rx_indir_table, in efx_ethtool_get_rxfh()
1186 int efx_ethtool_set_rxfh(struct net_device *net_dev, const u32 *indir, in efx_ethtool_set_rxfh() argument
1194 if (!indir && !key) in efx_ethtool_set_rxfh()
1199 if (!indir) in efx_ethtool_set_rxfh()
1200 indir = efx->rss_context.rx_indir_table; in efx_ethtool_set_rxfh()
1202 return efx->type->rx_push_rss_config(efx, true, indir, key); in efx_ethtool_set_rxfh()
1205 int efx_ethtool_get_rxfh_context(struct net_device *net_dev, u32 *indir, in efx_ethtool_get_rxfh_context() argument
1227 if (indir) in efx_ethtool_get_rxfh_context()
[all …]
/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 …]
/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 …]
/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 …]
/drivers/net/ethernet/marvell/octeontx2/nic/
Dotx2_ethtool.c754 static int otx2_set_rxfh_context(struct net_device *dev, const u32 *indir, in otx2_set_rxfh_context() argument
789 if (indir) { in otx2_set_rxfh_context()
792 rss_ctx->ind_tbl[idx] = indir[idx]; in otx2_set_rxfh_context()
799 static int otx2_get_rxfh_context(struct net_device *dev, u32 *indir, in otx2_get_rxfh_context() argument
812 if (!indir) in otx2_get_rxfh_context()
818 indir[idx] = ethtool_rxfh_indir_default(idx, rx_queues); in otx2_get_rxfh_context()
828 if (indir) { in otx2_get_rxfh_context()
830 indir[idx] = rss_ctx->ind_tbl[idx]; in otx2_get_rxfh_context()
839 static int otx2_get_rxfh(struct net_device *dev, u32 *indir, in otx2_get_rxfh() argument
842 return otx2_get_rxfh_context(dev, indir, hkey, hfunc, in otx2_get_rxfh()
[all …]
/drivers/net/dsa/
Dbcm_sf2.h152 u32 indir, dir; \
155 indir = reg_readl(priv, REG_DIR_DATA_READ); \
157 return (u64)indir << 32 | dir; \
/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()
/drivers/net/ethernet/amd/xgbe/
Dxgbe-ethtool.c532 static int xgbe_get_rxfh(struct net_device *netdev, u32 *indir, u8 *key, in xgbe_get_rxfh() argument
538 if (indir) { in xgbe_get_rxfh()
540 indir[i] = XGMAC_GET_BITS(pdata->rss_table[i], in xgbe_get_rxfh()
553 static int xgbe_set_rxfh(struct net_device *netdev, const u32 *indir, in xgbe_set_rxfh() argument
565 if (indir) { in xgbe_set_rxfh()
566 ret = hw_if->set_rss_lookup_table(pdata, indir); in xgbe_set_rxfh()
/drivers/net/ethernet/aquantia/atlantic/
Daq_ethtool.c441 static int aq_ethtool_get_rss(struct net_device *ndev, u32 *indir, u8 *key, in aq_ethtool_get_rss() argument
452 if (indir) { in aq_ethtool_get_rss()
454 indir[i] = cfg->aq_rss.indirection_table[i]; in aq_ethtool_get_rss()
463 static int aq_ethtool_set_rss(struct net_device *netdev, const u32 *indir, in aq_ethtool_set_rss() argument
479 if (indir) in aq_ethtool_set_rss()
481 cfg->aq_rss.indirection_table[i] = indir[i]; in aq_ethtool_set_rss()
/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()
/drivers/net/ethernet/marvell/mvpp2/
Dmvpp2_cls.c1488 mvpp22_rxfh_indir(port, table->indir[i])); in mvpp22_rss_fill_table()
1598 const u32 *indir) in mvpp22_port_rss_ctx_indir_set() argument
1607 memcpy(rss_table->indir, indir, in mvpp22_port_rss_ctx_indir_set()
1608 MVPP22_RSS_TABLE_ENTRIES * sizeof(rss_table->indir[0])); in mvpp22_port_rss_ctx_indir_set()
1616 u32 *indir) in mvpp22_port_rss_ctx_indir_get() argument
1625 memcpy(indir, rss_table->indir, in mvpp22_port_rss_ctx_indir_get()
1626 MVPP22_RSS_TABLE_ENTRIES * sizeof(rss_table->indir[0])); in mvpp22_port_rss_ctx_indir_get()
1735 table->indir[i] = ethtool_rxfh_indir_default(i, port->nrxqs); in mvpp22_port_rss_init()
Dmvpp2_cls.h271 const u32 *indir);
273 u32 *indir);
/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()
/drivers/net/ethernet/intel/ixgbevf/
Dethtool.c900 static int ixgbevf_get_rxfh(struct net_device *netdev, u32 *indir, u8 *key, in ixgbevf_get_rxfh() argument
914 if (indir) { in ixgbevf_get_rxfh()
918 indir[i] = adapter->rss_indir_tbl[i]; in ixgbevf_get_rxfh()
924 if (!indir && !key) in ixgbevf_get_rxfh()
928 if (indir) in ixgbevf_get_rxfh()
929 err = ixgbevf_get_reta_locked(&adapter->hw, indir, in ixgbevf_get_rxfh()
/drivers/net/ethernet/huawei/hinic/
Dhinic_ethtool.c1057 const u32 *indir, const u8 *key) in __set_rss_rxfh() argument
1062 if (indir) { in __set_rss_rxfh()
1071 memcpy(nic_dev->rss_indir_user, indir, in __set_rss_rxfh()
1075 nic_dev->rss_tmpl_idx, indir); in __set_rss_rxfh()
1139 u32 *indir, u8 *key, u8 *hfunc) in hinic_get_rxfh() argument
1158 if (indir) { in hinic_get_rxfh()
1160 nic_dev->rss_tmpl_idx, indir); in hinic_get_rxfh()
1172 static int hinic_set_rxfh(struct net_device *netdev, const u32 *indir, in hinic_set_rxfh() argument
1195 err = __set_rss_rxfh(netdev, indir, key); in hinic_set_rxfh()

123