drivers: Add 'U' to unsigned variable assignments
Add 'U' to a value when assigning it to an unsigned variable. MISRA-C rule 7.2 Signed-off-by: Patrik Flykt <patrik.flykt@intel.com>
This commit is contained in:
parent
25e8e4d4e7
commit
8ff96b5a57
172 changed files with 693 additions and 693 deletions
|
@ -124,7 +124,7 @@ static int uart_imx_fifo_fill(struct device *dev, const u8_t *tx_data,
|
|||
int size)
|
||||
{
|
||||
UART_Type *uart = UART_STRUCT(dev);
|
||||
unsigned int num_tx = 0;
|
||||
unsigned int num_tx = 0U;
|
||||
|
||||
while (((size - num_tx) > 0) &&
|
||||
UART_GetStatusFlag(uart, uartStatusTxReady)) {
|
||||
|
@ -140,7 +140,7 @@ static int uart_imx_fifo_read(struct device *dev, u8_t *rx_data,
|
|||
const int size)
|
||||
{
|
||||
UART_Type *uart = UART_STRUCT(dev);
|
||||
unsigned int num_rx = 0;
|
||||
unsigned int num_rx = 0U;
|
||||
|
||||
while (((size - num_rx) > 0) &&
|
||||
UART_GetStatusFlag(uart, uartStatusRxReady)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue