Changeset 2928e82 in rtems


Ignore:
Timestamp:
Feb 15, 2008, 7:10:49 AM (12 years ago)
Author:
Ralf Corsepius <ralf.corsepius@…>
Branches:
4.8
Children:
174eea53
Parents:
56535aa
Message:

2008-02-15 Ralf Corsépius <ralf.corsepius@…>

  • clock/ckinit.c, console/duart.c, timer/timer.c: Reflect changes to rtems/motorola/*.h.
Location:
c/src/lib/libbsp/m68k/idp
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/m68k/idp/ChangeLog

    r56535aa r2928e82  
     12008-02-15      Ralf Corsépius <ralf.corsepius@rtems.org>
     2
     3        * clock/ckinit.c, console/duart.c, timer/timer.c: Reflect changes
     4          to rtems/motorola/*.h.
     5
    162007-06-22      Joel Sherrill <joel.sherrill@OARcorp.com>
    27
  • c/src/lib/libbsp/m68k/idp/clock/ckinit.c

    r56535aa r2928e82  
    6868  Clock_driver_ticks += 1;
    6969  /* acknowledge interrupt
    70         TSR = 1; */
    71   MC68230_WRITE (TSR, 1);
     70        MC68230_TSR = 1; */
     71  MC68230_WRITE (MC68230_TSR, 1);
    7272
    7373  if ( Clock_isrs == 1 ) {
     
    8787{
    8888        /* Disable timer */
    89         MC68230_WRITE (TCR, 0x00);
     89        MC68230_WRITE (MC68230_TCR, 0x00);
    9090}
    9191
     
    100100
    101101  /* Disable timer for initialization */
    102   MC68230_WRITE (TCR, 0x00);
     102  MC68230_WRITE (MC68230_TCR, 0x00);
    103103
    104104  /* some PI/T initialization stuff here -- see comment in the ckisr.c
    105105     file in this directory to understand why I use the values that I do */
    106106  /* Set up the interrupt vector on the MC68230 chip:
    107   TIVR = CLOCK_VECTOR; */
    108   MC68230_WRITE (TIVR, CLOCK_VECTOR);
     107  MC68230_TIVR = CLOCK_VECTOR; */
     108  MC68230_WRITE (MC68230_TIVR, CLOCK_VECTOR);
    109109
    110110  /* Set CPRH through CPRL to 193 (not 203) decimal for countdown--see ckisr.c
     
    112112        CPRM = 0x00;
    113113        CPRL = 0xC1; */
    114   MC68230_WRITE (CPRH, 0x00);
    115   MC68230_WRITE (CPRM, 0x00);
    116   MC68230_WRITE (CPRL, 0xC1);
     114  MC68230_WRITE (MC68230_CPRH, 0x00);
     115  MC68230_WRITE (MC68230_CPRM, 0x00);
     116  MC68230_WRITE (MC68230_CPRL, 0xC1);
    117117
    118118  /* Enable timer and use it as an external periodic interrupt generator
    119         TCR = 0xA1; */
     119        MC68230_TCR = 0xA1; */
    120120/*    led_putnum('a'); * for debugging purposes */
    121   MC68230_WRITE (TCR, 0xA1);
     121  MC68230_WRITE (MC68230_TCR, 0xA1);
    122122
    123123  /*
     
    135135        data = TCR;
    136136        TCR = (data & 0xFE); */
    137   MC68230_READ (TCR, data);
    138   MC68230_WRITE (TCR, (data & 0xFE));
     137  MC68230_READ (MC68230_TCR, data);
     138  MC68230_WRITE (MC68230_TCR, (data & 0xFE));
    139139
    140140  /* do not restore old vector */
  • c/src/lib/libbsp/m68k/idp/console/duart.c

    r56535aa r2928e82  
    5959   *  install ISR for ports A and B
    6060   */
    61   set_vector(C_Receive_ISR, (VECT+H3VECT), 1);
     61  set_vector(C_Receive_ISR, (MC68230_VECT+MC68230_H3VECT), 1);
    6262
    6363  /*
     
    7171   *  turn on all ports
    7272   */
    73   MC68230_WRITE(PGCR, 0x00);
    74   MC68230_WRITE(PSRR, 0x18);
    75   MC68230_WRITE(PBDDR, 0x00);
    76   MC68230_WRITE(PBCR, 0x82);
    77   MC68230_WRITE(PIVR, VECT);
    78   MC68230_WRITE(PGCR, 0x20);
     73  MC68230_WRITE(MC68230_PGCR, 0x00);
     74  MC68230_WRITE(MC68230_PSRR, 0x18);
     75  MC68230_WRITE(MC68230_PBDDR, 0x00);
     76  MC68230_WRITE(MC68230_PBCR, 0x82);
     77  MC68230_WRITE(MC68230_PIVR, MC68230_VECT);
     78  MC68230_WRITE(MC68230_PGCR, 0x20);
    7979
    8080  /*
     
    187187   *  Clear pit interrupt.
    188188   */
    189   _addr = (unsigned char *) (PIT_ADDR + PITSR);
     189  _addr = (unsigned char *) (MC68230_PIT_ADDR + MC68230_PITSR);
    190190  *_addr = 0x04;
    191191
  • c/src/lib/libbsp/m68k/idp/timer/timer.c

    r56535aa r2928e82  
    4646  /* Set up the interrupt vector on the MC68230 chip:
    4747     TIVR = TIMER_VECTOR; */
    48   MC68230_WRITE (TIVR, TIMER_VECTOR);
     48  MC68230_WRITE (MC68230_TIVR, TIMER_VECTOR);
    4949
    5050  /* Set CPRH through CPRL to maximum count to reduce interrupt overhead
     
    5252      CPRM = 0xFF;
    5353      CPRL = 0xFF; */
    54   MC68230_WRITE (CPRH, 0xFF);
    55   MC68230_WRITE (CPRM, 0xFF);
    56   MC68230_WRITE (CPRL, 0xFF);
     54  MC68230_WRITE (MC68230_CPRH, 0xFF);
     55  MC68230_WRITE (MC68230_CPRM, 0xFF);
     56  MC68230_WRITE (MC68230_CPRL, 0xFF);
    5757
    5858  /* Enable timer and use it as an external periodic interrupt generator
    5959      TCR = 0xA1; */
    60   MC68230_WRITE (TCR, 0xA1);
     60  MC68230_WRITE (MC68230_TCR, 0xA1);
    6161
    6262}
     
    7272
    7373  /* Disable timer so that timer can be read
    74         data = TCR;
    75         TCR = (data & 0xFE); */
    76   MC68230_READ (TCR, data);
    77   MC68230_WRITE (TCR, (data & 0xFE));
     74        data = MC68230_TCR;
     75        MC68230_TCR = (data & 0xFE); */
     76  MC68230_READ (MC68230_TCR, data);
     77  MC68230_WRITE (MC68230_TCR, (data & 0xFE));
    7878
    7979  /* Read the counter value
    80         msb = CNTRH;
    81         osb = CNTRM;
    82         lsb = CNTRL; */
    83   MC68230_READ (CNTRH, msb);
    84   MC68230_READ (CNTRM, osb);
    85   MC68230_READ (CNTRL, lsb);
     80        msb = MC68230_CNTRH;
     81        osb = MC68230_CNTRM;
     82        lsb = MC68230_CNTRL; */
     83  MC68230_READ (MC68230_CNTRH, msb);
     84  MC68230_READ (MC68230_CNTRM, osb);
     85  MC68230_READ (MC68230_CNTRL, lsb);
    8686
    8787  /* Calculate the time so far */
     
    9090
    9191  /* Enable timer so that timer can continue
    92                 TCR = 0xA1; */
    93   MC68230_WRITE (TCR, 0xA1);
     92                MC68230_TCR = 0xA1; */
     93  MC68230_WRITE (MC68230_TCR, 0xA1);
    9494
    9595  /* do not restore old vector */
Note: See TracChangeset for help on using the changeset viewer.