From abe5dbeed0c367293ce108c93d825de8d5cadeae Mon Sep 17 00:00:00 2001 From: Rohan S <3526930+brosahay@users.noreply.github.com> Date: Mon, 17 Jun 2024 22:24:35 +0530 Subject: [PATCH] Adds changes for use of SL_MBEDTLS_USE_TINYCRYPT --- src/platform/silabs/PlatformManagerImpl.cpp | 4 ++-- src/platform/silabs/PlatformManagerImpl.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/platform/silabs/PlatformManagerImpl.cpp b/src/platform/silabs/PlatformManagerImpl.cpp index c3a8f182ce39a0..741a0b6b8676e1 100644 --- a/src/platform/silabs/PlatformManagerImpl.cpp +++ b/src/platform/silabs/PlatformManagerImpl.cpp @@ -31,9 +31,9 @@ #include #include -#if defined(TINYCRYPT_PRIMITIVES) +#if defined(SL_MBEDTLS_USE_TINYCRYPT) #include "tinycrypt/ecc.h" -#endif // TINYCRYPT_PRIMITIVES +#endif // SL_MBEDTLS_USE_TINYCRYPT #if CHIP_SYSTEM_CONFIG_USE_LWIP #include diff --git a/src/platform/silabs/PlatformManagerImpl.h b/src/platform/silabs/PlatformManagerImpl.h index 4a0bfdb52c1e81..b44fbadbfa3308 100644 --- a/src/platform/silabs/PlatformManagerImpl.h +++ b/src/platform/silabs/PlatformManagerImpl.h @@ -41,7 +41,7 @@ class PlatformManagerImpl final : public PlatformManager, public Internal::Gener // the implementation methods provided by this class. friend PlatformManager; -#if defined(TINYCRYPT_PRIMITIVES) +#if defined(SL_MBEDTLS_USE_TINYCRYPT) // Since the RNG callback will be called from multiple threads, // use this mutex to lock/unlock the call to Matter RNG API, which // uses some global variables. @@ -51,7 +51,7 @@ class PlatformManagerImpl final : public PlatformManager, public Internal::Gener // It must be set before calling any sign operations, // which are used in both Matter and OT threads. static int uECC_RNG_Function(uint8_t * dest, unsigned int size); -#endif +#endif // SL_MBEDTLS_USE_TINYCRYPT // Allow the generic implementation base class to call helper methods on // this class.