net/bnxt: integrate with the latest TF core changes
ULP changes to integrate with the latest session open interface in tf_core Signed-off-by: Kishore Padmanabha <kishore.padmanabha@broadcom.com> Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com> Signed-off-by: Venkat Duvvuru <venkatkumar.duvvuru@broadcom.com> Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
This commit is contained in:
parent
b2da02480c
commit
c828d590f7
@ -68,6 +68,7 @@ ulp_ctx_session_open(struct bnxt *bp,
|
||||
struct rte_eth_dev *ethdev = bp->eth_dev;
|
||||
int32_t rc = 0;
|
||||
struct tf_open_session_parms params;
|
||||
struct tf_session_resources *resources;
|
||||
|
||||
memset(¶ms, 0, sizeof(params));
|
||||
|
||||
@ -79,6 +80,51 @@ ulp_ctx_session_open(struct bnxt *bp,
|
||||
return rc;
|
||||
}
|
||||
|
||||
params.shadow_copy = false;
|
||||
params.device_type = TF_DEVICE_TYPE_WH;
|
||||
resources = ¶ms.resources;
|
||||
/** RX **/
|
||||
/* Identifiers */
|
||||
resources->ident_cnt[TF_DIR_RX].cnt[TF_IDENT_TYPE_L2_CTXT] = 16;
|
||||
resources->ident_cnt[TF_DIR_RX].cnt[TF_IDENT_TYPE_WC_PROF] = 8;
|
||||
resources->ident_cnt[TF_DIR_RX].cnt[TF_IDENT_TYPE_PROF_FUNC] = 8;
|
||||
resources->ident_cnt[TF_DIR_RX].cnt[TF_IDENT_TYPE_EM_PROF] = 8;
|
||||
|
||||
/* Table Types */
|
||||
resources->tbl_cnt[TF_DIR_RX].cnt[TF_TBL_TYPE_FULL_ACT_RECORD] = 720;
|
||||
resources->tbl_cnt[TF_DIR_RX].cnt[TF_TBL_TYPE_ACT_STATS_64] = 720;
|
||||
|
||||
/* TCAMs */
|
||||
resources->tcam_cnt[TF_DIR_RX].cnt[TF_TCAM_TBL_TYPE_L2_CTXT_TCAM] = 16;
|
||||
resources->tcam_cnt[TF_DIR_RX].cnt[TF_TCAM_TBL_TYPE_PROF_TCAM] = 8;
|
||||
resources->tcam_cnt[TF_DIR_RX].cnt[TF_TCAM_TBL_TYPE_WC_TCAM] = 416;
|
||||
|
||||
/* EM */
|
||||
resources->em_cnt[TF_DIR_RX].cnt[TF_EM_TBL_TYPE_EM_RECORD] = 2048;
|
||||
|
||||
/** TX **/
|
||||
/* Identifiers */
|
||||
resources->ident_cnt[TF_DIR_TX].cnt[TF_IDENT_TYPE_L2_CTXT] = 8;
|
||||
resources->ident_cnt[TF_DIR_TX].cnt[TF_IDENT_TYPE_WC_PROF] = 8;
|
||||
resources->ident_cnt[TF_DIR_TX].cnt[TF_IDENT_TYPE_PROF_FUNC] = 8;
|
||||
resources->ident_cnt[TF_DIR_TX].cnt[TF_IDENT_TYPE_EM_PROF] = 8;
|
||||
|
||||
/* Table Types */
|
||||
resources->tbl_cnt[TF_DIR_TX].cnt[TF_TBL_TYPE_FULL_ACT_RECORD] = 16;
|
||||
resources->tbl_cnt[TF_DIR_TX].cnt[TF_TBL_TYPE_ACT_STATS_64] = 16;
|
||||
|
||||
/* TCAMs */
|
||||
resources->tcam_cnt[TF_DIR_TX].cnt[TF_TCAM_TBL_TYPE_L2_CTXT_TCAM] = 8;
|
||||
resources->tcam_cnt[TF_DIR_TX].cnt[TF_TCAM_TBL_TYPE_PROF_TCAM] = 8;
|
||||
resources->tcam_cnt[TF_DIR_TX].cnt[TF_TCAM_TBL_TYPE_WC_TCAM] = 8;
|
||||
|
||||
/* EM */
|
||||
resources->em_cnt[TF_DIR_TX].cnt[TF_EM_TBL_TYPE_EM_RECORD] = 8;
|
||||
|
||||
/* EEM */
|
||||
resources->em_cnt[TF_DIR_RX].cnt[TF_EM_TBL_TYPE_TBL_SCOPE] = 1;
|
||||
resources->em_cnt[TF_DIR_TX].cnt[TF_EM_TBL_TYPE_TBL_SCOPE] = 1;
|
||||
|
||||
rc = tf_open_session(&bp->tfp, ¶ms);
|
||||
if (rc) {
|
||||
BNXT_TF_DBG(ERR, "Failed to open TF session - %s, rc = %d\n",
|
||||
|
Loading…
Reference in New Issue
Block a user