]> git.sur5r.net Git - freertos/blobdiff - FreeRTOS/Source/include/FreeRTOS.h
Add the default definition of configPRECONDITION to FreeRTOS.h.
[freertos] / FreeRTOS / Source / include / FreeRTOS.h
index 6e3deed52dc4dd3cc4c1e29aea7b05392048b05e..14f98d0b0172fb6b689f8531b5c28b2dafae5c71 100644 (file)
@@ -1,5 +1,5 @@
 /*\r
- * FreeRTOS Kernel V10.2.0\r
+ * FreeRTOS Kernel V10.2.1\r
  * Copyright (C) 2019 Amazon.com, Inc. or its affiliates.  All Rights Reserved.\r
  *\r
  * Permission is hereby granted, free of charge, to any person obtaining a copy of\r
@@ -241,6 +241,23 @@ extern "C" {
        #define configASSERT_DEFINED 1\r
 #endif\r
 \r
+/* configPRECONDITION should resolve to configASSERT. The CBMC proofs need a way\r
+to track assumptions and assertions.\r
+- A configPRECONDITION statement should express an implicit invariant or\r
+assumption made.\r
+- A configASSERT statement should express an invariant that must hold explicit\r
+before calling the code. */\r
+#ifndef configPRECONDITION\r
+       #define configPRECONDITION( X ) configASSERT(X)\r
+       #define configPRECONDITION_DEFINED 0\r
+#else\r
+       #define configPRECONDITION_DEFINED 1\r
+#endif\r
+\r
+#ifndef portMEMORY_BARRIER\r
+       #define portMEMORY_BARRIER()\r
+#endif\r
+\r
 /* The timers module relies on xTaskGetSchedulerState(). */\r
 #if configUSE_TIMERS == 1\r
 \r
@@ -766,8 +783,8 @@ extern "C" {
        #define portALLOCATE_SECURE_CONTEXT( ulSecureStackSize )\r
 #endif\r
 \r
-#ifndef portHAS_STACK_OVERFLOW_CHECKING\r
-       #define portHAS_STACK_OVERFLOW_CHECKING 0\r
+#ifndef portDONT_DISCARD\r
+       #define portDONT_DISCARD\r
 #endif\r
 \r
 #ifndef configUSE_TIME_SLICING\r
@@ -1039,25 +1056,40 @@ the Secure Side only. */
  */\r
 struct xSTATIC_LIST_ITEM\r
 {\r
-       TickType_t xDummy1;\r
-       void *pvDummy2[ 4 ];\r
+       #if( configUSE_LIST_DATA_INTEGRITY_CHECK_BYTES == 1 )\r
+               TickType_t xDummy1;\r
+       #endif\r
+       TickType_t xDummy2;\r
+       void *pvDummy3[ 4 ];\r
+       #if( configUSE_LIST_DATA_INTEGRITY_CHECK_BYTES == 1 )\r
+               TickType_t xDummy4;\r
+       #endif\r
 };\r
 typedef struct xSTATIC_LIST_ITEM StaticListItem_t;\r
 \r
 /* See the comments above the struct xSTATIC_LIST_ITEM definition. */\r
 struct xSTATIC_MINI_LIST_ITEM\r
 {\r
-       TickType_t xDummy1;\r
-       void *pvDummy2[ 2 ];\r
+       #if( configUSE_LIST_DATA_INTEGRITY_CHECK_BYTES == 1 )\r
+               TickType_t xDummy1;\r
+       #endif\r
+       TickType_t xDummy2;\r
+       void *pvDummy3[ 2 ];\r
 };\r
 typedef struct xSTATIC_MINI_LIST_ITEM StaticMiniListItem_t;\r
 \r
 /* See the comments above the struct xSTATIC_LIST_ITEM definition. */\r
 typedef struct xSTATIC_LIST\r
 {\r
-       UBaseType_t uxDummy1;\r
-       void *pvDummy2;\r
-       StaticMiniListItem_t xDummy3;\r
+       #if( configUSE_LIST_DATA_INTEGRITY_CHECK_BYTES == 1 )\r
+               TickType_t xDummy1;\r
+       #endif\r
+       UBaseType_t uxDummy2;\r
+       void *pvDummy3;\r
+       StaticMiniListItem_t xDummy4;\r
+       #if( configUSE_LIST_DATA_INTEGRITY_CHECK_BYTES == 1 )\r
+               TickType_t xDummy5;\r
+       #endif\r
 } StaticList_t;\r
 \r
 /*\r