Skip to content

Commit cfd4c73

Browse files
authored
Fix compilation warnings with Clang (#721)
Fix compilation warnings with Clang Signed-off-by: Gaurav Aggarwal <[email protected]>
1 parent a33ba8e commit cfd4c73

File tree

6 files changed

+17
-7
lines changed

6 files changed

+17
-7
lines changed

.github/lexicon.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3089,6 +3089,7 @@ xtaskswaitingtermination
30893089
xtaskswaitingtoreceive
30903090
xtaskswaitingtosend
30913091
xtasktodelete
3092+
xtasktomodify
30923093
xtasktonotify
30933094
xtasktoquery
30943095
xtasktoresume

include/FreeRTOS.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -472,6 +472,14 @@
472472

473473
#endif
474474

475+
#ifndef configUSE_CORE_AFFINITY
476+
#define configUSE_CORE_AFFINITY 0
477+
#endif /* configUSE_CORE_AFFINITY */
478+
479+
#ifndef configUSE_MINIMAL_IDLE_HOOK
480+
#define configUSE_MINIMAL_IDLE_HOOK 0
481+
#endif /* configUSE_MINIMAL_IDLE_HOOK */
482+
475483
/* The timers module relies on xTaskGetSchedulerState(). */
476484
#if configUSE_TIMERS == 1
477485

include/task.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -715,7 +715,7 @@ typedef enum
715715
* a call to xTaskCreateRestricted(). These regions can be redefined using
716716
* vTaskAllocateMPURegions().
717717
*
718-
* @param xTask The handle of the task being updated.
718+
* @param xTaskToModify The handle of the task being updated.
719719
*
720720
* @param[in] pxRegions A pointer to a MemoryRegion_t structure that contains the
721721
* new memory region definitions.
@@ -1321,7 +1321,7 @@ BaseType_t xTaskResumeFromISR( TaskHandle_t xTaskToResume ) PRIVILEGED_FUNCTION;
13211321
UBaseType_t uxCoreAffinityMask );
13221322
#endif
13231323

1324-
#if ( configUSE_CORE_AFFINITY == 1 )
1324+
#if ( ( configNUMBER_OF_CORES > 1 ) && ( configUSE_CORE_AFFINITY == 1 ) )
13251325

13261326
/**
13271327
* @brief Gets the core affinity mask for a task.

portable/MemMang/heap_5.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,8 +120,8 @@
120120
* of their memory address. */
121121
typedef struct A_BLOCK_LINK
122122
{
123-
struct A_BLOCK_LINK * pxNextFreeBlock; /*<< The next free block in the list. */
124-
size_t xBlockSize; /*<< The size of the free block. */
123+
struct A_BLOCK_LINK * pxNextFreeBlock; /**< The next free block in the list. */
124+
size_t xBlockSize; /**< The size of the free block. */
125125
} BlockLink_t;
126126

127127
/*-----------------------------------------------------------*/

portable/ThirdParty/GCC/Posix/port.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -584,12 +584,12 @@ static void prvSetupSignalsAndSchedulerPolicy( void )
584584
}
585585
/*-----------------------------------------------------------*/
586586

587-
unsigned long ulPortGetRunTime( void )
587+
uint32_t ulPortGetRunTime( void )
588588
{
589589
struct tms xTimes;
590590

591591
times( &xTimes );
592592

593-
return ( unsigned long ) xTimes.tms_utime;
593+
return ( uint32_t ) xTimes.tms_utime;
594594
}
595595
/*-----------------------------------------------------------*/

portable/ThirdParty/GCC/Posix/portmacro.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
/* *INDENT-ON* */
3838

3939
#include <limits.h>
40+
#include <stdint.h>
4041

4142
/*-----------------------------------------------------------
4243
* Port specific definitions.
@@ -126,7 +127,7 @@ extern void vPortCancelThread( void *pxTaskToDelete );
126127
*/
127128
#define portMEMORY_BARRIER() __asm volatile( "" ::: "memory" )
128129

129-
extern unsigned long ulPortGetRunTime( void );
130+
extern uint32_t ulPortGetRunTime( void );
130131
#define portCONFIGURE_TIMER_FOR_RUN_TIME_STATS() /* no-op */
131132
#define portGET_RUN_TIME_COUNTER_VALUE() ulPortGetRunTime()
132133

0 commit comments

Comments
 (0)