diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2007-09-19 15:15:15 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2007-09-19 15:15:15 +0000 |
commit | b151f5bd50ccc2c2c6a1d8449966995f9c393929 (patch) | |
tree | 7a24bb8ed12b3ae6840fe70305fc1fd060581821 | |
parent | 2007-09-19 Kate Feng <feng1@bnl.gov> (diff) | |
download | rtems-b151f5bd50ccc2c2c6a1d8449966995f9c393929.tar.bz2 |
2007-09-19 Daniel Hellstrom <daniel@gaisler.com>
* shared/can/occan.c: Fix Reenable command and fix typo.
-rw-r--r-- | c/src/lib/libbsp/sparc/ChangeLog | 4 | ||||
-rw-r--r-- | c/src/lib/libbsp/sparc/shared/can/occan.c | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/c/src/lib/libbsp/sparc/ChangeLog b/c/src/lib/libbsp/sparc/ChangeLog index 6e739e4434..506ca69333 100644 --- a/c/src/lib/libbsp/sparc/ChangeLog +++ b/c/src/lib/libbsp/sparc/ChangeLog @@ -1,3 +1,7 @@ +2007-09-19 Daniel Hellstrom <daniel@gaisler.com> + + * shared/can/occan.c: Fix Reenable command and fix typo. + 2007-09-18 Joel Sherrill <joel.sherrill@OARcorp.com> * shared/1553/b1553brm.c, shared/can/grcan.c: Remove include of sched.h diff --git a/c/src/lib/libbsp/sparc/shared/can/occan.c b/c/src/lib/libbsp/sparc/shared/can/occan.c index 6b9dd47601..b5b6e51885 100644 --- a/c/src/lib/libbsp/sparc/shared/can/occan.c +++ b/c/src/lib/libbsp/sparc/shared/can/occan.c @@ -1625,7 +1625,7 @@ static void occan_interrupt(occan_priv *can){ } /* Re-Enable RX buffer for a new message */ - regs->cmd = READ_REG(®s->cmd) | PELICAN_CMD_RELRXBUF; + regs->cmd = PELICAN_CMD_RELRXBUF; /* make message available to the user */ occan_fifo_put(can->rxfifo); @@ -1726,7 +1726,7 @@ static void occan_interrupt(occan_priv *can){ tx_error_cnt = READ_REG(®s->tx_err_cnt); rx_error_cnt = READ_REG(®s->rx_err_cnt); - if ( (tx_error_cnt > 127) || (tx_error_cnt > 127) ){ + if ( (tx_error_cnt > 127) || (rx_error_cnt > 127) ){ can->status |= OCCAN_STATUS_ERR_PASSIVE; }else{ can->status &= ~(OCCAN_STATUS_ERR_PASSIVE); |