diff options
author | Mike Frysinger <vapier@gentoo.org> | 2011-05-14 15:59:09 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2011-05-14 15:59:09 +0000 |
commit | 28fe96b798c2b0a7abd07b2631f6d4abeaf9d4dd (patch) | |
tree | b36e50567ba4c3b69bd47cea4479e37b2d394d35 /sim/bfin/dv-bfin_uart.h | |
parent | ba4a8bdd81e55d45b97cdf9b91eb111a7ac0d3f9 (diff) | |
download | gdb-28fe96b798c2b0a7abd07b2631f6d4abeaf9d4dd.zip gdb-28fe96b798c2b0a7abd07b2631f6d4abeaf9d4dd.tar.gz gdb-28fe96b798c2b0a7abd07b2631f6d4abeaf9d4dd.tar.bz2 |
sim: bfin: implement loop back support in the UARTs
The UART has a LOOP_ENA bit in its MCR register where writes to the THR
go to the RBR. Implement support for this mode.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'sim/bfin/dv-bfin_uart.h')
-rw-r--r-- | sim/bfin/dv-bfin_uart.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/sim/bfin/dv-bfin_uart.h b/sim/bfin/dv-bfin_uart.h index ccb7af4..52074f6 100644 --- a/sim/bfin/dv-bfin_uart.h +++ b/sim/bfin/dv-bfin_uart.h @@ -26,8 +26,8 @@ #define BFIN_MMR_UART_SIZE 0x30 struct bfin_uart; -bu16 bfin_uart_get_next_byte (struct hw *, bu16, bool *fresh); -bu16 bfin_uart_write_byte (struct hw *, bu16); +bu16 bfin_uart_get_next_byte (struct hw *, bu16, bu16, bool *fresh); +bu16 bfin_uart_write_byte (struct hw *, bu16, bu16); bu16 bfin_uart_get_status (struct hw *); unsigned bfin_uart_write_buffer (struct hw *, const unsigned char *, unsigned); unsigned bfin_uart_read_buffer (struct hw *, unsigned char *, unsigned); @@ -51,4 +51,14 @@ void bfin_uart_reschedule (struct hw *); #define ETBEI (1 << 1) #define ELSI (1 << 2) +/* UART_MCR */ +#define XOFF (1 << 0) +#define MRTS (1 << 1) +#define RFIT (1 << 2) +#define RFRT (1 << 3) +#define LOOP_ENA (1 << 4) +#define FCPOL (1 << 5) +#define ARTS (1 << 6) +#define ACTS (1 << 7) + #endif |