Changeset 2d0383b in rtems


Ignore:
Timestamp:
Oct 14, 1996, 7:17:37 PM (25 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
752cd8f
Parents:
355c262c
Message:

patches to erc32.h to correct handling of timer mirror from Jiri Gaisler.

Location:
c/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • c/src/exec/score/cpu/sparc/erc32.h

    r355c262c r2d0383b  
    428428 *          0 = hold scaler and counter
    429429 *
    430  *    D2 - Scaler Load
     430 *    D3 - Scaler Load
    431431 *          1 = load scalar with preset value and restart
    432432 *          0 = no function
     
    470470      _control = _ERC32_MEC_Timer_Control_Mirror; \
    471471      _control &= ERC32_MEC_TIMER_COUNTER_DEFINED_MASK << 8; \
    472       _ERC32_MEC_Timer_Control_Mirror = _control | _value; \
     472      _ERC32_MEC_Timer_Control_Mirror = _control | __value; \
    473473      _control &= (ERC32_MEC_TIMER_COUNTER_CURRENT_MODE_MASK << 8); \
    474474      _control |= __value; \
     
    480480#define ERC32_MEC_Get_General_Purpose_Timer_Control( _value ) \
    481481  do { \
    482     (_value) = _ERC32_MEC_Timer_Control_Mirror & 0xf; \
     482    (_value) = (_ERC32_MEC_Timer_Control_Mirror >> 8) & 0xf; \
    483483  } while ( 0 )
    484484
  • c/src/lib/libcpu/sparc/include/erc32.h

    r355c262c r2d0383b  
    428428 *          0 = hold scaler and counter
    429429 *
    430  *    D2 - Scaler Load
     430 *    D3 - Scaler Load
    431431 *          1 = load scalar with preset value and restart
    432432 *          0 = no function
     
    470470      _control = _ERC32_MEC_Timer_Control_Mirror; \
    471471      _control &= ERC32_MEC_TIMER_COUNTER_DEFINED_MASK << 8; \
    472       _ERC32_MEC_Timer_Control_Mirror = _control | _value; \
     472      _ERC32_MEC_Timer_Control_Mirror = _control | __value; \
    473473      _control &= (ERC32_MEC_TIMER_COUNTER_CURRENT_MODE_MASK << 8); \
    474474      _control |= __value; \
     
    480480#define ERC32_MEC_Get_General_Purpose_Timer_Control( _value ) \
    481481  do { \
    482     (_value) = _ERC32_MEC_Timer_Control_Mirror & 0xf; \
     482    (_value) = (_ERC32_MEC_Timer_Control_Mirror >> 8) & 0xf; \
    483483  } while ( 0 )
    484484
Note: See TracChangeset for help on using the changeset viewer.