Skip to content

Commit a79752a

Browse files
authored
Remove lint suppression comment (#920)
Remove lint suppression comment
1 parent a2712b5 commit a79752a

File tree

11 files changed

+155
-184
lines changed

11 files changed

+155
-184
lines changed

event_groups.c

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,10 @@
4040
#include "timers.h"
4141
#include "event_groups.h"
4242

43-
/* Lint e961, e750 and e9021 are suppressed as a MISRA exception justified
44-
* because the MPU ports require MPU_WRAPPERS_INCLUDED_FROM_API_FILE to be defined
43+
/* The MPU ports require MPU_WRAPPERS_INCLUDED_FROM_API_FILE to be defined
4544
* for the header files above, but not in this file, in order to generate the
4645
* correct privileged Vs unprivileged linkage and placement. */
47-
#undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE /*lint !e961 !e750 !e9021 See comment above. */
46+
#undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE
4847

4948
typedef struct EventGroupDef_t
5049
{
@@ -94,7 +93,7 @@ static BaseType_t prvTestWaitCondition( const EventBits_t uxCurrentEventBits,
9493
* event group structure. */
9594
volatile size_t xSize = sizeof( StaticEventGroup_t );
9695
configASSERT( xSize == sizeof( EventGroup_t ) );
97-
} /*lint !e529 xSize is referenced if configASSERT() is defined. */
96+
}
9897
#endif /* configASSERT_DEFINED */
9998

10099
/* The user has provided a statically allocated event group - use it. */
@@ -166,7 +165,7 @@ static BaseType_t prvTestWaitCondition( const EventBits_t uxCurrentEventBits,
166165
}
167166
else
168167
{
169-
traceEVENT_GROUP_CREATE_FAILED(); /*lint !e9063 Else branch only exists to allow tracing and does not generate code if trace macros are not defined. */
168+
traceEVENT_GROUP_CREATE_FAILED();
170169
}
171170

172171
traceRETURN_xEventGroupCreate( pxEventBits );
@@ -533,7 +532,7 @@ EventBits_t xEventGroupGetBitsFromISR( EventGroupHandle_t xEventGroup )
533532
traceRETURN_xEventGroupGetBitsFromISR( uxReturn );
534533

535534
return uxReturn;
536-
} /*lint !e818 EventGroupHandle_t is a typedef used in other functions to so can't be pointer to const. */
535+
}
537536
/*-----------------------------------------------------------*/
538537

539538
EventBits_t xEventGroupSetBits( EventGroupHandle_t xEventGroup,
@@ -555,7 +554,7 @@ EventBits_t xEventGroupSetBits( EventGroupHandle_t xEventGroup,
555554
configASSERT( ( uxBitsToSet & eventEVENT_BITS_CONTROL_BYTES ) == 0 );
556555

557556
pxList = &( pxEventBits->xTasksWaitingForBits );
558-
pxListEnd = listGET_END_MARKER( pxList ); /*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. */
557+
pxListEnd = listGET_END_MARKER( pxList );
559558
vTaskSuspendAll();
560559
{
561560
traceEVENT_GROUP_SET_BITS( xEventGroup, uxBitsToSet );

include/list.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ struct xLIST_ITEM
151151
struct xLIST * configLIST_VOLATILE pxContainer; /**< Pointer to the list in which this list item is placed (if any). */
152152
listSECOND_LIST_ITEM_INTEGRITY_CHECK_VALUE /**< Set to a known value if configUSE_LIST_DATA_INTEGRITY_CHECK_BYTES is set to 1. */
153153
};
154-
typedef struct xLIST_ITEM ListItem_t; /* For some reason lint wants this as two separate definitions. */
154+
typedef struct xLIST_ITEM ListItem_t;
155155

156156
#if ( configUSE_MINI_LIST_ITEM == 1 )
157157
struct xMINI_LIST_ITEM

include/portable.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,7 @@ size_t xPortGetMinimumEverFreeHeapSize( void ) PRIVILEGED_FUNCTION;
200200
*
201201
* This hook function is called when allocation failed.
202202
*/
203-
void vApplicationMallocFailedHook( void ); /*lint !e526 Symbol not defined as it is an application callback. */
203+
void vApplicationMallocFailedHook( void );
204204
#endif
205205

206206
/*

include/queue.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1554,7 +1554,7 @@ BaseType_t xQueueGiveMutexRecursive( QueueHandle_t xMutex ) PRIVILEGED_FUNCTION;
15541554
*/
15551555
#if ( configQUEUE_REGISTRY_SIZE > 0 )
15561556
void vQueueAddToRegistry( QueueHandle_t xQueue,
1557-
const char * pcQueueName ) PRIVILEGED_FUNCTION; /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
1557+
const char * pcQueueName ) PRIVILEGED_FUNCTION;
15581558
#endif
15591559

15601560
/*
@@ -1583,7 +1583,7 @@ BaseType_t xQueueGiveMutexRecursive( QueueHandle_t xMutex ) PRIVILEGED_FUNCTION;
15831583
* returned.
15841584
*/
15851585
#if ( configQUEUE_REGISTRY_SIZE > 0 )
1586-
const char * pcQueueGetName( QueueHandle_t xQueue ) PRIVILEGED_FUNCTION; /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
1586+
const char * pcQueueGetName( QueueHandle_t xQueue ) PRIVILEGED_FUNCTION;
15871587
#endif
15881588

15891589
/*

include/task.h

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ typedef struct xMEMORY_REGION
144144
typedef struct xTASK_PARAMETERS
145145
{
146146
TaskFunction_t pvTaskCode;
147-
const char * pcName; /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
147+
const char * pcName;
148148
configSTACK_DEPTH_TYPE usStackDepth;
149149
void * pvParameters;
150150
UBaseType_t uxPriority;
@@ -160,7 +160,7 @@ typedef struct xTASK_PARAMETERS
160160
typedef struct xTASK_STATUS
161161
{
162162
TaskHandle_t xHandle; /* The handle of the task to which the rest of the information in the structure relates. */
163-
const char * pcTaskName; /* A pointer to the task's name. This value will be invalid if the task was deleted since the structure was populated! */ /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
163+
const char * pcTaskName; /* A pointer to the task's name. This value will be invalid if the task was deleted since the structure was populated! */
164164
UBaseType_t xTaskNumber; /* A number unique to the task. */
165165
eTaskState eCurrentState; /* The state in which the task existed when the structure was populated. */
166166
UBaseType_t uxCurrentPriority; /* The priority at which the task was running (may be inherited) when the structure was populated. */
@@ -379,7 +379,7 @@ typedef enum
379379
*/
380380
#if ( configSUPPORT_DYNAMIC_ALLOCATION == 1 )
381381
BaseType_t xTaskCreate( TaskFunction_t pxTaskCode,
382-
const char * const pcName, /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
382+
const char * const pcName,
383383
const configSTACK_DEPTH_TYPE usStackDepth,
384384
void * const pvParameters,
385385
UBaseType_t uxPriority,
@@ -388,7 +388,7 @@ typedef enum
388388

389389
#if ( ( configSUPPORT_DYNAMIC_ALLOCATION == 1 ) && ( configNUMBER_OF_CORES > 1 ) && ( configUSE_CORE_AFFINITY == 1 ) )
390390
BaseType_t xTaskCreateAffinitySet( TaskFunction_t pxTaskCode,
391-
const char * const pcName, /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
391+
const char * const pcName,
392392
const configSTACK_DEPTH_TYPE usStackDepth,
393393
void * const pvParameters,
394394
UBaseType_t uxPriority,
@@ -506,7 +506,7 @@ typedef enum
506506
*/
507507
#if ( configSUPPORT_STATIC_ALLOCATION == 1 )
508508
TaskHandle_t xTaskCreateStatic( TaskFunction_t pxTaskCode,
509-
const char * const pcName, /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
509+
const char * const pcName,
510510
const uint32_t ulStackDepth,
511511
void * const pvParameters,
512512
UBaseType_t uxPriority,
@@ -516,7 +516,7 @@ typedef enum
516516

517517
#if ( ( configSUPPORT_STATIC_ALLOCATION == 1 ) && ( configNUMBER_OF_CORES > 1 ) && ( configUSE_CORE_AFFINITY == 1 ) )
518518
TaskHandle_t xTaskCreateStaticAffinitySet( TaskFunction_t pxTaskCode,
519-
const char * const pcName, /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
519+
const char * const pcName,
520520
const uint32_t ulStackDepth,
521521
void * const pvParameters,
522522
UBaseType_t uxPriority,
@@ -1745,7 +1745,7 @@ UBaseType_t uxTaskGetNumberOfTasks( void ) PRIVILEGED_FUNCTION;
17451745
* \defgroup pcTaskGetName pcTaskGetName
17461746
* \ingroup TaskUtils
17471747
*/
1748-
char * pcTaskGetName( TaskHandle_t xTaskToQuery ) PRIVILEGED_FUNCTION; /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
1748+
char * pcTaskGetName( TaskHandle_t xTaskToQuery ) PRIVILEGED_FUNCTION;
17491749

17501750
/**
17511751
* task. h
@@ -1764,7 +1764,7 @@ char * pcTaskGetName( TaskHandle_t xTaskToQuery ) PRIVILEGED_FUNCTION; /*lint !e
17641764
* \ingroup TaskUtils
17651765
*/
17661766
#if ( INCLUDE_xTaskGetHandle == 1 )
1767-
TaskHandle_t xTaskGetHandle( const char * pcNameToQuery ) PRIVILEGED_FUNCTION; /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
1767+
TaskHandle_t xTaskGetHandle( const char * pcNameToQuery ) PRIVILEGED_FUNCTION;
17681768
#endif
17691769

17701770
/**
@@ -1978,7 +1978,7 @@ char * pcTaskGetName( TaskHandle_t xTaskToQuery ) PRIVILEGED_FUNCTION; /*lint !e
19781978
/* MISRA Ref 8.6.1 [External linkage] */
19791979
/* More details at: https://github.com/FreeRTOS/FreeRTOS-Kernel/blob/main/MISRA.md#rule-86 */
19801980
/* coverity[misra_c_2012_rule_8_6_violation] */
1981-
void vApplicationTickHook( void ); /*lint !e526 Symbol not defined as it is an application callback. */
1981+
void vApplicationTickHook( void );
19821982

19831983
#endif
19841984

@@ -1999,7 +1999,7 @@ char * pcTaskGetName( TaskHandle_t xTaskToQuery ) PRIVILEGED_FUNCTION; /*lint !e
19991999
*/
20002000
void vApplicationGetIdleTaskMemory( StaticTask_t ** ppxIdleTaskTCBBuffer,
20012001
StackType_t ** ppxIdleTaskStackBuffer,
2002-
uint32_t * pulIdleTaskStackSize ); /*lint !e526 Symbol not defined as it is an application callback. */
2002+
uint32_t * pulIdleTaskStackSize );
20032003

20042004
/**
20052005
* task.h
@@ -2349,7 +2349,7 @@ char * pcTaskGetName( TaskHandle_t xTaskToQuery ) PRIVILEGED_FUNCTION; /*lint !e
23492349
*/
23502350
#if ( ( configGENERATE_RUN_TIME_STATS == 1 ) && ( configUSE_STATS_FORMATTING_FUNCTIONS > 0 ) && ( configUSE_TRACE_FACILITY == 1 ) )
23512351
void vTaskGetRunTimeStatistics( char * pcWriteBuffer,
2352-
size_t uxBufferLength ) PRIVILEGED_FUNCTION; /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
2352+
size_t uxBufferLength ) PRIVILEGED_FUNCTION;
23532353
#endif
23542354

23552355
/**

include/timers.h

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,8 @@
3434
#error "include FreeRTOS.h must appear in source files before include timers.h"
3535
#endif
3636

37-
/*lint -save -e537 This headers are only multiply included if the application code
38-
* happens to also be including task.h. */
3937
#include "task.h"
40-
/*lint -restore */
38+
4139

4240
/* *INDENT-OFF* */
4341
#ifdef __cplusplus
@@ -229,7 +227,7 @@ typedef void (* PendedFunction_t)( void * arg1,
229227
* @endverbatim
230228
*/
231229
#if ( configSUPPORT_DYNAMIC_ALLOCATION == 1 )
232-
TimerHandle_t xTimerCreate( const char * const pcTimerName, /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
230+
TimerHandle_t xTimerCreate( const char * const pcTimerName,
233231
const TickType_t xTimerPeriodInTicks,
234232
const BaseType_t xAutoReload,
235233
void * const pvTimerID,
@@ -359,7 +357,7 @@ typedef void (* PendedFunction_t)( void * arg1,
359357
* @endverbatim
360358
*/
361359
#if ( configSUPPORT_STATIC_ALLOCATION == 1 )
362-
TimerHandle_t xTimerCreateStatic( const char * const pcTimerName, /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
360+
TimerHandle_t xTimerCreateStatic( const char * const pcTimerName,
363361
const TickType_t xTimerPeriodInTicks,
364362
const BaseType_t xAutoReload,
365363
void * const pvTimerID,
@@ -1253,7 +1251,7 @@ TaskHandle_t xTimerGetTimerDaemonTaskHandle( void ) PRIVILEGED_FUNCTION;
12531251
*
12541252
* @return The name assigned to the timer specified by the xTimer parameter.
12551253
*/
1256-
const char * pcTimerGetName( TimerHandle_t xTimer ) PRIVILEGED_FUNCTION; /*lint !e971 Unqualified char types are allowed for strings and single characters only. */
1254+
const char * pcTimerGetName( TimerHandle_t xTimer ) PRIVILEGED_FUNCTION;
12571255

12581256
/**
12591257
* void vTimerSetReloadMode( TimerHandle_t xTimer, const BaseType_t xAutoReload );

list.c

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,10 @@
3737
#include "FreeRTOS.h"
3838
#include "list.h"
3939

40-
/* Lint e9021, e961 and e750 are suppressed as a MISRA exception justified
41-
* because the MPU ports require MPU_WRAPPERS_INCLUDED_FROM_API_FILE to be
40+
/* The MPU ports require MPU_WRAPPERS_INCLUDED_FROM_API_FILE to be
4241
* defined for the header files above, but not in this file, in order to
4342
* generate the correct privileged Vs unprivileged linkage and placement. */
44-
#undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE /*lint !e961 !e750 !e9021. */
43+
#undef MPU_WRAPPERS_INCLUDED_FROM_API_FILE
4544

4645
/*-----------------------------------------------------------
4746
* PUBLIC LIST API documented in list.h
@@ -54,7 +53,7 @@ void vListInitialise( List_t * const pxList )
5453
/* The list structure contains a list item which is used to mark the
5554
* end of the list. To initialise the list the list end is inserted
5655
* as the only list entry. */
57-
pxList->pxIndex = ( ListItem_t * ) &( pxList->xListEnd ); /*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. */
56+
pxList->pxIndex = ( ListItem_t * ) &( pxList->xListEnd );
5857

5958
listSET_FIRST_LIST_ITEM_INTEGRITY_CHECK_VALUE( &( pxList->xListEnd ) );
6059

@@ -64,8 +63,8 @@ void vListInitialise( List_t * const pxList )
6463

6564
/* The list end next and previous pointers point to itself so we know
6665
* when the list is empty. */
67-
pxList->xListEnd.pxNext = ( ListItem_t * ) &( pxList->xListEnd ); /*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. */
68-
pxList->xListEnd.pxPrevious = ( ListItem_t * ) &( pxList->xListEnd ); /*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. */
66+
pxList->xListEnd.pxNext = ( ListItem_t * ) &( pxList->xListEnd );
67+
pxList->xListEnd.pxPrevious = ( ListItem_t * ) &( pxList->xListEnd );
6968

7069
/* Initialize the remaining fields of xListEnd when it is a proper ListItem_t */
7170
#if ( configUSE_MINI_LIST_ITEM == 0 )
@@ -190,7 +189,7 @@ void vListInsert( List_t * const pxList,
190189
* configMAX_SYSCALL_INTERRUPT_PRIORITY.
191190
**********************************************************************/
192191

193-
for( pxIterator = ( ListItem_t * ) &( pxList->xListEnd ); pxIterator->pxNext->xItemValue <= xValueOfInsertion; pxIterator = pxIterator->pxNext ) /*lint !e826 !e740 !e9087 The mini list structure is used as the list end to save RAM. This is checked and valid. *//*lint !e440 The iterator moves to a different value, not xValueOfInsertion. */
192+
for( pxIterator = ( ListItem_t * ) &( pxList->xListEnd ); pxIterator->pxNext->xItemValue <= xValueOfInsertion; pxIterator = pxIterator->pxNext )
194193
{
195194
/* There is nothing to do here, just iterating to the wanted
196195
* insertion position. */

0 commit comments

Comments
 (0)