include: Use macro BIT for shift operations
Use a macro BIT when dealing with bit shift operations. MISRA-C rule 10.1 Signed-off-by: Flavio Ceolin <flavio.ceolin@intel.com>
This commit is contained in:
parent
a996203739
commit
95eb2b4fed
12 changed files with 38 additions and 38 deletions
|
@ -54,8 +54,8 @@ struct posix_thread {
|
|||
|
||||
/* Pthread cancellation */
|
||||
#define _PTHREAD_CANCEL_POS 0
|
||||
#define PTHREAD_CANCEL_ENABLE (0 << _PTHREAD_CANCEL_POS)
|
||||
#define PTHREAD_CANCEL_DISABLE (1 << _PTHREAD_CANCEL_POS)
|
||||
#define PTHREAD_CANCEL_ENABLE (0U << _PTHREAD_CANCEL_POS)
|
||||
#define PTHREAD_CANCEL_DISABLE BIT(_PTHREAD_CANCEL_POS)
|
||||
|
||||
/* Passed to pthread_once */
|
||||
#define PTHREAD_ONCE_INIT 1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue