Ignore:
Timestamp:
May 5, 2009, 4:18:06 PM (11 years ago)
Author:
Jennifer Averett <Jennifer.Averett@…>
Branches:
4.9
Children:
8e230e6
Parents:
56e12a17
Message:

2009-05-05 Jennifer Averett <jennifer.averett@…>

  • Makefile.am, README, configure.ac, preinstall.am, PCI_bus/PCI.c, PCI_bus/PCI.h, PCI_bus/flash.c, PCI_bus/universe.c, console/85c30.c, console/85c30.h, console/console.c, console/consolebsp.h, console/tbl85c30.c, include/bsp.h, include/coverhd.h, include/gen2.h, include/irq-config.h, include/tm27.h, irq/FPGA.c, irq/irq.h, irq/irq_init.c, start/start.S, startup/Hwr_init.c, startup/bspstart.c, timer/timer.c, tod/tod.c: Updated and tested with the latest powerpc isr source
  • irq/no_pic.c: New file.
  • irq/irq.c, startup/genpvec.c, startup/setvec.c, startup/vmeintr.c: Removed.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/powerpc/score603e/startup/bspstart.c

    r56e12a17 r31a5ec8  
    66 *  before any of these are invoked.
    77 *
    8  *  COPYRIGHT (c) 1989-2007.
     8 *  COPYRIGHT (c) 1989-2009.
    99 *  On-Line Applications Research Corporation (OAR).
    1010 *
    11  *  The license and distribution terms for this file may in
    12  *  the file LICENSE in this distribution or at
     11 *  The license and distribution terms for this file may be
     12 *  found in the file LICENSE in this distribution or at
    1313 *  http://www.rtems.com/license/LICENSE.
    1414 *
    15  *  $Id:
     15 *  $Id$
    1616 */
    1717
     
    2323#include <rtems/bspIo.h>
    2424#include <libcpu/cpuIdent.h>
    25 #define DEBUG 1
     25
     26#define DEBUG 0
    2627
    2728/*
     
    3334 * PCI Bus Frequency
    3435 */
    35 unsigned int BSP_bus_frequency;  /* XXX - Set this based upon the Score board */
     36unsigned int BSP_bus_frequency; 
    3637
    3738/*
    3839 * processor clock frequency
    3940 */
    40 unsigned int BSP_processor_frequency; /* XXX - Set this based upon the Score board */
     41unsigned int BSP_processor_frequency;
    4142
    4243/*
     
    9192  uint32_t         heap_size;
    9293
    93   #if DEBUG
    94     printk("bsp_pretasking_hook: Set Heap\n");
    95   #endif
    96   heap_start = (uint32_t) &end;
    97   if (heap_start & (CPU_ALIGNMENT-1))
    98     heap_start = (heap_start + CPU_ALIGNMENT) & ~(CPU_ALIGNMENT-1);
    99 
    100   heap_size = Configuration.work_space_start - (void *)&end;
     94  heap_start = (BSP_heap_start + CPU_ALIGNMENT - 1) & ~(CPU_ALIGNMENT-1);
     95  heap_size = (uint32_t) &RAM_END;
     96  heap_size = heap_size - heap_start - Configuration.work_space_size;
    10197  heap_size &= 0xfffffff0;  /* keep it as a multiple of 16 bytes */
     98 
     99
     100  #if DEBUG
     101    printk("bsp_pretasking_hook: Set Heap start 0x%x size 0x%x\n", heap_start, heap_size);
     102  #endif
    102103
    103104  #if DEBUG
     
    122123void bsp_predriver_hook(void)
    123124{
     125  init_PCI();
     126  initialize_universe();
     127
     128  #if DEBUG
     129    printk("bsp_predriver_hook: initialize_PCI_bridge\n");
     130  #endif
     131  initialize_PCI_bridge ();
    124132
    125133#if (HAS_PMC_PSC8)
     
    182190void bsp_postdriver_hook(void)
    183191{
    184   extern void Init_EE_mask_init(void);
    185192  extern void open_dev_console(void);
    186193  #if DEBUG
     
    188195  #endif
    189196  open_dev_console();
    190 
    191   #if DEBUG
    192     printk("bsp_postdriver_hook: Init_EE_mask_init\n");
    193   #endif
    194   Init_EE_mask_init();
    195197  #if DEBUG
    196198    printk("bsp_postdriver_hook: Finished procedure\n");
     
    251253  intrStackSize = rtems_configuration_get_interrupt_stack_size();
    252254  BSP_heap_start = intrStackStart + intrStackSize;
     255  printk("Interrupt Stack Start: 0x%x Size: 0x%x  Heap Start: 0x%x\n",
     256    intrStackStart, intrStackSize, BSP_heap_start
     257  );
    253258
    254259  /*
     
    260265    intrStackSize
    261266  );
    262   #if DEBUG
    263     printk("bsp_predriver_hook: init_RTC\n");
    264   #endif
    265 
    266 /*   init_RTC(); */
    267   init_PCI();
    268   initialize_universe();
    269 
    270   #if DEBUG
    271     printk("bsp_predriver_hook: initialize_PCI_bridge\n");
    272   #endif
    273   initialize_PCI_bridge ();
    274267
    275268  msr_value = 0x2030;
    276269  _CPU_MSR_SET( msr_value );
    277 
    278270
    279271  _CPU_MSR_SET( msr_value );
     
    284276   *  not malloc'ed.  It is just "pulled from the air".
    285277   */
    286 
    287   #if DEBUG
    288     printk("bsp_start: Calculate Wrokspace\n");
    289   #endif
    290278  work_space_start =
    291279    (unsigned char *)&RAM_END - rtems_configuration_get_work_space_size();
     280  printk("Work Space Start: 0x%x\n", work_space_start );
    292281
    293282  if ( work_space_start <= (unsigned char *)&end ) {
     
    306295  bsp_clicks_per_usec = 66 / 4;  /* XXX get from linkcmds */
    307296
    308 #if ( PPC_USE_DATA_CACHE )
    309   #if DEBUG
    310     printk("bsp_start: cache_enable\n");
    311   #endif
    312   instruction_cache_enable ();
    313   data_cache_enable ();
    314   #if DEBUG
    315     printk("bsp_start: END PPC_USE_DATA_CACHE\n");
    316   #endif
    317 #endif
    318 
    319   /* Initalize interrupt support */
    320   if (bsp_interrupt_initialize() != RTEMS_SUCCESSFUL) {
    321     BSP_panic( "Cannot intitialize interrupt support\n");
    322   }
    323 
     297  #if ( PPC_USE_DATA_CACHE )
     298    #if DEBUG
     299      printk("bsp_start: cache_enable\n");
     300    #endif
     301    instruction_cache_enable ();
     302    data_cache_enable ();
     303    #if DEBUG
     304      printk("bsp_start: END PPC_USE_DATA_CACHE\n");
     305    #endif
     306  #endif
     307
     308  /*
     309   * Initalize RTEMS IRQ system
     310   */
     311  #if DEBUG 
     312    printk("bspstart: Call BSP_rtems_irq_mng_init\n");
     313  #endif
     314  BSP_rtems_irq_mng_init(0);
     315 
    324316  #if DEBUG
    325317    printk("bsp_start: end BSPSTART\n");
    326   ShowBATS();
    327   #endif
    328 }
     318    ShowBATS();
     319  #endif
     320}
Note: See TracChangeset for help on using the changeset viewer.