diff --git a/SAI b/SAI index c7a49cce5..bc1d6ec90 160000 --- a/SAI +++ b/SAI @@ -1 +1 @@ -Subproject commit c7a49cce5646bd6793e36b4cc3418dac4ae81ac9 +Subproject commit bc1d6ec90fb462c5171dbaa1aedcab1aac890ce9 diff --git a/lib/sai_redis_dash_eni.cpp b/lib/sai_redis_dash_eni.cpp index 9f21bda71..54a3a8fc3 100644 --- a/lib/sai_redis_dash_eni.cpp +++ b/lib/sai_redis_dash_eni.cpp @@ -5,6 +5,7 @@ REDIS_BULK_CREATE_ENTRY_EX(ENI_ETHER_ADDRESS_MAP_ENTRY, eni_ether_address_map_en REDIS_BULK_REMOVE_ENTRY_EX(ENI_ETHER_ADDRESS_MAP_ENTRY, eni_ether_address_map_entry, eni_ether_address_map_entries); REDIS_GENERIC_QUAD(ENI, eni); +REDIS_GENERIC_STATS(ENI, eni); REDIS_BULK_CREATE(ENI, enis); REDIS_BULK_REMOVE(ENI, enis); @@ -14,6 +15,7 @@ const sai_dash_eni_api_t redis_dash_eni_api = { redis_bulk_remove_eni_ether_address_map_entries, REDIS_GENERIC_QUAD_API(eni) + REDIS_GENERIC_STATS_API(eni) redis_bulk_create_enis, redis_bulk_remove_enis, }; diff --git a/unittest/lib/test_sai_redis_dash_eni.cpp b/unittest/lib/test_sai_redis_dash_eni.cpp index 5949762c6..4dcac45a4 100644 --- a/unittest/lib/test_sai_redis_dash_eni.cpp +++ b/unittest/lib/test_sai_redis_dash_eni.cpp @@ -28,6 +28,9 @@ TEST(libsairedis, dash_eni) EXPECT_NE(SAI_STATUS_SUCCESS, api->remove_eni(0)); EXPECT_NE(SAI_STATUS_SUCCESS, api->set_eni_attribute(0,0)); EXPECT_NE(SAI_STATUS_SUCCESS, api->get_eni_attribute(0,0,0)); + EXPECT_NE(SAI_STATUS_SUCCESS, api->get_eni_stats(0,0,0,0)); + EXPECT_NE(SAI_STATUS_SUCCESS, api->get_eni_stats_ext(0,0,0,SAI_STATS_MODE_READ,0)); + EXPECT_NE(SAI_STATUS_SUCCESS, api->clear_eni_stats(0,0,0)); EXPECT_NE(SAI_STATUS_SUCCESS, api->create_enis(0,0,0,0,SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR,0,0)); EXPECT_NE(SAI_STATUS_SUCCESS, api->remove_enis(0,0,SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR,0)); } diff --git a/unittest/vslib/test_sai_vs_dash_eni.cpp b/unittest/vslib/test_sai_vs_dash_eni.cpp index c40c7d724..4b2dd061f 100644 --- a/unittest/vslib/test_sai_vs_dash_eni.cpp +++ b/unittest/vslib/test_sai_vs_dash_eni.cpp @@ -28,6 +28,9 @@ TEST(libsaivs, dash_eni) EXPECT_NE(SAI_STATUS_SUCCESS, api->remove_eni(0)); EXPECT_NE(SAI_STATUS_SUCCESS, api->set_eni_attribute(0,0)); EXPECT_NE(SAI_STATUS_SUCCESS, api->get_eni_attribute(0,0,0)); + EXPECT_NE(SAI_STATUS_SUCCESS, api->get_eni_stats(0,0,0,0)); + EXPECT_NE(SAI_STATUS_SUCCESS, api->get_eni_stats_ext(0,0,0,SAI_STATS_MODE_READ,0)); + EXPECT_NE(SAI_STATUS_SUCCESS, api->clear_eni_stats(0,0,0)); EXPECT_NE(SAI_STATUS_SUCCESS, api->create_enis(0,0,0,0,SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR,0,0)); EXPECT_NE(SAI_STATUS_SUCCESS, api->remove_enis(0,0,SAI_BULK_OP_ERROR_MODE_IGNORE_ERROR,0)); } diff --git a/vslib/sai_vs_dash_eni.cpp b/vslib/sai_vs_dash_eni.cpp index e79dad959..0971bbff3 100644 --- a/vslib/sai_vs_dash_eni.cpp +++ b/vslib/sai_vs_dash_eni.cpp @@ -5,6 +5,7 @@ VS_BULK_CREATE_ENTRY_EX(ENI_ETHER_ADDRESS_MAP_ENTRY, eni_ether_address_map_entry VS_BULK_REMOVE_ENTRY_EX(ENI_ETHER_ADDRESS_MAP_ENTRY, eni_ether_address_map_entry, eni_ether_address_map_entries); VS_GENERIC_QUAD(ENI, eni); +VS_GENERIC_STATS(ENI, eni); VS_BULK_CREATE(ENI, enis); VS_BULK_REMOVE(ENI, enis); @@ -14,6 +15,7 @@ const sai_dash_eni_api_t vs_dash_eni_api = { vs_bulk_remove_eni_ether_address_map_entries, VS_GENERIC_QUAD_API(eni) + VS_GENERIC_STATS_API(eni) vs_bulk_create_enis, vs_bulk_remove_enis, };