mirror of
https://github.com/yuzu-emu/mbedtls
synced 2024-11-24 23:28:13 +00:00
Define timing_selftest() even with TIMING_ALT
This commit is contained in:
parent
a27b1979dc
commit
8903fe0fd3
2 changed files with 18 additions and 6 deletions
|
@ -79,6 +79,18 @@ void mbedtls_set_alarm( int seconds );
|
||||||
*/
|
*/
|
||||||
void mbedtls_timing_m_sleep( int milliseconds );
|
void mbedtls_timing_m_sleep( int milliseconds );
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#else /* MBEDTLS_TIMING_ALT */
|
||||||
|
#include "timing_alt.h"
|
||||||
|
#endif /* MBEDTLS_TIMING_ALT */
|
||||||
|
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined(MBEDTLS_SELF_TEST)
|
#if defined(MBEDTLS_SELF_TEST)
|
||||||
/**
|
/**
|
||||||
* \brief Checkup routine
|
* \brief Checkup routine
|
||||||
|
@ -92,8 +104,4 @@ int mbedtls_timing_self_test( int verbose );
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#else /* MBEDTLS_TIMING_ALT */
|
|
||||||
#include "timing_alt.h"
|
|
||||||
#endif /* MBEDTLS_TIMING_ALT */
|
|
||||||
|
|
||||||
#endif /* timing.h */
|
#endif /* timing.h */
|
||||||
|
|
|
@ -33,10 +33,12 @@
|
||||||
#define mbedtls_printf printf
|
#define mbedtls_printf printf
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(MBEDTLS_TIMING_C) && !defined(MBEDTLS_TIMING_ALT)
|
#if defined(MBEDTLS_TIMING_C)
|
||||||
|
|
||||||
#include "mbedtls/timing.h"
|
#include "mbedtls/timing.h"
|
||||||
|
|
||||||
|
#if !defined(MBEDTLS_TIMING_ALT)
|
||||||
|
|
||||||
#if defined(_WIN32) && !defined(EFIX64) && !defined(EFI32)
|
#if defined(_WIN32) && !defined(EFIX64) && !defined(EFI32)
|
||||||
|
|
||||||
#include <windows.h>
|
#include <windows.h>
|
||||||
|
@ -333,6 +335,8 @@ void mbedtls_timing_m_sleep( int milliseconds )
|
||||||
|
|
||||||
#endif /* _WIN32 && !EFIX64 && !EFI32 */
|
#endif /* _WIN32 && !EFIX64 && !EFI32 */
|
||||||
|
|
||||||
|
#endif /* !MBEDTLS_TIMING_ALT */
|
||||||
|
|
||||||
#if defined(MBEDTLS_SELF_TEST)
|
#if defined(MBEDTLS_SELF_TEST)
|
||||||
|
|
||||||
/* To test mbedtls_net_usleep against our functions */
|
/* To test mbedtls_net_usleep against our functions */
|
||||||
|
@ -501,4 +505,4 @@ hard_test:
|
||||||
|
|
||||||
#endif /* MBEDTLS_SELF_TEST */
|
#endif /* MBEDTLS_SELF_TEST */
|
||||||
|
|
||||||
#endif /* MBEDTLS_TIMING_C && !MBEDTLS_TIMING_ALT */
|
#endif /* MBEDTLS_TIMING_C */
|
||||||
|
|
Loading…
Reference in a new issue