diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2007-05-09 17:40:24 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2007-05-09 17:40:24 +0000 |
commit | 0bb47ebd6577c6881d6ffd5636c70ca7bcbcf104 (patch) | |
tree | 7d079bf1fea32c254f1a27ceaed255a2a09f425e /c/src/lib/libbsp/arm/rtl22xx/console | |
parent | Regenerate. (diff) | |
download | rtems-0bb47ebd6577c6881d6ffd5636c70ca7bcbcf104.tar.bz2 |
2007-05-09 Joel Sherrill <joel.sherrill@OARcorp.com>
* console/uart.c, startup/bspclean.c, startup/bspstart.c: Remove debug
print methods that are redundant with prntk and replace their usage
with printk.
Diffstat (limited to 'c/src/lib/libbsp/arm/rtl22xx/console')
-rw-r--r-- | c/src/lib/libbsp/arm/rtl22xx/console/uart.c | 50 |
1 files changed, 4 insertions, 46 deletions
diff --git a/c/src/lib/libbsp/arm/rtl22xx/console/uart.c b/c/src/lib/libbsp/arm/rtl22xx/console/uart.c index aad1383867..792398a0c3 100644 --- a/c/src/lib/libbsp/arm/rtl22xx/console/uart.c +++ b/c/src/lib/libbsp/arm/rtl22xx/console/uart.c @@ -168,8 +168,7 @@ static int uart_read(int minor) return -1; } } else { - debug_printk("Unknown console minor number"); - printi(minor); + printk("Unknown console minor number %d\n", minor); return -1; } @@ -197,10 +196,9 @@ static int uart_write(int minor, const char *buf, int len) continue; /* also either WDOG() or swap()*/ U0THR = (char) buf[i]; } - }else { - debug_printk("Unknown console minor number"); - printi(minor); - return -1; + } else { + printk("Unknown console minor number %d\n", minor); + return -1; } return 1; @@ -334,43 +332,3 @@ void UART0_SendStr(char const *str) UART0_SendByte(*str++); // Send the char } } - -debug_printk(char *dg_str) -{ - UART0_SendStr(dg_str); - UART0_SendStr("\r\n"); -} - -void printi(unsigned long value) -{ - static char istring[9]={0,0,0,0,0,0,0,0,0}; - static char tmp[9]={0,0,0,0,0,0,0,0,0}; - char *sp; - char *tp = tmp; - - long i; - unsigned long v = value; - int index; - - for(index=0;index<9;index++) - istring[index]=tmp[index]=0x0; - - while (v || tp == tmp) - { - i = v % 16; - v = v / 16; - if (i < 10) - *tp++ = i+'0'; - else - *tp++ = i + 'a' - 10; - } - - sp = istring; - while (tp > tmp) - *sp++ = *--tp; - - tp=tmp; - sp=istring; - debug_printk(istring); - -} |