]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
serial: Do not write additional \r before \n for dm_serial drivers
authorPali Rohár <pali@kernel.org>
Sat, 10 Dec 2022 23:27:44 +0000 (00:27 +0100)
committerTom Rini <trini@konsulko.com>
Mon, 2 Jan 2023 21:01:40 +0000 (16:01 -0500)
serial-uclass.c code already puts \r before \n for all dm_serial drivers.

Signed-off-by: Pali Rohár <pali@kernel.org>
Reviewed-by: Stefan Roese <sr@denx.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
drivers/serial/serial_lpuart.c
drivers/serial/serial_mpc8xx.c

index ff576da516d42b56cb2325d3e886a4b22720e50b..07941c29ed74de9968b08b2b8eba88594fd3b80c 100644 (file)
@@ -349,9 +349,6 @@ static void _lpuart32_serial_putc(struct lpuart_serial_plat *plat,
        struct lpuart_fsl_reg32 *base = plat->reg;
        u32 stat;
 
-       if (c == '\n')
-               serial_putc('\r');
-
        while (true) {
                lpuart_read32(plat->flags, &base->stat, &stat);
 
index aeae6ae6cd250831eb477674db1d6a280050be5b..808a40f503eaa340a5c6ce05234de6f5277f773a 100644 (file)
@@ -176,9 +176,6 @@ static int serial_mpc8xx_putc(struct udevice *dev, const char c)
        cpm8xx_t        __iomem *cpmp = &(im->im_cpm);
        struct serialbuffer     __iomem *rtx;
 
-       if (c == '\n')
-               serial_mpc8xx_putc(dev, '\r');
-
        rtx = (struct serialbuffer __iomem *)&cpmp->cp_dpmem[CPM_SERIAL_BASE];
 
        /* Wait for last character to go. */