From 80859fe108d4be82af9f2c8ba436ffc19d81211f Mon Sep 17 00:00:00 2001 From: Stepan Blyschak Date: Wed, 18 Dec 2024 15:26:26 +0000 Subject: [PATCH] fix review comment Signed-off-by: Stepan Blyschak --- syncd/SaiDiscovery.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/syncd/SaiDiscovery.cpp b/syncd/SaiDiscovery.cpp index 34b7f1d26..b75f490d6 100644 --- a/syncd/SaiDiscovery.cpp +++ b/syncd/SaiDiscovery.cpp @@ -60,13 +60,6 @@ void SaiDiscovery::discover( sai_object_type_t ot = m_sai->objectTypeQuery(rid); -#ifdef SKIP_SAI_PORT_DISCOVERY - if (ot == SAI_OBJECT_TYPE_PORT) - { - return; - } -#endif - if (ot == SAI_OBJECT_TYPE_NULL) { SWSS_LOG_THROW("objectTypeQuery: rid %s returned NULL object type", @@ -94,6 +87,13 @@ void SaiDiscovery::discover( discovered.insert(rid); } +#ifdef SKIP_SAI_PORT_DISCOVERY + if (ot == SAI_OBJECT_TYPE_PORT) + { + return; + } +#endif + const sai_object_type_info_t *info = sai_metadata_get_object_type_info(ot); /*