From 8a78b784c4357b60043b7840317ba590f9e0f138 Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Tue, 31 Jul 2018 10:45:41 +0200 Subject: serial/ns16550: Use standard register names Use the standard register names for the divisor latches. This makes it easier to compare the code with other driver implementations. --- bsps/shared/dev/serial/ns16550-context.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'bsps/shared/dev') diff --git a/bsps/shared/dev/serial/ns16550-context.c b/bsps/shared/dev/serial/ns16550-context.c index b42be96a26..5f5ef27c77 100644 --- a/bsps/shared/dev/serial/ns16550-context.c +++ b/bsps/shared/dev/serial/ns16550-context.c @@ -153,9 +153,9 @@ bool ns16550_probe(rtems_termios_device_context *base) (*setReg)(pNS16550, NS16550_LINE_CONTROL, ucDataByte); /* XXX */ - (*setReg)(pNS16550,NS16550_TRANSMIT_BUFFER,(uint8_t)(ulBaudDivisor & 0xffU)); + (*setReg)(pNS16550,NS16550_DIVISOR_LATCH_L,(uint8_t)(ulBaudDivisor & 0xffU)); (*setReg)( - pNS16550,NS16550_INTERRUPT_ENABLE, + pNS16550,NS16550_DIVISOR_LATCH_M, (uint8_t)(( ulBaudDivisor >> 8 ) & 0xffU ) ); @@ -660,8 +660,8 @@ static bool ns16550_set_attributes( */ (*setReg)(pNS16550, NS16550_LINE_CONTROL, SP_LINE_DLAB); - (*setReg)(pNS16550, NS16550_TRANSMIT_BUFFER, ulBaudDivisor&0xff); - (*setReg)(pNS16550, NS16550_INTERRUPT_ENABLE, (ulBaudDivisor>>8)&0xff); + (*setReg)(pNS16550, NS16550_DIVISOR_LATCH_L, ulBaudDivisor&0xff); + (*setReg)(pNS16550, NS16550_DIVISOR_LATCH_M, (ulBaudDivisor>>8)&0xff); /* * Now write the line control -- cgit v1.2.3