Changeset 847fc79 in rtems


Ignore:
Timestamp:
Feb 7, 2014, 8:32:31 AM (7 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, 5, master
Children:
01794eb
Parents:
7579e25
Message:

Revert "bsp/leon3: New BSP variant leon3_qemu"

This reverts commit 7579e255127ee0cf04901bbab6c1538559053508.

Improve QEMU to support AMBA plug and play instead.

Location:
c/src/lib/libbsp/sparc/leon3
Files:
2 deleted
7 edited

Legend:

Unmodified
Added
Removed
  • c/src/lib/libbsp/sparc/leon3/Makefile.am

    r7579e25 r847fc79  
    2727dist_project_lib_DATA += startup/linkcmds
    2828dist_project_lib_DATA += startup/linkcmds.leon3
    29 dist_project_lib_DATA += startup/linkcmds.leon3_qemu
    3029dist_project_lib_DATA += startup/linkcmds.ngmp
    3130
  • c/src/lib/libbsp/sparc/leon3/amba/amba.c

    r7579e25 r847fc79  
    4040void amba_initialize(void)
    4141{
    42 #ifndef LEON3_QEMU
    4342  int icsel;
    4443  struct ambapp_dev *adev;
     
    9291                     (LEON3_Timer_Regs->scaler_reload + 1) * 1000000);
    9392  }
    94 #else /* LEON3_QEMU */
    95   LEON3_IrqCtrl_Regs = (volatile struct irqmp_regs *)0x80000200;
    96 #endif /* LEON3_QEMU */
    9793}
  • c/src/lib/libbsp/sparc/leon3/clock/ckinit.c

    r7579e25 r847fc79  
    5656#endif
    5757
    58 #ifndef LEON3_QEMU
    5958#define Clock_driver_support_find_timer() \
    6059  do { \
     
    7372    } \
    7473  } while (0)
    75 #else /* LEON3_QEMU */
    76 #define Clock_driver_support_find_timer() \
    77   do { \
    78     LEON3_Timer_Regs = (volatile struct gptimer_regs *) \
    79                        0x80000300; \
    80     clkirq = 6; \
    81   } while (0)
    82 #endif /* LEON3_QEMU */
    8374
    8475#define Clock_driver_support_install_isr( _new, _old ) \
     
    8778  } while(0)
    8879
    89 #ifndef LEON3_QEMU
    9080#define Clock_driver_support_initialize_hardware() \
    9181  do { \
     
    9787        LEON3_GPTIMER_LD | LEON3_GPTIMER_IRQEN; \
    9888  } while (0)
    99 #else
    100 #define Clock_driver_support_initialize_hardware() \
    101   do { \
    102     LEON3_Timer_Regs->timer[LEON3_CLOCK_INDEX].reload = \
    103       40 * (rtems_configuration_get_microseconds_per_tick() - 1); \
    104     \
    105     LEON3_Timer_Regs->timer[LEON3_CLOCK_INDEX].ctrl = \
    106       LEON3_GPTIMER_EN | LEON3_GPTIMER_RL | \
    107         LEON3_GPTIMER_LD | LEON3_GPTIMER_IRQEN; \
    108   } while (0)
    109 #endif
    11089
    11190#define Clock_driver_support_shutdown_hardware() \
     
    123102    return 0;
    124103
    125 #ifndef LEON3_QEMU
    126104  clicks = LEON3_Timer_Regs->timer[LEON3_CLOCK_INDEX].value;
    127 #else
    128   clicks = LEON3_Timer_Regs->timer[LEON3_CLOCK_INDEX].value / 40;
    129 #endif
    130105
    131106  if ( LEON_Is_interrupt_pending( clkirq ) ) {
  • c/src/lib/libbsp/sparc/leon3/configure.ac

    r7579e25 r847fc79  
    2727better.])
    2828
    29 RTEMS_BSPOPTS_SET([SIMSPARC_FAST_IDLE],[*qemu],[1])
    3029RTEMS_BSPOPTS_SET([SIMSPARC_FAST_IDLE],[*],[])
    3130RTEMS_BSPOPTS_HELP([SIMSPARC_FAST_IDLE],
     
    3938 determining the CPU core number in an SMP configuration.])
    4039
    41 RTEMS_BSPOPTS_SET([LEON3_QEMU],[*qemu],[1])
    42 RTEMS_BSPOPTS_HELP([LEON3_QEMU],
    43 [If defined, then use settings for QEMU simulator.])
    44 
    4540RTEMS_BSP_CLEANUP_OPTIONS(0, 1)
    4641RTEMS_BSP_LINKCMDS
  • c/src/lib/libbsp/sparc/leon3/console/console.c

    r7579e25 r847fc79  
    218218}
    219219
    220 #ifndef LEON3_QEMU
    221220/* AMBA PP find routine. Extract AMBA PnP information into data structure. */
    222221static int find_matching_apbuart(struct ambapp_dev *dev, int index, void *arg)
     
    250249                  GAISLER_APBUART, find_matching_apbuart, NULL);
    251250}
    252 #else /* LEON3_QEMU */
    253 static void leon3_console_scan_uarts(void)
    254 {
    255   uarts = 1;
    256 
    257   apbuarts[0].regs = (struct apbuart_regs *)0x80000100;
    258 #if CONSOLE_USE_INTERRUPTS
    259   apbuarts[0].irq = 3;
    260 #endif
    261   apbuarts[0].freq_hz = 40000000;
    262 }
    263 #endif /* LEON3_QEMU */
    264251
    265252/*
  • c/src/lib/libbsp/sparc/leon3/console/printk_support.c

    r7579e25 r847fc79  
    2626static struct apbuart_regs *dbg_uart = NULL;
    2727
    28 #ifndef LEON3_QEMU
    2928/* Before UART driver has registered (or when no UART is available), calls to
    3029 * printk that gets to bsp_out_char() will be filling data into the
     
    7574  }
    7675}
    77 #else
    78 static void bsp_out_char(char c);
    79 
    80 static void leon3_qemu_debug_uart_init(char c)
    81 {
    82   bsp_debug_uart_init();
    83 
    84   BSP_output_char = bsp_out_char;
    85 
    86   bsp_out_char(c);
    87 }
    88 
    89 void bsp_debug_uart_init(void)
    90 {
    91   dbg_uart = (struct apbuart_regs *)0x80000100;
    92   dbg_uart->ctrl |= LEON_REG_UART_CTRL_RE | LEON_REG_UART_CTRL_TE;
    93   dbg_uart->status = 0;
    94 }
    95 #endif
    9676
    9777/*
     
    149129static void bsp_out_char(char c)
    150130{
    151 #ifndef LEON3_QEMU
    152131  if (dbg_uart == NULL) {
    153132    /* Local debug buffer when UART driver has not registered */
     
    156135    return;
    157136  }
    158 #endif
    159137
    160138  apbuart_outbyte_polled(dbg_uart, c, 1, 1);
     
    167145#include <rtems/bspIo.h>
    168146
    169 #ifndef LEON3_QEMU
    170147BSP_output_char_function_type BSP_output_char = bsp_out_char;
    171 #else
    172 BSP_output_char_function_type BSP_output_char = leon3_qemu_debug_uart_init;
    173 #endif
    174148
    175149static int bsp_in_char(void)
  • c/src/lib/libbsp/sparc/leon3/preinstall.am

    r7579e25 r847fc79  
    8282PREINSTALL_FILES += $(PROJECT_LIB)/linkcmds.leon3
    8383
    84 $(PROJECT_LIB)/linkcmds.leon3_qemu: startup/linkcmds.leon3_qemu $(PROJECT_LIB)/$(dirstamp)
    85         $(INSTALL_DATA) $< $(PROJECT_LIB)/linkcmds.leon3_qemu
    86 PREINSTALL_FILES += $(PROJECT_LIB)/linkcmds.leon3_qemu
    87 
    8884$(PROJECT_LIB)/linkcmds.ngmp: startup/linkcmds.ngmp $(PROJECT_LIB)/$(dirstamp)
    8985        $(INSTALL_DATA) $< $(PROJECT_LIB)/linkcmds.ngmp
Note: See TracChangeset for help on using the changeset viewer.