diff --git a/dash-pipeline/SAI/templates/saiapi.cpp.j2 b/dash-pipeline/SAI/templates/saiapi.cpp.j2 index 1d3911485..85ab7fbda 100644 --- a/dash-pipeline/SAI/templates/saiapi.cpp.j2 +++ b/dash-pipeline/SAI/templates/saiapi.cpp.j2 @@ -46,7 +46,7 @@ static sai_status_t dash_sai_create_{{ table.name }}( // Generate a SAI object ID and fill it as the P4 table key auto mf = matchActionEntry->add_match(); mf->set_field_id({{table['keys'][0].id}}); - objId = NextObjIndex((sai_object_type_t)SAI_OBJECT_TYPE_{{ table.name | upper}}); + objId = NextObjectId((sai_object_type_t)SAI_OBJECT_TYPE_{{ table.name | upper}}); auto mf_exact = mf->mutable_exact(); {{table['keys'][0].field}}SetVal(objId, mf_exact, {{table['keys'][0].bitwidth}}); {% else %} diff --git a/dash-pipeline/SAI/templates/utils.cpp.j2 b/dash-pipeline/SAI/templates/utils.cpp.j2 index bf57529d6..c984ffaaa 100644 --- a/dash-pipeline/SAI/templates/utils.cpp.j2 +++ b/dash-pipeline/SAI/templates/utils.cpp.j2 @@ -111,7 +111,7 @@ bool InsertInTable(std::shared_ptr entry, sai_object_type_t if (*objId == 0) { - *objId = NextObjIndex(objectType); + *objId = NextObjectId(objectType); } tableEntryMap.insert(std::make_pair(*objId, entry)); @@ -119,7 +119,7 @@ bool InsertInTable(std::shared_ptr entry, sai_object_type_t return true; } -sai_object_id_t NextObjIndex(sai_object_type_t objectType) +sai_object_id_t NextObjectId(sai_object_type_t objectType) { DASH_LOG_ENTER(); diff --git a/dash-pipeline/SAI/templates/utils.h.j2 b/dash-pipeline/SAI/templates/utils.h.j2 index 21f560e1c..9807c30d3 100644 --- a/dash-pipeline/SAI/templates/utils.h.j2 +++ b/dash-pipeline/SAI/templates/utils.h.j2 @@ -313,7 +313,7 @@ void u64SetMask(const sai_uint64_t &value, T &t, int bits = 64) { grpc::StatusCode MutateTableEntry(std::shared_ptr, p4::v1::Update_Type updateType); -sai_object_id_t NextObjIndex(sai_object_type_t objectType); +sai_object_id_t NextObjectId(sai_object_type_t objectType); bool InsertInTable(std::shared_ptr entry, sai_object_type_t objectType, sai_object_id_t *objId);