Changeset 28f3f511 in rtems


Ignore:
Timestamp:
Sep 6, 2007, 1:11:45 PM (12 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
c468e489
Parents:
921bb59
Message:

2007-09-06 Daniel Hellstrom <daniel@…>

  • console/debugputs.c: Now works on multi-CPU systems.
Location:
c/src/lib/libbsp/sparc/leon3
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/sparc/leon3/ChangeLog

    r921bb59 r28f3f511  
     12007-09-06      Daniel Hellstrom <daniel@gaisler.com>
     2
     3        * console/debugputs.c: Now works on multi-CPU systems.
     4
    152007-09-05      Daniel Hellstrom <daniel@gaisler.com>
    26
  • c/src/lib/libbsp/sparc/leon3/console/debugputs.c

    r921bb59 r28f3f511  
    3636  if ((port >= 0) && (port <= CONFIGURE_NUMBER_OF_TERMIOS_PORTS))
    3737  {
    38     while ( (LEON3_Console_Uart[port]->status & LEON_REG_UART_STATUS_THE) == 0 );
    39     LEON3_Console_Uart[port]->data = (unsigned int) ch;
     38    while ( (LEON3_Console_Uart[LEON3_Cpu_Index+port]->status &
     39                      LEON_REG_UART_STATUS_THE) == 0 );
     40    LEON3_Console_Uart[LEON3_Cpu_Index+port]->data = (unsigned int) ch;
    4041  }
    4142}
     
    5354  {
    5455
    55       if (LEON3_Console_Uart[port]->status & LEON_REG_UART_STATUS_ERR) {
    56         LEON3_Console_Uart[port]->status = ~LEON_REG_UART_STATUS_ERR;
     56      if (LEON3_Console_Uart[LEON3_Cpu_Index+port]->status & LEON_REG_UART_STATUS_ERR) {
     57        LEON3_Console_Uart[LEON3_Cpu_Index+port]->status = ~LEON_REG_UART_STATUS_ERR;
    5758      }
    5859
    59       if ((LEON3_Console_Uart[port]->status & LEON_REG_UART_STATUS_DR) == 0)
     60      if ((LEON3_Console_Uart[LEON3_Cpu_Index+port]->status & LEON_REG_UART_STATUS_DR) == 0)
    6061         return -1;
    61       return (int) LEON3_Console_Uart[port]->data;
     62      return (int) LEON3_Console_Uart[LEON3_Cpu_Index+port]->data;
    6263  }
    6364
Note: See TracChangeset for help on using the changeset viewer.