arch/arm/src/samd5e5/sam_serial.c: Appease nxstyle

This commit is contained in:
YAMAMOTO Takashi 2020-11-13 14:55:27 +09:00 committed by Xiang Xiao
parent 566ca63cee
commit 45a51bf4b0

View File

@ -67,6 +67,7 @@
/**************************************************************************** /****************************************************************************
* Pre-processor Definitions * Pre-processor Definitions
****************************************************************************/ ****************************************************************************/
/* If we are not using the serial driver for the console, then we still must /* If we are not using the serial driver for the console, then we still must
* provide some minimal implementation of up_putc. * provide some minimal implementation of up_putc.
*/ */
@ -907,7 +908,9 @@ static void sam_rxint(struct uart_dev_s *dev, bool enable)
if (enable) if (enable)
{ {
#ifndef CONFIG_SUPPRESS_SERIAL_INTS #ifndef CONFIG_SUPPRESS_SERIAL_INTS
/* Receive an interrupt when their is anything in the Rx data register */ /* Receive an interrupt when their is anything in the Rx data
* register
*/
sam_serialout8(priv, SAM_USART_INTENSET_OFFSET, USART_INT_RXC); sam_serialout8(priv, SAM_USART_INTENSET_OFFSET, USART_INT_RXC);
#endif #endif
@ -929,7 +932,8 @@ static void sam_rxint(struct uart_dev_s *dev, bool enable)
static bool sam_rxavailable(struct uart_dev_s *dev) static bool sam_rxavailable(struct uart_dev_s *dev)
{ {
struct sam_dev_s *priv = (struct sam_dev_s *)dev->priv; struct sam_dev_s *priv = (struct sam_dev_s *)dev->priv;
return ((sam_serialin8(priv, SAM_USART_INTFLAG_OFFSET) & USART_INT_RXC) != 0); return ((sam_serialin8(priv, SAM_USART_INTFLAG_OFFSET) & USART_INT_RXC)
!= 0);
} }
/**************************************************************************** /****************************************************************************
@ -997,7 +1001,8 @@ static void sam_txint(struct uart_dev_s *dev, bool enable)
static bool sam_txempty(struct uart_dev_s *dev) static bool sam_txempty(struct uart_dev_s *dev)
{ {
struct sam_dev_s *priv = (struct sam_dev_s *)dev->priv; struct sam_dev_s *priv = (struct sam_dev_s *)dev->priv;
return ((sam_serialin8(priv, SAM_USART_INTFLAG_OFFSET) & USART_INT_DRE) != 0); return ((sam_serialin8(priv, SAM_USART_INTFLAG_OFFSET) & USART_INT_DRE)
!= 0);
} }
/**************************************************************************** /****************************************************************************