Changeset 35ece2e in rtems


Ignore:
Timestamp:
Feb 11, 2000, 3:21:40 PM (20 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
562e7ed1
Parents:
1249edfa
Message:

Patch from Eric Norum <eric@…> based on working with
Bob Wisdon <bobwis@…> and Chris Johns <ccj@…>
to resolve a random network lockup problem.

ckinit.c:

Occasional network lockups have been noted when the PIT has a higher
interrupt request level than the CPM. The SCC1 bit in the CISR is set
even though the SCC1 interrupt handler is not active. This blocks
interrupts from SCC1 (and all other CPM sources) and locks up the
system. It has not been determined whether the error is within the
68360 or in the RTEMS interrupt support assembler code. The solution,
for now, is to set both PIT and CPM interrupt request levels to the same
value (4).

network.c:

Set CPM transmitter buffer pointer (_tbptr) to beginning of frame
before restarting transmitter. Don't retire transmitter buffer
descriptors belonging to the restarted frame.

Location:
c/src/lib/libbsp/m68k/gen68360
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/m68k/gen68360/README

    r1249edfa r35ece2e  
    300300                P.O. Box 270352
    301301                Fort Collins, CO 80527-0352
     302
     303Interrupt Notes
     304===============
     305ckinit.c:
     306        Occasional network lockups have been noted when the PIT has a higher
     307interrupt request level than the CPM.  The SCC1 bit in the CISR is set
     308even though the SCC1 interrupt handler is not active.  This blocks
     309interrupts from SCC1 (and all other CPM sources) and locks up the
     310system.  It has not been determined whether the error is within the
     31168360 or in the RTEMS interrupt support assembler code.  The solution,
     312for now, is to set both PIT and CPM interrupt request levels to the same
     313value (4).
     314
     315
  • c/src/lib/libbsp/m68k/gen68360/clock/ckinit.c

    r1249edfa r35ece2e  
    3636
    3737#define CLOCK_VECTOR    120
    38 #define CLOCK_IRQ_LEVEL 6
     38#define CLOCK_IRQ_LEVEL 4
    3939
    4040/*
  • c/src/lib/libbsp/m68k/gen68360/network/network.c

    r1249edfa r35ece2e  
    365365                                        M360_BD_RETRY_LIMIT |
    366366                                        M360_BD_UNDERRUN)) {
     367                                int j;
     368
    367369                                if (status & M360_BD_LATE_COLLISION)
    368370                                        scc_softc[0].txLateCollision++;
     
    373375
    374376                                /*
     377                                 * Reenable buffer descriptors
     378                                 */
     379                                j = sc->txBdTail;
     380                                for (;;) {
     381                                        status = (sc->txBdBase + j)->status;
     382                                        if (status & M360_BD_READY)
     383                                                break;
     384                                        (sc->txBdBase + j)->status = M360_BD_READY |
     385                                                (status & (M360_BD_PAD |
     386                                                           M360_BD_WRAP |
     387                                                           M360_BD_INTERRUPT |
     388                                                           M360_BD_LAST |
     389                                                           M360_BD_TX_CRC));
     390                                        if (status & M360_BD_LAST)
     391                                                break;
     392                                        if (++j == sc->txBdCount)
     393                                                j = 0;
     394                                }
     395
     396                                /*
     397                                 * Move transmitter back to the first
     398                                 * buffer descriptor in the frame.
     399                                 */
     400                                m360.scc1p._tbptr = m360.scc1p.tbase +
     401                                        sc->txBdTail * sizeof (m360BufferDescriptor_t);
     402
     403                                /*
    375404                                 * Restart the transmitter
    376405                                 */
    377406                                M360ExecuteRISC (M360_CR_OP_RESTART_TX | M360_CR_CHAN_SCC1);
     407                                continue;
    378408                        }
    379409                        if (status & M360_BD_DEFER)
Note: See TracChangeset for help on using the changeset viewer.