mirror of
https://github.com/apache/nuttx.git
synced 2026-05-31 05:55:46 +08:00
sched/init: use enum type for g_nx_initstate
Change g_nx_initstate type from uint8_t to enum nx_initstate_e. Avoid enum/integer base-type mismatch in init state comparisons. Satisfies MISRA C:2012 Rule 10.4 without behavior change. Signed-off-by: fangxinyong <fangxinyong@xiaomi.com>
This commit is contained in:
@@ -93,7 +93,7 @@ extern "C"
|
||||
* hardware resources may not yet be available to the OS-internal logic.
|
||||
*/
|
||||
|
||||
EXTERN volatile uint8_t g_nx_initstate; /* See enum nx_initstate_e */
|
||||
EXTERN volatile enum nx_initstate_e g_nx_initstate; /* See enum nx_initstate_e */
|
||||
|
||||
/****************************************************************************
|
||||
* Public Function Prototypes
|
||||
|
||||
@@ -185,7 +185,7 @@ struct tasklist_s g_tasklisttable[NUM_TASK_STATES];
|
||||
* hardware resources may not yet be available to the kernel logic.
|
||||
*/
|
||||
|
||||
volatile uint8_t g_nx_initstate; /* See enum nx_initstate_e */
|
||||
volatile enum nx_initstate_e g_nx_initstate; /* See enum nx_initstate_e */
|
||||
|
||||
/* This is an array of task control block (TCB) for the IDLE thread of each
|
||||
* CPU. For the non-SMP case, this is a a single TCB; For the SMP case,
|
||||
|
||||
Reference in New Issue
Block a user