Skip to content
Commit 9d938630 authored by ferar alashkar's avatar ferar alashkar Committed by Anas Nashif
Browse files

drivers: intc: stm32: use BIT macro with type cast argument



1. use 'BIT' macro instead of explicit left shift operations, since
'BIT' macro implicitly adds unsigned type suffix, avoiding possible
[shiftTooManyBitsSigned] scenarios, and

2. add an explicit uint32_t cast to 'BIT' macro argument, complying with
required [misra-c2012-10.1] rule which states; operands shall not be of
an inappropriate essential type.

Found as a coding guideline violation (Rule 10.1) by static code
scanning tool.

Note: Tested on STM32L5 Nucleo-144 board (stm32l552xx).

Signed-off-by: default avatarferar alashkar <ferar.alashkar@gmail.com>
parent 67dd5841
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment