mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-04-20 05:21:59 -04:00
Code review suggestions
Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
This commit is contained in:
parent
4a3711b192
commit
1fc772392f
|
@ -26,6 +26,9 @@
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/* Hardware includes. */
|
||||||
|
#include "msp430.h"
|
||||||
|
|
||||||
/* Scheduler includes. */
|
/* Scheduler includes. */
|
||||||
#include "FreeRTOS.h"
|
#include "FreeRTOS.h"
|
||||||
#include "task.h"
|
#include "task.h"
|
||||||
|
|
|
@ -39,9 +39,6 @@
|
||||||
*-----------------------------------------------------------
|
*-----------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* Hardware includes. */
|
|
||||||
#include "msp430.h"
|
|
||||||
|
|
||||||
/* Type definitions. */
|
/* Type definitions. */
|
||||||
#define portCHAR char
|
#define portCHAR char
|
||||||
#define portFLOAT float
|
#define portFLOAT float
|
||||||
|
@ -75,8 +72,8 @@ typedef unsigned short UBaseType_t;
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
/* Interrupt control macros. */
|
/* Interrupt control macros. */
|
||||||
#define portDISABLE_INTERRUPTS() _disable_interrupt(); _nop()
|
#define portDISABLE_INTERRUPTS() __asm volatile ( " DINT\n" " NOP" )
|
||||||
#define portENABLE_INTERRUPTS() _enable_interrupt(); _nop()
|
#define portENABLE_INTERRUPTS() __asm volatile ( " NOP\n" " EINT\n" " NOP" )
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
/* Critical section control macros. */
|
/* Critical section control macros. */
|
||||||
|
@ -126,7 +123,7 @@ extern void vPortYield( void );
|
||||||
#define portBYTE_ALIGNMENT 2
|
#define portBYTE_ALIGNMENT 2
|
||||||
#define portSTACK_GROWTH ( -1 )
|
#define portSTACK_GROWTH ( -1 )
|
||||||
#define portTICK_PERIOD_MS ( ( TickType_t ) 1000 / configTICK_RATE_HZ )
|
#define portTICK_PERIOD_MS ( ( TickType_t ) 1000 / configTICK_RATE_HZ )
|
||||||
#define portNOP() __no_operation()
|
#define portNOP() __asm volatile ( " NOP" )
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
/* Task function macros as described on the FreeRTOS.org WEB site. */
|
/* Task function macros as described on the FreeRTOS.org WEB site. */
|
||||||
|
|
|
@ -73,7 +73,7 @@ typedef unsigned short UBaseType_t;
|
||||||
|
|
||||||
/* Interrupt control macros. */
|
/* Interrupt control macros. */
|
||||||
#define portDISABLE_INTERRUPTS() __asm volatile ( "DINT\n" "NOP" )
|
#define portDISABLE_INTERRUPTS() __asm volatile ( "DINT\n" "NOP" )
|
||||||
#define portENABLE_INTERRUPTS() __asm volatile ( "EINT\n" "NOP" )
|
#define portENABLE_INTERRUPTS() __asm volatile ( "NOP\n" "EINT\n" "NOP" )
|
||||||
/*-----------------------------------------------------------*/
|
/*-----------------------------------------------------------*/
|
||||||
|
|
||||||
/* Critical section control macros. */
|
/* Critical section control macros. */
|
||||||
|
|
Loading…
Reference in a new issue