Freescale: Add KSDK FreeRTOS build, using fastmath
This commit is contained in:
parent
e604ca1d3c
commit
be5ac590b7
@ -1085,7 +1085,7 @@ int wc_GenerateSeed(OS_Seed* os, byte* output, word32 sz)
|
||||
#endif /* WOLFSSL_MIC32MZ_RNG */
|
||||
|
||||
#elif defined(FREESCALE_MQX) || defined(FREESCALE_KSDK_MQX) || \
|
||||
defined(FREESCALE_KSDK_BM)
|
||||
defined(FREESCALE_KSDK_BM) || defined(FREESCALE_FREE_RTOS)
|
||||
|
||||
#ifdef FREESCALE_K70_RNGA
|
||||
/*
|
||||
|
@ -81,6 +81,9 @@
|
||||
/* Uncomment next line if building for Freescale KSDK Bare Metal */
|
||||
/* #define FREESCALE_KSDK_BM */
|
||||
|
||||
/* Uncomment next line if building for Freescale FreeRTOS */
|
||||
/* #define FREESCALE_FREE_RTOS */
|
||||
|
||||
/* Uncomment next line if using STM32F2 */
|
||||
/* #define WOLFSSL_STM32F2 */
|
||||
|
||||
@ -555,6 +558,22 @@ static char *fgets(char *buff, int sz, FILE *fp)
|
||||
#define USE_WOLFSSL_MEMORY
|
||||
#endif
|
||||
|
||||
#ifdef FREESCALE_FREE_RTOS
|
||||
#define FREESCALE_COMMON
|
||||
#define NO_FILESYSTEM
|
||||
#define NO_MAIN_DRIVER
|
||||
#define XMALLOC(s, h, t) OSA_MemAlloc(s);
|
||||
#define XFREE(p, h, t) {void* xp = (p); if((xp)) OSA_MemFree((xp));}
|
||||
#define XREALLOC(p, n, h, t) ksdk_realloc((p), (n), (h), (t));
|
||||
#ifdef FREESCALE_KSDK_BM
|
||||
#error Baremetal and FreeRTOS cannot be both enabled at the same time!
|
||||
#endif
|
||||
#ifndef SINGLE_THREADED
|
||||
#include "FreeRTOS.h"
|
||||
#include "semphr.h"
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef FREESCALE_COMMON
|
||||
#define SIZEOF_LONG_LONG 8
|
||||
#define NO_WRITEV
|
||||
@ -572,7 +591,7 @@ static char *fgets(char *buff, int sz, FILE *fp)
|
||||
#define NO_OLD_RNGNAME
|
||||
#if FSL_FEATURE_SOC_TRNG_COUNT > 0
|
||||
#define FREESCALE_TRNG
|
||||
#elif !defined(FREESCALE_KSDK_BM)
|
||||
#elif !defined(FREESCALE_KSDK_BM) && !defined(FREESCALE_FREE_RTOS)
|
||||
#define FREESCALE_K70_RNGA
|
||||
/* #define FREESCALE_K53_RNGB */
|
||||
#endif
|
||||
|
@ -179,9 +179,9 @@
|
||||
#define XREALLOC(p, n, h, t) realloc((p), (n))
|
||||
#elif !defined(MICRIUM_MALLOC) && !defined(EBSNET) \
|
||||
&& !defined(WOLFSSL_SAFERTOS) && !defined(FREESCALE_MQX) \
|
||||
&& !defined(FREESCALE_KSDK_MQX) && !defined(WOLFSSL_LEANPSK) \
|
||||
&& !defined(FREERTOS) && !defined(WOLFSSL_uITRON4) \
|
||||
&& !defined(WOLFSSL_uTKERNEL2)
|
||||
&& !defined(FREESCALE_KSDK_MQX) && !defined(FREESCALE_FREE_RTOS) \
|
||||
&& !defined(WOLFSSL_LEANPSK) && !defined(FREERTOS) \
|
||||
&& !defined(WOLFSSL_uITRON4) && !defined(WOLFSSL_uTKERNEL2)
|
||||
/* default C runtime, can install different routines at runtime via cbs */
|
||||
#include <wolfssl/wolfcrypt/memory.h>
|
||||
#define XMALLOC(s, h, t) ((void)h, (void)t, wolfSSL_Malloc((s)))
|
||||
|
@ -55,6 +55,8 @@
|
||||
/* do nothing */
|
||||
#elif defined(FREESCALE_MQX) || defined(FREESCALE_KSDK_MQX)
|
||||
/* do nothing */
|
||||
#elif defined(FREESCALE_FREE_RTOS)
|
||||
#include "fsl_os_abstraction.h"
|
||||
#elif defined(WOLFSSL_uITRON4)
|
||||
#include "kernel.h"
|
||||
#elif defined(WOLFSSL_uTKERNEL2)
|
||||
@ -104,6 +106,8 @@
|
||||
typedef RTP_MUTEX wolfSSL_Mutex;
|
||||
#elif defined(FREESCALE_MQX) || defined(FREESCALE_KSDK_MQX)
|
||||
typedef MUTEX_STRUCT wolfSSL_Mutex;
|
||||
#elif defined(FREESCALE_FREE_RTOS)
|
||||
typedef mutex_t wolfSSL_Mutex;
|
||||
#elif defined(WOLFSSL_uITRON4)
|
||||
typedef struct wolfSSL_Mutex {
|
||||
T_CSEM sem ;
|
||||
|
Loading…
x
Reference in New Issue
Block a user