From f8a70c1eb1401a4efa87ebc2c97f9782c79a6e7f Mon Sep 17 00:00:00 2001 From: gdisirio Date: Sat, 9 Mar 2013 11:19:01 +0000 Subject: Fixed bug 3606616. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@5389 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/platforms/STM32/can_lld.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'os/hal') diff --git a/os/hal/platforms/STM32/can_lld.c b/os/hal/platforms/STM32/can_lld.c index 76a50f460..7dab31faf 100644 --- a/os/hal/platforms/STM32/can_lld.c +++ b/os/hal/platforms/STM32/can_lld.c @@ -212,6 +212,7 @@ static void can_lld_sce_handler(CANDriver *canp) { msr = canp->can->MSR; canp->can->MSR = CAN_MSR_ERRI | CAN_MSR_WKUI | CAN_MSR_SLAKI; /* Wakeup event.*/ +#if CAN_USE_SLEEP_MODE if (msr & CAN_MSR_WKUI) { canp->state = CAN_READY; canp->can->MCR &= ~CAN_MCR_SLEEP; @@ -219,6 +220,7 @@ static void can_lld_sce_handler(CANDriver *canp) { chEvtBroadcastI(&canp->wakeup_event); chSysUnlockFromIsr(); } +#endif /* CAN_USE_SLEEP_MODE */ /* Error event.*/ if (msr & CAN_MSR_ERRI) { flagsmask_t flags; -- cgit v1.2.3