Changeset f309cda in rtems


Ignore:
Timestamp:
Apr 11, 2005, 8:20:18 PM (15 years ago)
Author:
Jennifer Averett <Jennifer.Averett@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
5c68bf8
Parents:
b6b9bbf
Message:

2005-04-11 Jennifer Averett<jennifer.averett@…>

PR 778/bsps

  • include/bsp.h, include/gen2.h, startup/FPGA.c, startup/Hwr_init.c, startup/bspstart.c, tod/tod.c: modify SCORE_.. to BSP_.. for externally used define's.
Location:
c/src/lib/libbsp/powerpc/score603e
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/powerpc/score603e/ChangeLog

    rb6b9bbf rf309cda  
     12005-04-11      Jennifer Averett<jennifer.averett@oarcorp.com>
     2
     3        PR 778/bsps
     4        * include/bsp.h, include/gen2.h, startup/FPGA.c, startup/Hwr_init.c,
     5        startup/bspstart.c, tod/tod.c:
     6        modify SCORE_.. to BSP_.. for externally used define's.
     7
    182005-02-16      Ralf Corsepius <ralf.corsepius@rtems.org>
    29
  • c/src/lib/libbsp/powerpc/score603e/include/bsp.h

    rb6b9bbf rf309cda  
    7070#define Initialize_Board_ctrl_register()                         \
    7171  *SCORE603E_BOARD_CTRL_REG = (*SCORE603E_BOARD_CTRL_REG |       \
    72                                SCORE603E_BRD_FLASH_DISABLE_MASK) \
     72                               SCORE603E_BRD_FLASH_DISABLE_MASK)
     73
     74#define Processor_Synchronize() \
     75  asm(" eieio ")
     76
    7377
    7478/* Constants */
     
    205209);
    206210
     211#define BSP_FLASH_ENABLE_WRITES( _area) SCORE603e_FLASH_Enable_writes( _area )
     212#define BSP_FLASH_DISABLE_WRITES(_area) SCORE603e_FLASH_Disable( _area )
     213
    207214#define Convert_Endian_32( _data ) \
    208215  ( ((_data&0x000000ff)<<24) | ((_data&0x0000ff00)<<8) |  \
  • c/src/lib/libbsp/powerpc/score603e/include/gen2.h

    rb6b9bbf rf309cda  
    2626 */
    2727#define SCORE603E_VME_JUMPER_ADDR      0x00e20000
    28 #define SCORE603E_FLASH_BASE_ADDR      0x04000000
     28#define BSP_FLASH_BASE                 0x04000000
    2929#define SCORE603E_ISA_PCI_IO_BASE      0x80000000
    3030#define SCORE603E_TIMER_PORT_C         0xfd000000
     
    4848 * PSC8 - PMC Card
    4949 */
    50 #define SCORE603E_PCI_CONFIGURATION_BASE   0x80800000
    51 #define SCORE603E_PMC_BASE                 SCORE603E_PCI_CONFIGURATION_BASE
    52 #define SCORE603E_PCI_PMC_DEVICE_BASE      0x80808000
    53 
    54 #define SCORE603E_PCI_REGISTER_BASE        0xfc000000
    55 
    56 #define SCORE603E_PCI_DEVICE_ADDRESS( _offset) \
    57          ((volatile uint32_t*)( SCORE603E_PCI_PMC_DEVICE_BASE + _offset ))
    58 
    59 #define SCORE603E_PMC_SERIAL_ADDRESS( _offset )    \
    60         ((volatile uint8_t*)(SCORE603E_PCI_REGISTER_BASE + _offset))
     50#define BSP_PCI_CONFIGURATION_BASE   0x80800000
     51#define BSP_PMC_BASE                 BSP_PCI_CONFIGURATION_BASE
     52#define BSP_PCI_PMC_DEVICE_BASE      0x80808000
     53
     54#define BSP_PCI_REGISTER_BASE        0xfc000000
     55
     56#define BSP_PCI_DEVICE_ADDRESS( _offset) \
     57         ((volatile rtems_unsigned32 *)( BSP_PCI_PMC_DEVICE_BASE + _offset ))
     58
     59
     60#define BSP_PMC_SERIAL_ADDRESS( _offset )    \
     61        ((volatile rtems_unsigned8 *)(BSP_PCI_REGISTER_BASE + _offset))
    6162
    6263/*
    6364 * PMC serial channels - (4-7: 232 and 8-11: 422)
    6465 */
    65 #define SCORE603E_85C30_CTRL_4        SCORE603E_PMC_SERIAL_ADDRESS(0x200020)
    66 #define SCORE603E_85C30_DATA_4        SCORE603E_PMC_SERIAL_ADDRESS(0x200024)
    67 #define SCORE603E_85C30_CTRL_5        SCORE603E_PMC_SERIAL_ADDRESS(0x200028)
    68 #define SCORE603E_85C30_DATA_5        SCORE603E_PMC_SERIAL_ADDRESS(0x20002c)
    69 #define SCORE603E_85C30_CTRL_6        SCORE603E_PMC_SERIAL_ADDRESS(0x200030)
    70 #define SCORE603E_85C30_DATA_6        SCORE603E_PMC_SERIAL_ADDRESS(0x200034)
    71 #define SCORE603E_85C30_CTRL_7        SCORE603E_PMC_SERIAL_ADDRESS(0x200038)
    72 #define SCORE603E_85C30_DATA_7        SCORE603E_PMC_SERIAL_ADDRESS(0x20003c)
    73 #define SCORE603E_85C30_CTRL_8        SCORE603E_PMC_SERIAL_ADDRESS(0x200000)
    74 #define SCORE603E_85C30_DATA_8        SCORE603E_PMC_SERIAL_ADDRESS(0x200004)
    75 #define SCORE603E_85C30_CTRL_9        SCORE603E_PMC_SERIAL_ADDRESS(0x200008)
    76 #define SCORE603E_85C30_DATA_9        SCORE603E_PMC_SERIAL_ADDRESS(0x20000c)
    77 #define SCORE603E_85C30_CTRL_10       SCORE603E_PMC_SERIAL_ADDRESS(0x200010)
    78 #define SCORE603E_85C30_DATA_10       SCORE603E_PMC_SERIAL_ADDRESS(0x200014)
    79 #define SCORE603E_85C30_CTRL_11       SCORE603E_PMC_SERIAL_ADDRESS(0x200018)
    80 #define SCORE603E_85C30_DATA_11       SCORE603E_PMC_SERIAL_ADDRESS(0x20001c)
     66#define SCORE603E_85C30_CTRL_4        BSP_PMC_SERIAL_ADDRESS(0x200020)
     67#define SCORE603E_85C30_DATA_4        BSP_PMC_SERIAL_ADDRESS(0x200024)
     68#define SCORE603E_85C30_CTRL_5        BSP_PMC_SERIAL_ADDRESS(0x200028)
     69#define SCORE603E_85C30_DATA_5        BSP_PMC_SERIAL_ADDRESS(0x20002c)
     70#define SCORE603E_85C30_CTRL_6        BSP_PMC_SERIAL_ADDRESS(0x200030)
     71#define SCORE603E_85C30_DATA_6        BSP_PMC_SERIAL_ADDRESS(0x200034)
     72#define SCORE603E_85C30_CTRL_7        BSP_PMC_SERIAL_ADDRESS(0x200038)
     73#define SCORE603E_85C30_DATA_7        BSP_PMC_SERIAL_ADDRESS(0x20003c)
     74#define SCORE603E_85C30_CTRL_8        BSP_PMC_SERIAL_ADDRESS(0x200000)
     75#define SCORE603E_85C30_DATA_8        BSP_PMC_SERIAL_ADDRESS(0x200004)
     76#define SCORE603E_85C30_CTRL_9        BSP_PMC_SERIAL_ADDRESS(0x200008)
     77#define SCORE603E_85C30_DATA_9        BSP_PMC_SERIAL_ADDRESS(0x20000c)
     78#define SCORE603E_85C30_CTRL_10       BSP_PMC_SERIAL_ADDRESS(0x200010)
     79#define SCORE603E_85C30_DATA_10       BSP_PMC_SERIAL_ADDRESS(0x200014)
     80#define SCORE603E_85C30_CTRL_11       BSP_PMC_SERIAL_ADDRESS(0x200018)
     81#define SCORE603E_85C30_DATA_11       BSP_PMC_SERIAL_ADDRESS(0x20001c)
    8182
    8283#define SCORE603E_PCI_IO_CFG_ADDR      0x80000cf8
     
    8586#define SCORE603E_UNIVERSE_BASE        0x80030000
    8687#define SCORE603E_IO_VME_UNIVERSE_BASE 0x80007000
    87 #define SCORE603E_PCI_MEM_BASE         0xc0000000
    88 #define SCORE603E_NVRAM_BASE           0xfd100000
    89 #define SCORE603E_RTC_ADDRESS          ((volatile unsigned char *)0xfd180000)
     88#define BSP_PCI_MEM_BASE         0xc0000000
     89#define BSP_NVRAM_BASE           0xfd100000
     90#define BSP_RTC_ADDRESS          ((volatile unsigned char *)0xfd180000)
    9091#define SCORE603E_JP1_JP2_PROM_BASE    0xfff00000
    9192#define SCORE603E_NOT_JP1_2_FLASH_BASE 0xff800000
     
    9697#define SCORE603E_VME_A16_OFFSET       0x11000000
    9798#define SCORE603E_VME_A24_OFFSET       0x10000000
    98 #define SCORE603E_VME_A24_BASE         (SCORE603E_PCI_MEM_BASE+SCORE603E_VME_A24_OFFSET)
     99#define BSP_VME_A24_BASE               (BSP_PCI_MEM_BASE+SCORE603E_VME_A24_OFFSET)
    99100#else
    100101#error "SCORE603E gen2.h -- what ROM monitor are you using"
    101102#endif
    102103
    103 #define SCORE603E_VME_A16_BASE         (SCORE603E_PCI_MEM_BASE+SCORE603E_VME_A16_OFFSET)
     104#define BSP_VME_A16_BASE         (BSP_PCI_MEM_BASE+SCORE603E_VME_A16_OFFSET)
    104105
    105106/*
     
    114115#define ICM1770_CRYSTAL_FREQ_4M       0x03
    115116
    116 #define SCORE_RTC_FREQUENCY           ICM1770_CRYSTAL_FREQ_32K
     117#define BSP_RTC_FREQUENCY           ICM1770_CRYSTAL_FREQ_32K
    117118
    118119/*
     
    156157 * The PMC status word is at the PMC base address
    157158 */
    158 #define SCORE603E_PMC_STATUS_ADDRESS  (SCORE603E_PMC_SERIAL_ADDRESS (0))
     159#define BSP_PMC_STATUS_ADDRESS  (BSP_PMC_SERIAL_ADDRESS (0))
    159160#define Is_PMC_85C30_4_IRQ( _status ) (_status & 0x80)    /* SCC 422-1 */
    160161#define Is_PMC_85C30_2_IRQ( _status ) (_status & 0x40)    /* SCC 232-1 */
     
    162163#define Is_PMC_85C30_3_IRQ( _status ) (_status & 0x08)    /* SCC 232-2 */
    163164
    164 #define SCORE603E_PMC_CONTROL_ADDRESS    SCORE603E_PMC_SERIAL_ADDRESS(0x100000)
     165#define SCORE603E_PMC_CONTROL_ADDRESS    BSP_PMC_SERIAL_ADDRESS(0x100000)
    165166#define SCORE603E_PMC_SCC_232_LOOPBACK (_word) (_word|0x20)
    166167
  • c/src/lib/libbsp/powerpc/score603e/startup/FPGA.c

    rb6b9bbf rf309cda  
    115115  uint16_t            status_word = irq;
    116116
    117   status_word = (*SCORE603E_PMC_STATUS_ADDRESS);
     117  status_word = (*BSP_PMC_STATUS_ADDRESS);
    118118
    119119  return status_word;
  • c/src/lib/libbsp/powerpc/score603e/startup/Hwr_init.c

    rb6b9bbf rf309cda  
    7474  volatile Harris_RTC *the_RTC;
    7575
    76   the_RTC = (volatile Harris_RTC *)SCORE603E_RTC_ADDRESS;
     76  the_RTC = (volatile Harris_RTC *)BSP_RTC_ADDRESS;
    7777
    7878  the_RTC->command_register = 0x0;
  • c/src/lib/libbsp/powerpc/score603e/startup/bspstart.c

    rb6b9bbf rf309cda  
    117117   * set PMC base address.
    118118   */
    119   PMC_addr  = SCORE603E_PCI_DEVICE_ADDRESS( 0x14 );
    120   *PMC_addr = (SCORE603E_PCI_REGISTER_BASE >> 24) & 0x3f;
     119  PMC_addr  = BSP_PCI_DEVICE_ADDRESS( 0x14 );
     120  *PMC_addr = (BSP_PCI_REGISTER_BASE >> 24) & 0x3f;
    121121
    122122  /*
    123123   * Clear status, enable SERR and memory space only.
    124124   */
    125   PMC_addr = SCORE603E_PCI_DEVICE_ADDRESS( 0x4 );
     125  PMC_addr = BSP_PCI_DEVICE_ADDRESS( 0x4 );
    126126  *PMC_addr = 0x0201ff37;
    127127
     
    130130   */
    131131  PMC_addr = (volatile uint32_t*)
    132         SCORE603E_PMC_SERIAL_ADDRESS( 0x100000 );
     132        BSP_PMC_SERIAL_ADDRESS( 0x100000 );
    133133  data = *PMC_addr;
    134134  /*   *PMC_addr = data | 0x3;  */
     
    142142   * Clear status, enable SERR and memory space only.
    143143   */
    144   PMC_addr = SCORE603E_PCI_DEVICE_ADDRESS( 0x4 );
     144  PMC_addr = BSP_PCI_DEVICE_ADDRESS( 0x4 );
    145145  *PMC_addr = 0x020080cc;
    146146
     
    148148   * set PMC base address.
    149149   */
    150   PMC_addr  = SCORE603E_PCI_DEVICE_ADDRESS( 0x14 );
    151   *PMC_addr = (SCORE603E_PCI_REGISTER_BASE >> 24) & 0x3f;
     150  PMC_addr  = BSP_PCI_DEVICE_ADDRESS( 0x14 );
     151  *PMC_addr = (BSP_PCI_REGISTER_BASE >> 24) & 0x3f;
    152152
    153153  PMC_addr = (volatile uint32_t*)
    154       SCORE603E_PMC_SERIAL_ADDRESS( 0x100000 );
     154      BSP_PMC_SERIAL_ADDRESS( 0x100000 );
    155155  data = *PMC_addr;
    156156  *PMC_addr = data & 0xfc;
  • c/src/lib/libbsp/powerpc/score603e/tod/tod.c

    rb6b9bbf rf309cda  
    4444  rtems_time_of_day rtc_tod;
    4545
    46   ICM7170_GetTOD( SCORE603E_RTC_ADDRESS, SCORE_RTC_FREQUENCY, &rtc_tod );
     46  ICM7170_GetTOD( BSP_RTC_ADDRESS, BSP_RTC_FREQUENCY, &rtc_tod );
    4747  rtems_clock_set( &rtc_tod );
    4848}
     
    5353
    5454  rtems_clock_get( RTEMS_CLOCK_GET_TOD, &rtems_tod );
    55   ICM7170_SetTOD( SCORE603E_RTC_ADDRESS, SCORE_RTC_FREQUENCY, &rtems_tod );
     55  ICM7170_SetTOD( BSP_RTC_ADDRESS, BSP_RTC_FREQUENCY, &rtems_tod );
    5656}
    5757
     
    6161  rtems_time_of_day rtc_tod;
    6262
    63   ICM7170_GetTOD( SCORE603E_RTC_ADDRESS, SCORE_RTC_FREQUENCY, &rtc_tod );
     63  ICM7170_GetTOD( BSP_RTC_ADDRESS, BSP_RTC_FREQUENCY, &rtc_tod );
    6464  rtems_clock_get( RTEMS_CLOCK_GET_TOD, &rtems_tod );
    6565
Note: See TracChangeset for help on using the changeset viewer.