]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - arch/ppc64/kernel/udbg.c
[PATCH] ppc64: Clean up CR handling
[linux-2.6-omap-h63xx.git] / arch / ppc64 / kernel / udbg.c
index c0da45540f0f50e1a2695b4f325e99831cccd3e1..155670a40c3b8186988b3ea7f1d39a245d9fb787 100644 (file)
@@ -169,12 +169,8 @@ void udbg_maple_real_putc(unsigned char c)
                while ((real_readb(&udbg_comport->lsr) & LSR_THRE) == 0)
                        /* wait for idle */;
                real_writeb(c, &udbg_comport->thr); eieio();
-               if (c == '\n') {
-                       /* Also put a CR.  This is for convenience. */
-                       while ((real_readb(&udbg_comport->lsr) & LSR_THRE) == 0)
-                               /* wait for idle */;
-                       real_writeb('\r', &udbg_comport->thr); eieio();
-               }
+               if (c == '\n')
+                       udbg_maple_real_putc('\r');
        }
 }
 
@@ -194,12 +190,8 @@ void udbg_putc(unsigned char c)
                while ((in_8(&udbg_comport->lsr) & LSR_THRE) == 0)
                        /* wait for idle */;
                out_8(&udbg_comport->thr, c);
-               if (c == '\n') {
-                       /* Also put a CR.  This is for convenience. */
-                       while ((in_8(&udbg_comport->lsr) & LSR_THRE) == 0)
-                               /* wait for idle */; 
-                       out_8(&udbg_comport->thr, '\r');
-               }
+               if (c == '\n')
+                       udbg_putc('\r');
        }
 #ifdef CONFIG_PPC_PMAC
        else if (sccc) {