diff --git a/board/drivers/can_common.h b/board/drivers/can_common.h index 6237c7aebe9..35b9a6882d8 100644 --- a/board/drivers/can_common.h +++ b/board/drivers/can_common.h @@ -38,7 +38,7 @@ can_ring *can_queues[PANDA_CAN_CNT] = {&can_tx1_q, &can_tx2_q, &can_tx3_q}; // ********************* interrupt safe queue ********************* bool can_pop(can_ring *q, CANPacket_t *elem) { - bool ret = 0; + bool ret = false; ENTER_CRITICAL(); if (q->w_ptr != q->r_ptr) { @@ -48,7 +48,7 @@ bool can_pop(can_ring *q, CANPacket_t *elem) { } else { q->r_ptr += 1U; } - ret = 1; + ret = true; } EXIT_CRITICAL(); diff --git a/tests/misra/suppressions.txt b/tests/misra/suppressions.txt index 4800a270bcb..96a07e4a7ca 100644 --- a/tests/misra/suppressions.txt +++ b/tests/misra/suppressions.txt @@ -19,3 +19,6 @@ unusedFunction:*/interrupt_handlers*.h # cppcheck from 2.5 -> 2.13. they are listed here to separate the update from # fixing the violations and all are intended to be removed soon after misra-c2012-2.5 # unused macros. a few legit, rest aren't common between F4/H7 builds. should we do this in the unusedFunction pass? + +# TODO: remove after opendbc PR #3256 or equivalent is merged +misra-c2012-10.3:*/opendbc/safety/modes/toyota.h