Skip to content

Commit

Permalink
Clean up
Browse files Browse the repository at this point in the history
  • Loading branch information
lupyuen committed Aug 3, 2023
1 parent 7ee02d6 commit 5551808
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 16 deletions.
8 changes: 4 additions & 4 deletions drivers/serial/uart_16550.c
Original file line number Diff line number Diff line change
Expand Up @@ -52,9 +52,9 @@

#ifdef CONFIG_16550_UART

/***************************************************************************
/****************************************************************************
* Pre-processor Definitions
***************************************************************************/
****************************************************************************/

/* Timeout for UART Busy Wait, in milliseconds */

Expand Down Expand Up @@ -631,7 +631,7 @@ static inline void u16550_serialout(FAR struct u16550_s *priv, int offset,
}

#ifdef CONFIG_16550_WAIT_LCR
/***************************************************************************
/****************************************************************************
* Name: u16550_wait
*
* Description:
Expand All @@ -644,7 +644,7 @@ static inline void u16550_serialout(FAR struct u16550_s *priv, int offset,
* Returned Value:
* Zero (OK) on success; ERROR if timeout.
*
***************************************************************************/
****************************************************************************/

static int u16550_wait(FAR struct u16550_s *priv)
{
Expand Down
24 changes: 12 additions & 12 deletions include/nuttx/serial/uart_16550.h
Original file line number Diff line number Diff line change
Expand Up @@ -172,18 +172,18 @@

/* Register offsets *********************************************************/

#define UART_RBR_INCR 0 /* (DLAB =0) Receiver Buffer Register */
#define UART_THR_INCR 0 /* (DLAB =0) Transmit Holding Register */
#define UART_DLL_INCR 0 /* (DLAB =1) Divisor Latch LSB */
#define UART_DLM_INCR 1 /* (DLAB =1) Divisor Latch MSB */
#define UART_IER_INCR 1 /* (DLAB =0) Interrupt Enable Register */
#define UART_IIR_INCR 2 /* Interrupt ID Register */
#define UART_FCR_INCR 2 /* FIFO Control Register */
#define UART_LCR_INCR 3 /* Line Control Register */
#define UART_MCR_INCR 4 /* Modem Control Register */
#define UART_LSR_INCR 5 /* Line Status Register */
#define UART_MSR_INCR 6 /* Modem Status Register */
#define UART_SCR_INCR 7 /* Scratch Pad Register */
#define UART_RBR_INCR 0 /* (DLAB =0) Receiver Buffer Register */
#define UART_THR_INCR 0 /* (DLAB =0) Transmit Holding Register */
#define UART_DLL_INCR 0 /* (DLAB =1) Divisor Latch LSB */
#define UART_DLM_INCR 1 /* (DLAB =1) Divisor Latch MSB */
#define UART_IER_INCR 1 /* (DLAB =0) Interrupt Enable Register */
#define UART_IIR_INCR 2 /* Interrupt ID Register */
#define UART_FCR_INCR 2 /* FIFO Control Register */
#define UART_LCR_INCR 3 /* Line Control Register */
#define UART_MCR_INCR 4 /* Modem Control Register */
#define UART_LSR_INCR 5 /* Line Status Register */
#define UART_MSR_INCR 6 /* Modem Status Register */
#define UART_SCR_INCR 7 /* Scratch Pad Register */
#define UART_USR_INCR 31 /* UART Status Register */

#define UART_RBR_OFFSET (CONFIG_16550_REGINCR*UART_RBR_INCR)
Expand Down

0 comments on commit 5551808

Please sign in to comment.