stm32: Add support for disabling the canbus filter

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor
2022-06-11 18:19:53 -04:00
parent 84b2bfe313
commit f5d5f53914
3 changed files with 18 additions and 7 deletions

View File

@@ -113,6 +113,8 @@ can_filter(uint32_t index, uint32_t id)
void
canbus_set_filter(uint32_t id)
{
if (!CONFIG_CANBUS_FILTER)
return;
/* Request initialisation */
SOC_CAN->CCCR |= FDCAN_CCCR_INIT;
/* Wait the acknowledge */