From 40f413d3c97a7694703938cd031ce15912b29ff7 Mon Sep 17 00:00:00 2001 From: gdisirio Date: Wed, 24 Jul 2013 14:54:26 +0000 Subject: git-svn-id: svn://svn.code.sf.net/p/chibios/svn/branches/kernel_3_dev@6025 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- os/hal/platforms/STM32/USARTv2/serial_lld.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'os/hal') diff --git a/os/hal/platforms/STM32/USARTv2/serial_lld.c b/os/hal/platforms/STM32/USARTv2/serial_lld.c index 85f6b059c..f57d0ce1b 100644 --- a/os/hal/platforms/STM32/USARTv2/serial_lld.c +++ b/os/hal/platforms/STM32/USARTv2/serial_lld.c @@ -134,9 +134,9 @@ static void set_error(SerialDriver *sdp, uint32_t isr) { sts |= SD_FRAMING_ERROR; if (isr & USART_ISR_NE) sts |= SD_NOISE_ERROR; - chSysLockFromIsr(); + chSysLockFromISR(); chnAddFlagsI(sdp, sts); - chSysUnlockFromIsr(); + chSysUnlockFromISR(); } /** @@ -158,20 +158,20 @@ static void serve_interrupt(SerialDriver *sdp) { set_error(sdp, isr); /* Special case, LIN break detection.*/ if (isr & USART_ISR_LBD) { - chSysLockFromIsr(); + chSysLockFromISR(); chnAddFlagsI(sdp, SD_BREAK_DETECTED); - chSysUnlockFromIsr(); + chSysUnlockFromISR(); } /* Data available.*/ if (isr & USART_ISR_RXNE) { - chSysLockFromIsr(); + chSysLockFromISR(); sdIncomingDataI(sdp, (uint8_t)u->RDR); - chSysUnlockFromIsr(); + chSysUnlockFromISR(); } /* Transmission buffer empty.*/ if ((cr1 & USART_CR1_TXEIE) && (isr & USART_ISR_TXE)) { msg_t b; - chSysLockFromIsr(); + chSysLockFromISR(); b = chOQGetI(&sdp->oqueue); if (b < Q_OK) { chnAddFlagsI(sdp, CHN_OUTPUT_EMPTY); @@ -179,13 +179,13 @@ static void serve_interrupt(SerialDriver *sdp) { } else u->TDR = b; - chSysUnlockFromIsr(); + chSysUnlockFromISR(); } /* Physical transmission end.*/ if (isr & USART_ISR_TC) { - chSysLockFromIsr(); + chSysLockFromISR(); chnAddFlagsI(sdp, CHN_TRANSMISSION_END); - chSysUnlockFromIsr(); + chSysUnlockFromISR(); u->CR1 = cr1 & ~USART_CR1_TCIE; } } -- cgit v1.2.3