uint32_t num_idents;
uint32_t i;
- /*
- * Since the cache entry is responsible for allocating
- * identifiers when in use, allocate the identifiers only
- * during normal processing.
- */
- if (parms->tcam_tbl_opc ==
- BNXT_ULP_MAPPER_TCAM_TBL_OPC_NORMAL) {
- idents = ulp_mapper_ident_fields_get(parms, tbl, &num_idents);
-
- for (i = 0; i < num_idents; i++) {
- if (ulp_mapper_ident_process(parms, tbl,
- &idents[i], NULL))
- return -EINVAL;
- }
+ idents = ulp_mapper_ident_fields_get(parms, tbl, &num_idents);
+ for (i = 0; i < num_idents; i++) {
+ if (ulp_mapper_ident_process(parms, tbl,
+ &idents[i], NULL))
+ return -EINVAL;
}
return 0;
}
struct tf_search_tcam_entry_parms searchparms = { 0 };
struct ulp_flow_db_res_params fid_parms = { 0 };
struct tf_free_tcam_entry_parms free_parms = { 0 };
- enum bnxt_ulp_search_before_alloc search_flag;
uint32_t hit = 0;
uint16_t tmplen = 0;
uint16_t idx;
- /* Skip this if was handled by the cache. */
- if (parms->tcam_tbl_opc == BNXT_ULP_MAPPER_TCAM_TBL_OPC_CACHE_SKIP) {
- parms->tcam_tbl_opc = BNXT_ULP_MAPPER_TCAM_TBL_OPC_NORMAL;
+ /* Skip this if table opcode is NOP */
+ if (tbl->tbl_opcode == BNXT_ULP_TCAM_TBL_OPC_NOT_USED ||
+ tbl->tbl_opcode >= BNXT_ULP_TCAM_TBL_OPC_LAST) {
+ BNXT_TF_DBG(ERR, "Invalid tcam table opcode %d\n",
+ tbl->tbl_opcode);
return 0;
}
}
}
+ /* For wild card tcam perform the post process to swap the blob */
if (tbl->resource_type == TF_TCAM_TBL_TYPE_WC_TCAM) {
ulp_mapper_wc_tcam_tbl_post_process(&key, tbl->key_bit_size);
ulp_mapper_wc_tcam_tbl_post_process(&mask, tbl->key_bit_size);
}
- if (tbl->srch_b4_alloc == BNXT_ULP_SEARCH_BEFORE_ALLOC_NO) {
- /*
- * No search for re-use is requested, so simply allocate the
- * tcam index.
- */
- aparms.dir = tbl->direction;
- aparms.tcam_tbl_type = tbl->resource_type;
- aparms.search_enable = tbl->srch_b4_alloc;
- aparms.key = ulp_blob_data_get(&key, &tmplen);
- aparms.key_sz_in_bits = tmplen;
+ if (tbl->tbl_opcode == BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE) {
+ /* allocate the tcam index */
+ aparms.dir = tbl->direction;
+ aparms.tcam_tbl_type = tbl->resource_type;
+ aparms.key = ulp_blob_data_get(&key, &tmplen);
+ aparms.key_sz_in_bits = tmplen;
if (tbl->blob_key_bit_size != tmplen) {
BNXT_TF_DBG(ERR, "Key len (%d) != Expected (%d)\n",
tmplen, tbl->blob_key_bit_size);
return -EINVAL;
}
- aparms.mask = ulp_blob_data_get(&mask, &tmplen);
+ aparms.mask = ulp_blob_data_get(&mask, &tmplen);
if (tbl->blob_key_bit_size != tmplen) {
BNXT_TF_DBG(ERR, "Mask len (%d) != Expected (%d)\n",
tmplen, tbl->blob_key_bit_size);
return -EINVAL;
}
-
- aparms.priority = tbl->priority;
-
- /*
- * All failures after this succeeds require the entry to be
- * freed. cannot return directly on failure, but needs to goto
- * error.
- */
+ aparms.priority = tbl->priority;
rc = tf_alloc_tcam_entry(tfp, &aparms);
if (rc) {
BNXT_TF_DBG(ERR, "tcam alloc failed rc=%d.\n", rc);
hit = searchparms.hit;
}
- /* if it is miss then it is same as no search before alloc */
- if (!hit)
- search_flag = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO;
- else
- search_flag = tbl->srch_b4_alloc;
+ /* Write the tcam index into the regfile*/
+ if (!ulp_regfile_write(parms->regfile, tbl->tbl_operand,
+ (uint64_t)tfp_cpu_to_be_64(idx))) {
+ BNXT_TF_DBG(ERR, "Regfile[%d] write failed.\n",
+ tbl->tbl_operand);
+ rc = -EINVAL;
+ /* Need to free the tcam idx, so goto error */
+ goto error;
+ }
- switch (search_flag) {
- case BNXT_ULP_SEARCH_BEFORE_ALLOC_NO:
+ /* if it is miss then it is same as no search before alloc */
+ if (!hit || tbl->tbl_opcode == BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE) {
/*Scan identifier list, allocate identifier and update regfile*/
rc = ulp_mapper_tcam_tbl_scan_ident_alloc(parms, tbl);
/* Create the result blob */
if (!rc)
rc = ulp_mapper_tcam_tbl_entry_write(parms, tbl, &key,
&mask, &data, idx);
- break;
- case BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP:
- /*Scan identifier list, extract identifier and update regfile*/
- rc = ulp_mapper_tcam_tbl_scan_ident_extract(parms, tbl, &data);
- break;
- case BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_UPDATE:
+ } else {
/*Scan identifier list, extract identifier and update regfile*/
rc = ulp_mapper_tcam_tbl_scan_ident_extract(parms, tbl, &data);
- /* Create the result blob */
- if (!rc)
- rc = ulp_mapper_tcam_tbl_result_create(parms, tbl,
- &update_data);
- /* Update/overwrite the tcam entry */
- if (!rc)
- rc = ulp_mapper_tcam_tbl_entry_write(parms, tbl, &key,
- &mask,
- &update_data, idx);
- break;
- default:
- BNXT_TF_DBG(ERR, "invalid search opcode\n");
- rc = -EINVAL;
- break;
}
if (rc)
goto error;
- /*
- * Only link the entry to the flow db in the event that cache was not
- * used.
- */
- if (parms->tcam_tbl_opc == BNXT_ULP_MAPPER_TCAM_TBL_OPC_NORMAL) {
- fid_parms.direction = tbl->direction;
- fid_parms.resource_func = tbl->resource_func;
- fid_parms.resource_type = tbl->resource_type;
- fid_parms.critical_resource = tbl->critical_resource;
- fid_parms.resource_hndl = idx;
- rc = ulp_mapper_fdb_opc_process(parms, tbl, &fid_parms);
- if (rc) {
- BNXT_TF_DBG(ERR,
- "Failed to link resource to flow rc = %d\n",
- rc);
- /* Need to free the identifier, so goto error */
- goto error;
- }
- } else {
- /*
- * Reset the tcam table opcode to normal in case the next tcam
- * entry does not use cache.
- */
- parms->tcam_tbl_opc = BNXT_ULP_MAPPER_TCAM_TBL_OPC_NORMAL;
+
+ /* Add the tcam index to the flow database */
+ fid_parms.direction = tbl->direction;
+ fid_parms.resource_func = tbl->resource_func;
+ fid_parms.resource_type = tbl->resource_type;
+ fid_parms.critical_resource = tbl->critical_resource;
+ fid_parms.resource_hndl = idx;
+ rc = ulp_mapper_fdb_opc_process(parms, tbl, &fid_parms);
+ if (rc) {
+ BNXT_TF_DBG(ERR, "Failed to link resource to flow rc = %d\n",
+ rc);
+ /* Need to free the identifier, so goto error */
+ goto error;
}
return 0;
error:
- parms->tcam_tbl_opc = BNXT_ULP_MAPPER_TCAM_TBL_OPC_NORMAL;
free_parms.dir = tbl->direction;
free_parms.tcam_tbl_type = tbl->resource_type;
free_parms.idx = idx;
if (trc)
BNXT_TF_DBG(ERR, "Failed to free tcam[%d][%d][%d] on failure\n",
tbl->resource_type, tbl->direction, idx);
-
return rc;
}
parms.comp_fld = cparms->comp_fld;
parms.tfp = bnxt_ulp_cntxt_tfp_get(ulp_ctx);
parms.ulp_ctx = ulp_ctx;
- parms.tcam_tbl_opc = BNXT_ULP_MAPPER_TCAM_TBL_OPC_NORMAL;
parms.act_tid = cparms->act_tid;
parms.class_tid = cparms->class_tid;
parms.flow_type = cparms->flow_type;
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1,
.blob_key_bit_size = 167,
.cond_opcode = BNXT_ULP_COND_OPC_COMP_FIELD_IS_SET,
.cond_operand = BNXT_ULP_CF_IDX_VFR_MODE,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 14,
.blob_key_bit_size = 167,
.cond_opcode = BNXT_ULP_COND_OPC_COMP_FIELD_NOT_SET,
.cond_operand = BNXT_ULP_CF_IDX_VFR_MODE,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 28,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 42,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 82,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 95,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 108,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_1,
.key_start_idx = 124,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 189,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_1,
.key_start_idx = 205,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 271,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 287,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 353,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 369,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 435,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 451,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 517,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 533,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 598,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 614,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 679,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 695,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 760,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 776,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 841,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 857,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 922,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 938,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1003,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1019,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1084,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1100,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_SKIP,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1148,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_RX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1164,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1224,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1240,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1306,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1322,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1388,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1404,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_LOW,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1470,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1486,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_UPDATE,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1551,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1567,
.blob_key_bit_size = 81,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_L2_CTXT_TCAM_HIGH,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_SEARCH_IF_HIT_UPDATE,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_SRCH_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_L2_CNTXT_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1624,
.blob_key_bit_size = 167,
.resource_func = BNXT_ULP_RESOURCE_FUNC_TCAM_TABLE,
.resource_type = TF_TCAM_TBL_TYPE_PROF_TCAM,
.direction = TF_DIR_TX,
- .srch_b4_alloc = BNXT_ULP_SEARCH_BEFORE_ALLOC_NO,
+ .tbl_opcode = BNXT_ULP_TCAM_TBL_OPC_ALLOC_WR_REGFILE,
+ .tbl_operand = BNXT_ULP_REGFILE_INDEX_PROFILE_TCAM_INDEX_0,
.priority = BNXT_ULP_PRIORITY_LEVEL_0,
.key_start_idx = 1640,
.blob_key_bit_size = 81,