Index: c/src/lib/libbsp/arm/acinclude.m4
===================================================================
--- c/src/lib/libbsp/arm/acinclude.m4	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ c/src/lib/libbsp/arm/acinclude.m4	(revision c8a8a6013fc3c02ae58eb343afec00a5954952e5)
@@ -13,6 +13,4 @@
   edb7312 )
     AC_CONFIG_SUBDIRS([edb7312]);;
-  gba )
-    AC_CONFIG_SUBDIRS([gba]);;
   gdbarmsim )
     AC_CONFIG_SUBDIRS([gdbarmsim]);;
Index: src/lib/libbsp/arm/gba/Makefile.am
===================================================================
--- c/src/lib/libbsp/arm/gba/Makefile.am	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,70 +1,0 @@
-ACLOCAL_AMFLAGS = -I ../../../../aclocal
-
-include $(top_srcdir)/../../../../automake/compile.am
-
-include_bspdir = $(includedir)/bsp
-
-dist_project_lib_DATA = bsp_specs
-
-include_HEADERS = include/bsp.h
-include_HEADERS += include/arm_mode_bits.h
-include_HEADERS += include/asm_macros.h
-include_HEADERS += include/gba_registers.h
-include_HEADERS += include/conio.h
-include_HEADERS += ../../shared/include/tm27.h
-include_HEADERS += include/gba.h
-
-include_bsp_HEADERS =
-
-nodist_include_HEADERS = include/bspopts.h
-nodist_include_HEADERS += ../../shared/include/coverhd.h
-nodist_include_bsp_HEADERS = ../../shared/include/bootcard.h
-DISTCLEANFILES = include/bspopts.h
-noinst_PROGRAMS =
-
-noinst_LIBRARIES = libbspstart.a
-libbspstart_a_SOURCES = start/start.S
-project_lib_DATA = start.$(OBJEXT)
-
-dist_project_lib_DATA += startup/linkcmds
-
-noinst_LIBRARIES += libbsp.a
-libbsp_a_SOURCES =
-
-# startup
-libbsp_a_SOURCES += ../../shared/bsplibc.c ../../shared/bsppost.c \
-    startup/bspgetworkarea.c \
-    ../../shared/bsppredriverhook.c ../../shared/bspclean.c \
-    startup/bspreset.c ../../shared/bootcard.c ../../shared/sbrk.c \
-    ../../shared/gnatinstallhandler.c \
-    startup/bspstart.c
-libbsp_a_SOURCES += ../../shared/cpucounterread.c
-libbsp_a_SOURCES += ../../shared/cpucounterdiff.c
-# clock
-libbsp_a_SOURCES += clock/clockdrv.c
-libbsp_a_SOURCES += ../../shared/clockdrv_shell.h
-# console
-libbsp_a_SOURCES += console/conio.c console/console.c \
-    console/defaultfont.h
-# timer
-libbsp_a_SOURCES += timer/timer.c
-
-# irq
-include_bsp_HEADERS += ../../shared/include/irq-generic.h \
-	../../shared/include/irq-info.h \
-	irq/irq.h
-libbsp_a_SOURCES += ../../shared/src/irq-default-handler.c
-libbsp_a_SOURCES += ../../shared/src/irq-generic.c
-libbsp_a_SOURCES += ../../shared/src/irq-info.c
-libbsp_a_SOURCES += ../../shared/src/irq-legacy.c
-libbsp_a_SOURCES += ../../shared/src/irq-server.c
-libbsp_a_SOURCES += ../../shared/src/irq-shell.c
-libbsp_a_SOURCES += irq/irq.c
-
-# Cache
-libbsp_a_SOURCES += ../../../libcpu/shared/src/cache_manager.c
-libbsp_a_SOURCES += ../../shared/include/cache_.h
-libbsp_a_CPPFLAGS = -I$(srcdir)/../../shared/include
-
-include $(srcdir)/preinstall.am
-include $(top_srcdir)/../../../../automake/local.am
Index: src/lib/libbsp/arm/gba/README
===================================================================
--- c/src/lib/libbsp/arm/gba/README	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,3 +1,0 @@
-This is the BSP for Nintendo's GBA and GBA SP.  The RTEMS Wiki
-has more detailed information on this BSP.
-
Index: src/lib/libbsp/arm/gba/bsp_specs
===================================================================
--- c/src/lib/libbsp/arm/gba/bsp_specs	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,14 +1,0 @@
-%rename endfile old_endfile
-%rename startfile old_startfile
-%rename link old_link
-
-*startfile:
-%{!qrtems: %(old_startfile)} \
-%{!nostdlib: %{qrtems: start.o%s crti.o%s crtbegin.o%s -e _start}}
-
-*link:
-%{!qrtems: %(old_link)} %{qrtems: -dc -dp -Bstatic -N}
-
-*endfile:
-%{!qrtems: %(old_endfiles)} %{qrtems: crtend.o%s crtn.o%s }
-
Index: src/lib/libbsp/arm/gba/clock/clockdrv.c
===================================================================
--- c/src/lib/libbsp/arm/gba/clock/clockdrv.c	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,97 +1,0 @@
-/**
- *  @file clockdrv.c
- *
- *  Game Boy Advance Clock driver.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#include <rtems.h>
-#include <bsp.h>
-#include <bsp/irq.h>
-#include <gba.h>
-#include <assert.h>
-
-void Clock_isr(void * arg);
-void Clock_driver_support_initialize_hardware(void);
-
-#define Clock_driver_support_at_tick()
-
-#define Clock_driver_support_install_isr( _new, _old )  \
-  do {                                                  \
-    rtems_status_code status = RTEMS_SUCCESSFUL;        \
-    status = rtems_interrupt_handler_install(           \
-        BSP_IRQ_TIMER3,                                 \
-        "Clock",                                        \
-        RTEMS_INTERRUPT_UNIQUE,                         \
-        Clock_isr,                                      \
-        NULL                                            \
-    );                                                  \
-    assert(status == RTEMS_SUCCESSFUL);                 \
-    _old = NULL;                                        \
-  } while(0)
-
-#define Clock_driver_support_shutdown_hardware()        \
-  do {                                                  \
-    rtems_status_code status = RTEMS_SUCCESSFUL;        \
-    status = rtems_interrupt_handler_remove(            \
-        BSP_IRQ_TIMER3,                                 \
-        Clock_isr,                                      \
-        NULL                                            \
-    );                                                  \
-    assert(status == RTEMS_SUCCESSFUL);                 \
-  } while (0)
-
-
-/*
- * Calculate Tick Times
- *    1 / 16.78Mhz  => 59.595 ns
- *   64 / 16.78Mhz  =>  3.814 us
- *  256 / 16.78Mhz  => 15.256 us
- * 1024 / 16.78Mhz  => 61.025 us
- */
-#define  __TimTickTime_us   ((1000000L/__ClockFrequency)*__TimPreScaler)
-#define  __TimTickTime_ns   ((1000000000L/__ClockFrequency)*__TimPreScaler)
-
-#if (__TimPreScaler==1)
- #define GBA_TMCNT_PS    0x0000
-#elif (__TimPreScaler==64)
- #define GBA_TMCNT_PS    0x0001
-#elif (__TimPreScaler==256)
- #define GBA_TMCNT_PS    0x0002
-#elif (__TimPreScaler==1024)
- #define GBA_TMCNT_PS    0x0003
-#else
- #define GBA_TMCNT_PS    0x0003
-#endif
-
-/**
- *  @brief This function set up the clock hardware
- *
- *  @param  None
- *  @return None
- */
-void Clock_driver_support_initialize_hardware(void)
-{
-  int tmreload;
-
-  tmreload = rtems_configuration_get_nanoseconds_per_tick() / __TimTickTime_ns;
-
-  if (tmreload>0xFFFF)
-    tmreload = 0xFFFF;
-  GBA_REG_TM3CNT = (GBA_TMCNT_PS);
-  GBA_REG_TM3D   = (0x0000-tmreload);
-  GBA_REG_TM3CNT = (0x00c0|GBA_TMCNT_PS);
-}
-
-#define CLOCK_DRIVER_USE_DUMMY_TIMECOUNTER
-
-#include "../../../shared/clockdrv_shell.h"
Index: src/lib/libbsp/arm/gba/configure.ac
===================================================================
--- c/src/lib/libbsp/arm/gba/configure.ac	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,23 +1,0 @@
-## Process this file with autoconf to produce a configure script.
-
-AC_PREREQ([2.69])
-AC_INIT([rtems-c-src-lib-libbsp-arm-gba],[_RTEMS_VERSION],[https://devel.rtems.org/newticket])
-AC_CONFIG_SRCDIR([bsp_specs])
-RTEMS_TOP(../../../../../..)
-
-RTEMS_CANONICAL_TARGET_CPU
-AM_INIT_AUTOMAKE([no-define nostdinc foreign 1.12.2])
-RTEMS_BSP_CONFIGURE
-
-RTEMS_PROG_CC_FOR_TARGET
-RTEMS_CANONICALIZE_TOOLS
-RTEMS_PROG_CCAS
-
-RTEMS_CHECK_NETWORKING
-AM_CONDITIONAL(HAS_NETWORKING,test "$HAS_NETWORKING" = "yes")
-
-RTEMS_BSP_CLEANUP_OPTIONS(1, 1)
-
-# Explicitly list all Makefiles here
-AC_CONFIG_FILES([Makefile])
-AC_OUTPUT
Index: src/lib/libbsp/arm/gba/console/conio.c
===================================================================
--- c/src/lib/libbsp/arm/gba/console/conio.c	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,450 +1,0 @@
-/**
- *  @file conio.c
- *
- *  This file contains the GBA conio I/O package.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *  based on MyLib by Rafael Vuijk (aka Dark Fader)
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-/*****************************************************************************
- * This source file is based on work by Rafael Vuijk (aka Dark Fader)
- *****************************************************************************
- *****************************************************************************
- * MyLib by Rafael Vuijk (aka Dark Fader)
- * :
- * This file is released into the public domain for commercial
- * or non-commercial usage with no restrictions placed upon it.
- *****************************************************************************/
-
-/*---------------------------------------------------------------------------*
- *   Includes                                                                *
- *---------------------------------------------------------------------------*/
-#include <stdint.h>
-#include <rtems/score/types.h>
-#include <gba.h>
-#include <conio.h>
-#include <stdio.h>
-#include <stdarg.h>
-
-/*---------------------------------------------------------------------------*
- * Defines                                                                   *
- *---------------------------------------------------------------------------*/
-#define W                   60                        /**< Screen width      */
-#define H                   26                        /**< Screen height     */
-#define CLRSCR_SIZE         (W*4 * H*6)               /**< Screen size       */
-#define DEFAULT_FONT_WIDTH  4                         /**< Font width        */
-#define DEFAULT_FONT_HEIGHT 6                         /**< Font height       */
-
-typedef unsigned short      Palette[256];                              /**< 256 colors */
-typedef unsigned short      Palettes[16][16];                          /**< 16 palettes with each 16 colors */
-typedef unsigned short      Bitmap3[GBA_LCD_HEIGHT][GBA_LCD_WIDTH];    /**< 16 bits, single buffered */
-typedef unsigned char       Bitmap4[GBA_LCD_HEIGHT][GBA_LCD_WIDTH];    /**< 8 bits, double buffered  */
-typedef unsigned short      Bitmap5[GBA_MODE5_HEIGHT][GBA_MODE5_WIDTH];/**< double buffered          */
-
-#define VRAM                GBA_VRAM_ADDR             /**< VRAM address      */
-#define VRAM_END            (VRAM +    0x18000)       /**< VRAM end          */
-#define BG_BITMAP0_VRAM     (VRAM +        0x0)       /**< BG Bitmap 0 RAM   */
-#define BG_BITMAP1_VRAM     (VRAM +     0xa000)       /**< BG Bitmap 1 RAM   */
-
-#define bg_bitmap0          (*(Bitmap4 *)BG_BITMAP0_VRAM)
-#define bg_bitmap1          (*(Bitmap4 *)BG_BITMAP1_VRAM)
-#define bg_bitmap3          (*(Bitmap3 *)BG_BITMAP0_VRAM)
-#define bg_bitmap4a         (*(Bitmap4 *)BG_BITMAP0_VRAM)
-#define bg_bitmap4b         (*(Bitmap4 *)BG_BITMAP1_VRAM)
-#define bg_bitmap5a         (*(Bitmap5 *)BG_BITMAP0_VRAM)
-#define bg_bitmap5b         (*(Bitmap5 *)BG_BITMAP1_VRAM)
-
-/** Color conversion macro  */
-#define RGB(r,g,b)          ( (r)<<0 | (g)<<5 | (b)<<10 )
-
-/** BG Affine Transformation Destination Data Structure */
-typedef struct {
-    int16_t H_DiffX;        /**< Line Direction X Coordinate Difference     */
-    int16_t V_DiffX;        /**< Vertical Direction X Coordinate Difference */
-    int16_t H_DiffY;        /**< Line Direction Y Coordinate Difference     */
-    int16_t V_DiffY;        /**< Vertical Direction Y Coordinate Difference */
-    int32_t StartX;         /**< Start X Coordinate                         */
-    int32_t StartY;         /**< Start Y Coordinate                         */
-} BgAffineDestData;
-
-typedef volatile BgAffineDestData   vBgAffineDestData;
-#define rBg2Affine          (*(vBgAffineDestData *)0x4000020)
-
-/** 256 colors for background(s) */
-#define bg_palette          (*(Palette *)(GBA_PAL_RAM_ADDR))
-
-
-int  _wherex;                /**< Screen X coordinate */
-int  _wherey;                /**< Screen Y coordinate */
-int  _textattr;              /**< Text attribute      */
-
-/*
- * Forward reference
- */
-static void gba_initconio(void);
-
-/*---------------------------------------------------------------------------*
- *  Defaultfont                                                              *
- *---------------------------------------------------------------------------*/
-#include "defaultfont.h"
-
-/**
- *  @brief gba_gotoxy function set screeen xy-coordinates
- *
- *  @param  _x screen x coordinate
- *  @param  _y screen y coordinate
- *  @return None
- */
-void gba_gotoxy(int _x, int _y)
-{
-    _wherex = _x;
-    _wherey = _y;
-}
-
-
-/**
- *  @brief gba_putchar function writes char-data to screen memory.
- *
- *  Char code is index to font table.
- *
- *  Input parameters:   char, attribute and cordinates
- *  @param  c character code
- *  @param  textattr text attribute
- *  @param  x screen x coordinate
- *  @param  y screen y coordinate
- *  @return None
- */
-static void gba_putchar(char c, int textattr, int x, int y)
-{
-  int       f = textattr & 0x0F;
-  int       b = textattr >> 4;
-  uint32_t  fmask = f | f<<8 | f<<16 | f<<24;
-  uint32_t  bmask = b | b<<8 | b<<16 | b<<24;
-  uint32_t  *dest = (uint32_t *)&bg_bitmap4a[((y<<1) + y) << 1][x<<2];
-  const uint32_t  *src = (uint32_t *)&(font3x5[(int)c]);
-  uint32_t s;
-
-  s = *src++;
-  *dest = (fmask&s) | (bmask&~s);
-  dest += GBA_LCD_WIDTH/sizeof(uint32_t);
-
-  s = *src++;
-  *dest = (fmask&s) | (bmask&~s);
-  dest += GBA_LCD_WIDTH/sizeof(uint32_t);
-
-  s = *src++;
-  *dest = (fmask&s) | (bmask&~s);
-  dest += GBA_LCD_WIDTH/sizeof(uint32_t);
-
-  s = *src++;
-  *dest = (fmask&s) | (bmask&~s);
-  dest += GBA_LCD_WIDTH/sizeof(uint32_t);
-
-  s = *src++;
-  *dest = (fmask&s) | (bmask&~s);
-  dest += GBA_LCD_WIDTH/sizeof(uint32_t);
-
-  s = *src++;
-  *dest = (fmask&s) | (bmask&~s);
-  dest += GBA_LCD_WIDTH/sizeof(uint32_t);
-}
-
-
-/**
- *  @brief gba_textattr function set textattribute
- *
- *  @param  _attr text attribute
- *  @return None
- */
-void gba_textattr(int _attr)
-{
-  _textattr = _attr;
-}
-
-/**
- *  @brief gba_textbackground function set text background color
- *
- *  @param  _color backround color
- *  @return None
- *
- */
-void gba_textbackground(int _color)
-{
-  _textattr = (_textattr & 0x0F) | (_color << 4);
-}
-
-/**
- *  @brief gba_textcolor function set text color
- *
- *  @param  _colour text color
- *  @return None
- */
-void gba_textcolor(int _color)
-{
-  _textattr = (_textattr & 0xF0) | (_color);
-}
-
-
-/**
- *  @brief gba_clearline function clear line number y
- *
- *  Line is filled with spaces
- *
- *  @param  y line number
- *  @return None
- */
-static void gba_clearline(int y)
-{
-  int x;
-
-  for (x=0 ; x<=W ; x++) {
-     gba_putchar(0, _textattr, x, y);
-  }
-}
-
-/**
- *  @brief gba_nextline function moves cursor to next line and clears it
- *
- *  @param  None
- *  @return None
- */
-static void gba_nextline(void)
-{
-    _wherex = 0;
-    if (++_wherey >= H) {
-       _wherey = 0;
-    }
-    gba_clearline(_wherey);
-}
-
-/**
- *  @brief gba_clrscr function clear screen
- *
- *  @param  None
- *  @return None
- */
-void gba_clrscr(void)
-{
-    int y;
-
-    for (y=0 ; y<=H ; y++) {
-       gba_clearline(y);
-    }
-    gba_gotoxy(0,0);
-}
-
-/**
- *  @brief gba_put function convert ascii char to font index and
- *  write char to screen memory
- *
- *  @param  _c character code
- *  @return None
- */
-static void gba_put(char _c)
-{
-  /* We have save some memory with reduced fonts */
-  _c = _c & 0x7F;   /* no extened chars */
-  _c = _c - 0x20;   /* no cntr chars    */
-  gba_putchar(_c, _textattr, _wherex, _wherey);
-}
-
-
-/**
- *  @brief gba_putch function write ascii chars to screen
- *
- *  @param  _c character code
- *  @return None
- */
-void gba_putch(char _c)
-{
-    switch (_c) {
-        case ASCII_LF:
-            gba_nextline();
-            break;
-        case ASCII_CR:
-            gba_gotoxy(0, _wherey);
-            break;
-        default:
-            gba_put(_c);
-            if (++_wherex >= W)
-            {
-               gba_nextline();
-            }
-            break;
-    }
-    return;
-}
-
-/**
- *  @brief gba_puts function write ascii string to screen
- *
- *  @param  _str ASCII string
- *  @return None
- */
-void gba_puts(const char *_str)
-{
-    while (*_str) {
-       gba_putch(*_str++);
-    }
-    return;
-}
-
-/**
- *  @brief gba_printf function do formated printf
- *
- *  @param  _format printf format string
- *  @param  ... parameters specified in format string
- *  @return None
- */
-int gba_printf(const char *_format, ...)
-{
-    char s[256];
-    va_list marker;
-    va_start(marker, _format);
-    int r = vsprintf(s, _format, marker);
-    va_end(marker);
-    gba_puts(s);
-    return r;
-}
-
-/**
- *  @brief gba_initconio function initialize console
- *
- *  @param  None
- *  @return None
- */
-static void gba_initconio(void)
-{
-    GBA_REG_DISPCNT = GBA_DISP_MODE_4 | GBA_DISP_BG2_ON;/*  256 color bitmapped mode */
-    const BgAffineDestData bgAffineReset = {256,0,0,256,0,-256*2};
-    rBg2Affine = bgAffineReset;
-    bg_palette[BLACK       ] =  RGB( 0, 0, 0);   /*  BLACK */
-    bg_palette[BLUE        ] =  RGB( 0, 0,16);   /*  BLUE */
-    bg_palette[GREEN       ] =  RGB( 0,16, 0);   /*  GREEN */
-    bg_palette[CYAN        ] =  RGB( 0,16,16);   /*  CYAN */
-    bg_palette[RED         ] =  RGB(16, 0, 0);   /*  RED */
-    bg_palette[MAGENTA     ] =  RGB(16, 0,16);   /*  MAGENTA */
-    bg_palette[BROWN       ] =  RGB(16,16, 0);   /*  BROWN */
-    bg_palette[LIGHTGRAY   ] =  RGB(24,24,24);   /*  LIGHTGRAY */
-    bg_palette[DARKGRAY    ] =  RGB(16,16,16);   /*  DARKGRAY */
-    bg_palette[LIGHTBLUE   ] =  RGB( 0, 0,31);   /*  LIGHTBLUE */
-    bg_palette[LIGHTGREEN  ] =  RGB( 0,31, 0);   /*  LIGHTGREEN */
-    bg_palette[LIGHTCYAN   ] =  RGB( 0,31,31);   /*  LIGHTCYAN */
-    bg_palette[LIGHTRED    ] =  RGB(31, 0, 0);   /*  LIGHTRED */
-    bg_palette[LIGHTMAGENTA] =  RGB(31, 0,31);   /*  LIGHTMAGENTA */
-    bg_palette[YELLOW      ] =  RGB(31,31, 0);   /*  YELLOW */
-    bg_palette[WHITE       ] =  RGB(31,31,31);   /*  WHITE */
-    gba_textattr(0);
-    gba_textcolor(DEF_TEXTCOLOR);
-    gba_textbackground(DEF_TEXTBACKGROUND);
-    gba_clrscr();
-}
-
-/**
- *  @brief gba_textmode function set console mode
- *
- *  @param  _mode console mode code
- *  @return None
- */
-void gba_textmode(int _mode)
-{
-  switch (_mode) {
-    case CO60: {
-      gba_initconio();
-      break;
-    }
-  }
-}
-
-
-/**
- *  @brief delay_loop function is simple delay loop
- *
- *  @param  count loop counter
- *  @return None
- */
-static void delay_loop(unsigned int count)
-{
-  int i;
-
-  for (i = 0; i<count; i++) i = i;
-}
-
-static unsigned char inputch = ASCII_CR;    /**< input character value */
-/**
- *  @brief gba_getch function read char from game pad keys
- *
- *  Character input is done with GBA buttons,
- *      up-down-left-right/A/B/R/L/Select/Start
- *  - Select-key accept selected character
- *  - Start-key read CR (Enter)
- *  - A-key select 'A' character
- *  - B-key select 'Z' character
- *  - R-key select '1' character
- *  - L-key select '9' character
- *  - up-key increment character ('A'->'B')
- *  - down-key decrement character ('B'-'A')
- *  - left-key change set of character ('!'->'A'->'a')
- *  - right-key change set of character ('a'->'A'->'!')
- *
- *  @param  None
- *  @return Selected char code
- */
-int gba_getch(void)
-{
-  int  keyx, key  = 0;
-
-  while(1) {
-    key = GBA_KEY();
-    while ( (keyx=GBA_KEY())==key );
-    switch (key) {
-      case GBA_KEY_SELECT:
-	gba_put(inputch);
-	return inputch;
-	break;
-      case GBA_KEY_START:
-	gba_put(' ');
-	inputch = ASCII_CR;
-	return inputch;
-	break;
-      case GBA_KEY_A:
-	inputch = 'A';
-	break;
-      case GBA_KEY_B:
-	inputch = 'Z';
-	break;
-      case GBA_KEY_UP:
-	if ((inputch-1) >= 0x20) inputch--;
-	break;
-      case GBA_KEY_DOWN:
-	if ((inputch+1) <=  0x7E) inputch++;
-	break;
-      case GBA_KEY_LEFT:
-	if ((inputch - 0x20) >= 0x20) inputch -= 0x20;
-	break;
-      case GBA_KEY_RIGHT:
-	if ((inputch + 0x20) <= 0x7E) inputch += 0x20;
-	break;
-      case GBA_KEY_R:
-	inputch = '1';
-	break;
-      case GBA_KEY_L:
-	inputch = '9';
-	break;
-      default:
-	break;
-    }
-
-    gba_put(inputch);
-    delay_loop(1000);
-  }
-}
Index: src/lib/libbsp/arm/gba/console/console.c
===================================================================
--- c/src/lib/libbsp/arm/gba/console/console.c	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,257 +1,0 @@
-/**
- *  @file console.c
- *
- *  This file contains the GBA console I/O package.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#include <stdio.h>
-#include <stdlib.h>
-#include <unistd.h>
-
-#include <bsp.h>
-#include <rtems/bspIo.h>
-#include <rtems/libio.h>
-#include <rtems/termiostypes.h>
-#include <termios.h>
-#include <bsp/irq.h>
-#include <gba.h>
-#include <conio.h>
-
-/**
- *  @brief gba_pollRead function read char
- *
- *  @param  minor unused
- *  @return character code
- */
-static int gba_pollRead(int minor)
-{
-  return (gba_getch());
-}
-
-/**
- *  @brief gba_write function writes chars
- *
- *  Input parameters:   minor code, buffer pointer and lenght
- *  @param  minor unused
- *  @param  *buf buffer pointer
- *  @param  len lenght of buffer
- *  @return character code
- *
- */
-static ssize_t gba_write(int minor, const char *buf, size_t len)
-{
-  int i;
-
-  for (i=0;i<len;i++) {
-    gba_putch((unsigned short)buf[i]);
-  }
-  return len;
-}
-
-/**
- *  @brief gba_setAttributes function is empty
- *
- *  @param  minor unused
- *  @param  *t unused
- *  @return constant 0
- */
-static int gba_setAttributes(int minor, const struct termios *t)
-{
-  return 0;
-}
-
-/** BSP_output_char for printk support */
-BSP_output_char_function_type     BSP_output_char = (BSP_output_char_function_type)     gba_putch;
-/** BSP_poll_char for printk support */
-BSP_polling_getchar_function_type BSP_poll_char   = gba_getch;
-
-/**
- *  @brief Console device driver INITIALIZE entry point
- *
- *  Initilizes the I/O console driver.
- *
- *  @param  major diver major number
- *  @param  minor driver minor mumber
- *  @param  *arg pointer to parameters
- *  @return status code
- */
-rtems_device_driver
-console_initialize(
-  rtems_device_major_number  major,
-  rtems_device_minor_number  minor,
-  void                      *arg
-)
-{
-  rtems_status_code status;
-
-  /* Set up TERMIOS */
-  rtems_termios_initialize ();
-
-  /* Do device-specific initialization  */
-  /* Already done in bspstart.c -> gba_textmode(CO60); */
-
-  /* Register the device */
-  status = rtems_io_register_name ("/dev/console", major, 0);
-  if (status != RTEMS_SUCCESSFUL) {
-    printk("Error registering console device!\n");
-    rtems_fatal_error_occurred (status);
-  }
-
-  printk("Initialized GBA console\n\n");
-
-  return RTEMS_SUCCESSFUL;
-}
-
-/**
- *  @brief console_first_open function is empty
- *
- *  @param  major diver major number
- *  @param  minor driver minor mumber
- *  @param  *arg pointer to parameters
- *  @return status code
- */
-static int console_first_open(int major, int minor, void *arg)
-{
-  return 0;
-}
-
-/**
- *  @brief console_last_close function is empty
- *
- *  @param  major diver major number
- *  @param  minor driver minor mumber
- *  @param  *arg pointer to parameters
- *  @return status code
- */
-static int console_last_close(int major, int minor, void *arg)
-{
-  return 0;
-}
-
-/**
- *  @brief Console device driver OPEN entry point
- *
- *  @param  major diver major number
- *  @param  minor driver minor mumber
- *  @param  *arg pointer to parameters
- *  @return status code
- */
-rtems_device_driver
-console_open(
-  rtems_device_major_number major,
-  rtems_device_minor_number minor,
-  void                      *arg
-)
-{
-  rtems_status_code              status;
-  static rtems_termios_callbacks cb =
-  {
-    console_first_open,         /* firstOpen     */
-    console_last_close,         /* lastClose     */
-    gba_pollRead,               /* pollRead      */
-    gba_write,                  /* write         */
-    gba_setAttributes,          /* setAttributes */
-    NULL,                       /* stopRemoteTx  */
-    NULL,                       /* startRemoteTx */
-    TERMIOS_POLLED              /* 1 = outputUsesInterrupts */
-  };
-
-  status = rtems_termios_open (major, minor, arg, &cb);
-
-  if (status != RTEMS_SUCCESSFUL) {
-    printk("Error openning console device\n");
-    return status;
-  }
-
-  return RTEMS_SUCCESSFUL;
-}
-
-/**
- *  @brief Console device driver CLOSE entry point
- *
- *  @param  major diver major number
- *  @param  minor driver minor mumber
- *  @param  *arg pointer to parameters
- *  @return status code
- */
-rtems_device_driver
-console_close(
-  rtems_device_major_number major,
-  rtems_device_minor_number minor,
-  void                      *arg
-)
-{
-  rtems_device_driver res = RTEMS_SUCCESSFUL;
-
-  res =  rtems_termios_close (arg);
-
-  return res;
-}
-
-/**
- *  @brief Console device driver READ entry point.
- *
- *  Read characters from the I/O console.
- *
- *  @param  major diver major number
- *  @param  minor driver minor mumber
- *  @param  *arg pointer to parameters
- *  @return status code
- */
-rtems_device_driver
-console_read(
-  rtems_device_major_number major,
-  rtems_device_minor_number minor,
-  void                      *arg
-)
-{
-  return rtems_termios_read (arg);
-}
-
-/**
- *  @brief Console device driver WRITE entry point.
- *
- *  Write characters to the I/O console.
- *
- *  @param  major diver major number
- *  @param  minor driver minor mumber
- *  @param  *arg pointer to parameters
- *  @return status code
-*/
-rtems_device_driver
-console_write(
-  rtems_device_major_number major,
-  rtems_device_minor_number minor,
-  void                      *arg
-)
-{
-  return rtems_termios_write (arg);
-}
-
-/**
- *  @brief Handle ioctl request.
- *
- *  @param  major diver major number
- *  @param  minor driver minor mumber
- *  @param  *arg pointer to parameters
- *  @return status code
- */
-rtems_device_driver
-console_control(
-  rtems_device_major_number major,
-  rtems_device_minor_number minor,
-  void                      *arg
-)
-{
-  return rtems_termios_ioctl (arg);
-}
Index: src/lib/libbsp/arm/gba/console/defaultfont.h
===================================================================
--- c/src/lib/libbsp/arm/gba/console/defaultfont.h	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,602 +1,0 @@
-/**
- * @file
- *
- * @ingroup arm_gba
- *
- * @brief Default font definitions.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-/** Font array dot value   */
-#define  X  255
-/** Generate font row data */
-#define GEN_FONT_DATA(a,b,c,d)  ( ((d)<<24) | ((c)<<16) | ((b)<<8) | ((a)<<0) )
-/** array for 3x5 font, font screen size is 4x6 */
-static const unsigned long	font3x5[256][6] =
-	{	{		/* ' ' - ascii:0x20 font:0x00   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* '!' - ascii:0x21 font:0x01   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* '"' - ascii:0x22 font:0x02   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* '#' - ascii:0x23 font:0x03   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* '$' - ascii:0x24 font:0x04    */
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* '%' - ascii:0x25 font:0x05   */
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,0  )
-		},{		/* '&' - ascii:0x26 font:0x06   */
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* ''' - ascii:0x27 font:0x07   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* '(' - ascii:0x28 font:0x08   */
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,X  )
-		},{		/* ')' - ascii:0x29 font:0x09   */
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  )
-		},{		/* '*' - ascii:0x2A font:0x0A   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* '+' - ascii:0x2B font:0x0B   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* 'ÂŽ' - ascii:0x2C font:0x0C   */
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* '-' - ascii:0x2D font:0x0D   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* '.' - ascii:0x2E font:0x0E   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		},{		/* '/' - ascii:0x2F font:0x0F   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  X,0,0,0  )
-		},{		/* '0' - ascii:0x30 font:0x10   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '1' - ascii:0x31 font:0x11   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '2' - ascii:0x32 font:0x12   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '3' - ascii:0x33 font:0x13   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '4' - ascii:0x34 font:0x14   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,X  )
-		},{		/* '5' - ascii:0x35 font:0x15   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '6' - ascii:0x36 font:0x16   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '7' - ascii:0x37 font:0x17   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* '8' - ascii:0x38 font:0x18   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '9' - ascii:0x39 font:0x19   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* ':' - ascii:0x3A font:0x1A   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		},{		/* ';' - ascii:0x3B font:0x1B   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		},{		/* '<' - ascii:0x3C font:0x1C   */
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,X  )
-		},{		/* '=' - ascii:0x3D font:0x1D   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* '>' - ascii:0x3E font:0x1E   */
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  )
-		},{		/* '?' - ascii:0x3F font:0x1F   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* '@' - ascii:0x40 font:0x20   */
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,X  )
-		},{		/* 'A' - ascii:0x41 font:0x21   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'B' - ascii:0x42 font:0x22   */
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  )
-		},{		/* 'C' - ascii:0x43 font:0x23   */
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,X  )
-		},{		/* 'D' - ascii:0x44 font:0x24   */
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		},{		/* 'E' - ascii:0x45 font:0x25   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* 'F' - ascii:0x46 font:0x26   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		},{		/* 'G' - ascii:0x47 font:0x27   */
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  )
-		},{		/* 'H' - ascii:0x48 font:0x28   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'I' - ascii:0x49 font:0x29   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* 'J' - ascii:0x4A font:0x2A   */
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* 'K' - ascii:0x4B font:0x2B   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'L' - ascii:0x4C font:0x2C   */
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* 'M' - ascii:0x4D font:0x2D   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'N' - ascii:0x4E font:0x2E   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'O' - ascii:0x4F font:0x2F   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* 'P' - ascii:0x50 font:0x30   */
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		},{		/* 'Q' - ascii:0x51 font:0x31   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  )
-		},{		/* 'R' - ascii:0x52 font:0x33   */
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'S' - ascii:0x53 font:0x33   */
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  )
-		},{		/* 'T' - ascii:0x54 font:0x34   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		},{		/* 'U' - ascii:0x55 font:0x35   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* 'V' - ascii:0x56 font:0x36   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		},{		/* 'W' - ascii:0x57 font:0x37   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		},{		/* 'X' - ascii:0x58 font:0x38   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'Y' - ascii:0x59 font:0x39   */
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		},{		/* 'Z' - ascii:0x5A font:0x3A   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '[' - ascii:0x5B font:0x3B   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '\' - ascii:0x5C font:0x3C   */
-		GEN_FONT_DATA(  X,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* ']' - ascii:0x5D font:0x3D   */
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '^' - ascii:0x5E font:0x3E   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* '_' - ascii:0x5F font:0x3F   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* 'ÂŽ' - ascii:0x60 font:0x30   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* 'a' - ascii:0x31 font:0x31   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* 'b' - ascii:0x62 font:0x32   */
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  )
-		},{		/* 'c' - ascii:0x63 font:0x33   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,X  )
-		},{		/* 'd' - ascii:0x64 font:0x34   */
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		},{		/* 'e' - ascii:0x65 font:0x35   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,0,X,X  )
-		},{		/* 'f' - ascii:0x66 font:0x36   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		},{		/* 'g' - ascii:0x67 font:0x37   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,X,0  )
-		},{		/* 'h' - ascii:0x68 font:0x38   */
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'i' - ascii:0x69 font:0x39   */
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* 'j' - ascii:0x6A font:0x3A   */
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* 'k' - ascii:0x6B font:0x3B   */
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'l' - ascii:0x6C font:0x3C   */
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* 'm' - ascii:0x6D font:0x3D   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'n' - ascii:0x6E font:0x3E   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'o' - ascii:0x6F font:0x6F   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  )
-		},{		/* 'p' - ascii:0x70 font:0x40   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		},{		/* 'q' - ascii:0x71 font:0x41   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  )
-		},{		/* 'r' - ascii:0x72 font:0x43   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  )
-		},{		/* 's' - ascii:0x73 font:0x43   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,X,X,0  )
-		},{		/* 't' - ascii:0x74 font:0x44   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,X  ),
-		},{		/* 'u' - ascii:0x75 font:0x45   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,X  )
-		},{		/* 'v' - ascii:0x76 font:0x46   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		},{		/* 'w' - ascii:0x77 font:0x47   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		},{		/* 'x' - ascii:0x78 font:0x48   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,X  )
-		},{		/* 'y' - ascii:0x79 font:0x49   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		},{		/* 'z' - ascii:0x7A font:0x4A   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,X,X  )
-		},{		/* '{' - ascii:0x7B font:0x4B   */
-		GEN_FONT_DATA(  0,0,X,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,X,X  )
-		},{		/* '\' - ascii:0x7C font:0x4C   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* '}' - ascii:0x7D font:0x4D   */
-		GEN_FONT_DATA(  0,X,X,0  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,X,0  ),
-		GEN_FONT_DATA(  0,X,X,0  )
-		},{		/* '~' - ascii:0x7E font:0x4E   */
-		GEN_FONT_DATA(  0,0,0,0  ),
-		GEN_FONT_DATA(  0,X,0,0  ),
-		GEN_FONT_DATA(  0,X,X,X  ),
-		GEN_FONT_DATA(  0,0,0,X  ),
-		GEN_FONT_DATA(  0,0,0,0  )
-		},{		/* DEL - ascii:0x7F font:0x4F   */
-		GEN_FONT_DATA(  X,X,X,X  ),
-		GEN_FONT_DATA(  X,X,X,X  ),
-		GEN_FONT_DATA(  X,X,X,X  ),
-		GEN_FONT_DATA(  X,X,X,X  ),
-		GEN_FONT_DATA(  X,X,X,X  )
-		}
-	};
Index: src/lib/libbsp/arm/gba/include/arm_mode_bits.h
===================================================================
--- c/src/lib/libbsp/arm/gba/include/arm_mode_bits.h	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,46 +1,0 @@
-/**
- * @file
- *
- * @ingroup arm_gba
- *
- * @brief ARM status register mode bits.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#ifndef __ARMMODEBITS_H
-#define __ARMMODEBITS_H
-
-/*-----------------------------------------------------------------------------
- * Definitions
- ----------------------------------------------------------------------------*/
-#define Mode_USR             0x10
-#define Mode_FIQ             0x11
-#define Mode_IRQ             0x12
-#define Mode_SVC             0x13
-#define Mode_ABT             0x17
-#define Mode_ABORT           0x17
-#define Mode_UNDEF           0x1B
-#define Mode_SYS             0x1F      /**< only available on ARM Arch v4 */
-#define Mode_Bits            0x1F      /**< mask for mode bits */
-#define ModePriv             Mode_SVC  /**< used supervisor mode */
-
-#define I_Bit                0x80
-#define F_Bit                0x40
-#define Int_Bits             0xC0
-
-#define Mode_SVC_MIRQ        (Mode_SVC | I_Bit | F_Bit)
-#define Mode_SVC_UIRQ        (Mode_SVC)
-#define Mode_IRQ_MIRQ        (Mode_SVC | I_Bit | F_Bit)
-#define Mode_IRQ_UIRQ        (Mode_SVC)
-
-#endif /* __ARMMODEBITS_H */
-
Index: src/lib/libbsp/arm/gba/include/asm_macros.h
===================================================================
--- c/src/lib/libbsp/arm/gba/include/asm_macros.h	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,55 +1,0 @@
-/**
- * @file
- *
- * @ingroup arm_gba
- *
- * @brief ASM macros.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-/*-----------------------------------------------------------------------------*
- * Macros
- *-----------------------------------------------------------------------------*/
-#ifdef __asm__
-#define PUBLIC_ARM_FUNCTION(label)   .global label ; \
-                                     .type label, function ; \
-                                     .arm ; \
-                                     label:
-
-#define PUBLIC_THUMB_FUNCTION(label) .global label ; \
-                                     .type label, function ; \
-                                     .thumb_func ; \
-                                     label:
-
-#define STATIC_ARM_FUNCTION(label)   .type label, function ; \
-                                     .arm ; \
-                                     label:
-
-#define STATIC_THUMB_FUNCTION(label) .type label, function ; \
-                                     .thumb_func ; \
-                                     label:
-
-#define OBJECT(label)                .global label ; \
-                                     .type label, object ; \
-                                     label:
-
-#define STATIC_OBJECT(label)         .type label, object ; \
-                                     label:
-
-#define WEAK_OBJECT(label)           .weak label ; \
-                                     .type label, object ; \
-                                     label:
-
-#define LABEL_END(label)             .L##label##_end: ; \
-                                     .size label, .L##label##_end - label
-
-#endif
Index: src/lib/libbsp/arm/gba/include/bsp.h
===================================================================
--- c/src/lib/libbsp/arm/gba/include/bsp.h	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,61 +1,0 @@
-/**
- * @file 
- *
- * @ingroup arm_gba
- *
- * @brief Global BSP definitions.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004
- *      Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#ifndef LIBBSP_ARM_GBA_H
-#define LIBBSP_ARM_GBA_H
-
-#include <bspopts.h>
-#include <bsp/default-initial-extension.h>
-
-#include <rtems.h>
-#include <rtems/iosupp.h>
-#include <rtems/console.h>
-#include <rtems/clockdrv.h>
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#define BSP_FEATURE_IRQ_EXTENSION
-
-/** Define operation count for Tests */
-#define OPERATION_COUNT 10
-
-/** gba_zero_memory library function in start.S  */
-extern void gba_zero_memory(int start, int stop);
-/** gba_move_memory library function in start.S  */
-extern void gba_move_memory(int from, int toStart, int toEnd);
-/** gba_set_memory library function in start.S  */
-extern void gba_set_memory(int start, int stop, int data);
-
-
-#ifdef __cplusplus
-}
-#endif
-
-
-#endif /* __BSP_H_ */
-/**
- * @defgroup arm_gba GBA Support
- *
- * @ingroup bsp_arm
- *
- * @brief GBA support package.
- */
-
Index: src/lib/libbsp/arm/gba/include/conio.h
===================================================================
--- c/src/lib/libbsp/arm/gba/include/conio.h	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,101 +1,0 @@
-/**
- * @file
- *
- * @ingroup gba_conio
- *
- * @brief GBA conio I/O package.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#ifndef _CONIO_H
-#define _CONIO_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/**
- * @defgroup gba_conio GBA Conio I/O
- *
- * @ingroup arm_gba
- *
- * @brief GBA Conio I/O support.
- */
-
-/*---------------------------------------------------------------------------*
- * Includes                                                                  *
- *---------------------------------------------------------------------------*/
-#include <gba.h>
-
-/*---------------------------------------------------------------------------*
- * Defines                                                                   *
- *---------------------------------------------------------------------------*/
-#define ASCII_BEL       0x07            /**< bell             */
-#define ASCII_BS        0x08            /**< backspace        */
-#define ASCII_TAB       0x09            /**< horizontal tab   */
-#define ASCII_LF        0x0A            /**< line feed        */
-#define ASCII_CR        0x0D            /**< carriage return  */
-#define ASCII_XON       0x11            /**< control-Q        */
-#define ASCII_XOFF      0x13            /**< control-S        */
-#define ASCII_ESC       0x1B            /**< escape           */
-
-
-enum TEXT_MODES
-{
-    CO60 = 0,                           /**< 60x26 (3x5 font) */
-    MAXMODES
-};
-
-enum COLORS
-{
-    BLACK,
-    BLUE,
-    GREEN,
-    CYAN,
-    RED,
-    MAGENTA,
-    BROWN,
-    LIGHTGRAY,
-    DARKGRAY,
-    LIGHTBLUE,
-    LIGHTGREEN,
-    LIGHTCYAN,
-    LIGHTRED,
-    LIGHTMAGENTA,
-    YELLOW,
-    WHITE,
-    MAXCOLORS
-};
-
-#define  DEF_TEXTCOLOR       BLACK
-#define  DEF_TEXTBACKGROUND  WHITE
-
-/*---------------------------------------------------------------------------*
- * Prototypes                                                                *
- *---------------------------------------------------------------------------*/
-void    gba_textmode(int _mode);
-void    gba_clrscr(void);
-void    gba_textattr(int _attr);
-void    gba_textbackground(int _color);
-void    gba_textcolor(int _color);
-void    gba_putch(char _c);
-void    gba_puts(const char *_str);
-int     gba_printf(const char *_format, ...);
-void    gba_gotoxy(int _x, int _y);
-int     gba_getch(void);
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif  /* _CONIO_H */
Index: src/lib/libbsp/arm/gba/include/gba.h
===================================================================
--- c/src/lib/libbsp/arm/gba/include/gba.h	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,107 +1,0 @@
-/**
- * @file
- *
- * @ingroup arm_gba
- *
- * @brief GameBoy Advance definitions.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#ifndef _GBA_H
-#define _GBA_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-#include <gba_registers.h>
-
-/*---------------------------------------------------------------------------*
- * Clock                                                                     *
- *---------------------------------------------------------------------------*/
-#define  __ClockFrequency   16780000L    /**< ClockFreguency in Hz           */
-#define  __TimPreScaler     1024L        /**< Prescaler value 1,64,256,1024  */
-
-/*---------------------------------------------------------------------------*
- * Activation defines                                                        *
- *---------------------------------------------------------------------------*/
-/**
- * Multiboot/Cart boot Selection.
- *
- * If the variable __gba_multiboot is defined
- * (probably should be in your main project file) then code
- * is generated which will run as a multiboot image (code starts
- * at 0x02000000) or as a normal flash cart / emulator image.
- * (i.e. start.S copies code from ROM to EWRAM if started in cart
- * or emulator.) If this variable is not defined then code is
- * generated for flash cart / emulator only operation (code starts
- * at 0x08000000).
- */
-#define MULTIBOOT volatile const unsigned short __gba_multiboot;
-
-/**
- * IWRAM/EWRAM data Selection.
- *
- * If the variable __gba_iwram_data is defined
- * (probably should be in your main project file) then code
- * is generated which will allocate data section in IWRAM
- * (data starts at 0x03000080).
- * If this variable is not defined then data sections is
- * allocated in EWRAM (data starts at 0x02000000).
- */
-#define IWRAMDATA volatile const unsigned short __gba_iwram_data;
-
-/**
- * IWRAM/EWRAM bss Selection.
- *
- * If the variable __gba_iwram_bss is defined
- * (probably should be in your main project file) then code
- * is generated which will allocate bss section in IWRAM
- * (data starts at 0x03000080).
- * If this variable is not defined then bss sections is
- * allocated in EWRAM (data starts at 0x02000000).
- */
-#define IWRAMBSS volatile const unsigned short __gba_iwram_bss;
-
-
-/*---------------------------------------------------------------------------*
- *  Attributes                                                               *
- *---------------------------------------------------------------------------*/
-#define CODE_IN_ROM   __attribute__ ((section (".text"), long_call))
-#define CODE_IN_IWRAM __attribute__ ((section (".iwram"), long_call))
-#define IN_IWRAM      __attribute__ ((section (".iwram")))
-#define IN_EWRAM      __attribute__ ((section (".ewram")))
-
-/*---------------------------------------------------------------------------*
- * Console Keypad                                                            *
- *---------------------------------------------------------------------------*/
-#define OK_KEY (0==0)  /**< TRUE  */
-#define NO_KEY (0==1)  /**< FALSE */
-#define GBA_KEYS_PRESSED(keys) (( ((~GBA_REG_P1) & (keys)) == (keys)) ? (OK_KEY) : (NO_KEY))
-#define GBA_ANY_KEY(keys)      (( ((~GBA_REG_P1) & (keys)) != 0) ? (OK_KEY) : (NO_KEY))
-#define GBA_KEY()              ((~GBA_REG_P1)&GBA_KEY_ALL)
-
-/*---------------------------------------------------------------------------*
- * Console Screen                                                            *
- *---------------------------------------------------------------------------*/
-#define GBA_LCD_WIDTH           240
-#define GBA_LCD_HEIGHT          160
-#define GBA_MODE5_WIDTH         160
-#define GBA_MODE5_HEIGHT        128
-#define GBA_LCD_ASPECT          ((float)(GBA_LCD_WIDTH / GBA_LCD_HEIGHT))
-
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
Index: src/lib/libbsp/arm/gba/include/gba_registers.h
===================================================================
--- c/src/lib/libbsp/arm/gba/include/gba_registers.h	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,965 +1,0 @@
-/**
- *  @file
- *
- *  @ingroup gba_reg
- *
- *  @brief Register definitions.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-/*---------------------------------------------------------------------------+
-| THIS CODE WAS NOT MADE IN ASSOCIATION WITH NINTENDO AND DOES NOT MAKE
-| USE OF ANY INTELLECTUAL PROPERTY CLAIMED BY NINTENDO.
-|
-| GAMEBOY ADVANCE IS A TRADEMARK OF NINTENDO.
-|
-| THIS CODE HAS BEEN PROVIDED "AS-IS" WITHOUT A WARRANTY OF ANY KIND,
-| EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO IMPLIED
-| WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE.
-| THE ENTIRE RISK AS TO THE QUALITY OR PERFORMANCE OF THE CODE IS WITH YOU.
-|
-| IN NO EVENT, UNLESS AGREED TO IN WRITING, WILL ANY COPYRIGHT HOLDER,
-| OR ANY OTHER PARTY, BE HELD LIABLE FOR ANY DAMAGES RESULTING FROM
-| THE USE OR INABILITY TO USE THIS CODE.
-+----------------------------------------------------------------------------*/
-
-#ifndef _GBA_REGISTERS_H
-#define _GBA_REGISTERS_H
-
-#ifndef __asm__
-extern volatile unsigned int  *Regs;        /**< Chip registers              */
-#endif
-
-/**
- * @defgroup gba_reg Register Definitions
- *
- * @ingroup arm_gba
- *
- * @brief Register definitions.
- */
-
-
-/*---------------------------------------------------------------------------+
-|    General address definitions
-+----------------------------------------------------------------------------*/
-/* General Internal Memory */
-#define GBA_BIOS_ADDR        0x00000000  /**< GBA BIOS start address         */
-#define GBA_BIOS_END         0x00004000  /**< GBA BIOS end address           */
-#define GBA_EXT_RAM_ADDR     0x02000000  /**< On-board RAM start address     */
-#define GBA_EXT_RAM_END      0x02040000  /**< On-board RAM end address       */
-#define GBA_INT_RAM_ADDR     0x03000000  /**< In-chip RAM start address      */
-#define GBA_INT_RAM_END      0x03008000  /**< In-chip RAM end address        */
-#define GBA_IO_REGS_ADDR     0x04000000  /**< IO registers start address     */
-#define GBA_IO_REGS_END      0x04000400  /**< IO registers end address       */
-/* Internal Display Memory */
-#define GBA_PAL_RAM_ADDR     0x05000000  /**< PAL RAM start address          */
-#define GBA_PAL_RAM_END      0x05000400  /**< PAL RAM end address            */
-#define GBA_VRAM_ADDR        0x06000000  /**< VRAM start address             */
-#define GBA_VRAM_END         0x06180000  /**< VRAM end address               */
-#define GBA_OAM_ADDR         0x07000000  /**< OAM start address              */
-#define GBA_OAM_END          0x07000400  /**< OAM end address                */
-/* External Memory (Game Pak) */
-#define GBA_ROM0_ADDR        0x08000000  /**< Card ROM0 start address        */
-#define GBA_ROM1_ADDR        0x0A000000  /**< Card ROM1 start address        */
-#define GBA_ROM2_ADDR        0x0C000000  /**< Card ROM2 start address        */
-#define GBA_SRAM_ADDR        0x0E000000  /**< Card SRAM start address        */
-#define GBA_SRAM_END         0x0E010000  /**< Card SRAM end address          */
-/* Unused Memory Area */
-#define GBA_MAX_ADDR         0x10000000  /**< Upper 4bits of address bus unused */
-/* Memory pointers */
-#ifndef __asm__
-#define GBA_BASE_BIOS       (volatile unsigned char *)GBA_BIOS_ADDR    /**< BIOS - System ROM 16KBytes, protected */
-#define GBA_BASE_EXT_RAM    (volatile unsigned char *)GBA_EXT_RAM_ADDR /**< WRAM - On-board Work RAM 256KBytes    */
-#define GBA_BASE_INT_RAM    (volatile unsigned char *)GBA_INT_RAM_ADDR /**< WRAM - In-chip Work RAM 32KBytes      */
-#define GBA_BASE_IO_REGS    (volatile unsigned char *)GBA_IO_REGS_ADDR /**< I/O Registers                         */
-#define GBA_BASE_PAL_RAM    (volatile unsigned char *)GBA_PAL_RAM_ADDR /**< BG/OBJ Palette RAM 1KBytes            */
-#define GBA_BASE_VRAM       (volatile unsigned char *)GBA_VRAM_ADDR    /**< VRAM - Video RAM 96KBytes             */
-#define GBA_BASE_OAM        (volatile unsigned char *)GBA_OAM_ADDR     /**< OAM - OBJ Attribytes                  */
-#define GBA_BASE_ROM0       (volatile unsigned char *)GBA_ROM0_ADDR    /**< Card ROM 32MB                         */
-#define GBA_BASE_ROM1       (volatile unsigned char *)GBA_ROM1_ADDR    /**< Card ROM 32MB                         */
-#define GBA_BASE_ROM2       (volatile unsigned char *)GBA_ROM2_ADDR    /**< Card ROM 32MB                         */
-#define GBA_BASE_SRAM       (volatile unsigned char *)GBA_SRAM_ADDR    /**< Card SRAM 64KBytes                    */
-#endif
-/*---------------------------------------------------------------------------*
- *   Display Control
- *---------------------------------------------------------------------------*/
-#define GBA_DISP_BG_MODE_MASK    0x0007      /**< BG Mode       */
-#define GBA_DISP_ON_MASK         0x1f00      /**< OBJ BG ON     */
-#define GBA_DISP_WIN_MASK        0x6000      /**< Window ON     */
-
-#define GBA_DISP_BG_MODE_SHIFT   0
-#define GBA_DISP_ON_SHIFT        8
-#define GBA_DISP_WIN_SHIFT       13
-
-#define GBA_DISP_MODE_0          0x0000      /**< BG Mode 0     */
-#define GBA_DISP_MODE_1          0x0001      /**< BG Mode 1     */
-#define GBA_DISP_MODE_2          0x0002      /**< BG Mode 2     */
-#define GBA_DISP_MODE_3          0x0003      /**< BG Mode 3     */
-#define GBA_DISP_MODE_4          0x0004      /**< BG Mode 4     */
-#define GBA_DISP_MODE_5          0x0005      /**< BG Mode 5     */
-#define GBA_DISP_BMP_FRAME_NO    0x0010      /**< Bitmap Mode Display Frame     */
-#define GBA_DISP_OBJ_HOFF        0x0020      /**< OBJ Processing in H Blank OFF */
-#define GBA_DISP_OBJ_CHAR_2D_MAP 0x0000      /**< OBJ Character Data 2D Mapping */
-#define GBA_DISP_OBJ_CHAR_1D_MAP 0x0040      /**< OBJ Character Data 1D Mapping */
-#define GBA_DISP_LCDC_OFF        0x0080      /**< LCDC OFF       */
-#define GBA_DISP_BG0_ON          0x0100      /**< BG0 ON         */
-#define GBA_DISP_BG1_ON          0x0200      /**< BG1 ON         */
-#define GBA_DISP_BG2_ON          0x0400      /**< BG2 ON         */
-#define GBA_DISP_BG3_ON          0x0800      /**< BG3 ON         */
-#define GBA_DISP_BG_ALL_ON       0x0f00      /**< All BG ON      */
-#define GBA_DISP_OBJ_ON          0x1000      /**< OBJ ON         */
-#define GBA_DISP_OBJ_BG_ALL_ON   0x1f00      /**< All OBJ/BG ON  */
-#define GBA_DISP_WIN0_ON         0x2000      /**< Window 0 ON    */
-#define GBA_DISP_WIN1_ON         0x4000      /**< Window 1 ON    */
-#define GBA_DISP_WIN01_ON        0x6000      /**< Window 0,1 ON  */
-#define GBA_DISP_OBJWIN_ON       0x8000      /**< OBJ Window ON  */
-#define GBA_DISP_WIN_ALL_ON      0xe000      /**< All Window ON  */
-#define GBA_DISP_ALL_ON          0x7f00      /**< All ON         */
-
-#define GBA_BG_MODE_0            0
-#define GBA_BG_MODE_1            1
-#define GBA_BG_MODE_2            2
-#define GBA_BG_MODE_3            3
-#define GBA_BG_MODE_4            4
-#define GBA_BG_MODE_5            5
-
-#define GBA_BG0_ENABLE           1
-#define GBA_BG1_ENABLE           2
-#define GBA_BG2_ENABLE           4
-#define GBA_BG3_ENABLE           8
-#define GBA_OBJ_ENABLE          16
-
-#define GBA_OBJ_1D_MAP           1
-#define GBA_OBJ_2D_MAP           0
-
-
-/*---------------------------------------------------------------------------+
-|    LCD
-+----------------------------------------------------------------------------*/
-/* LCD I/O Register address offsets */
-#define GBA_DISPCNT             0x00000000   /**< LCD Control                */
-#define GBA_DISPSTAT            0x00000004   /**< General LCD Status (STAT,LYC) */
-#define GBA_VCOUNT              0x00000006   /**< Vertical Counter (LY)      */
-#define GBA_BG0CNT              0x00000008   /**< BG0 Control                */
-#define GBA_BG1CNT              0x0000000A   /**< BG1 Control                */
-#define GBA_BG2CNT              0x0000000C   /**< BG2 Control                */
-#define GBA_BG3CNT              0x0000000E   /**< BG3 Control                */
-#define GBA_BG0HOFS             0x00000010   /**< BG0 X-Offset               */
-#define GBA_BG0VOFS             0x00000012   /**< BG0 Y-Offset               */
-#define GBA_BG1HOFS             0x00000014   /**< BG1 X-Offset               */
-#define GBA_BG1VOFS             0x00000016   /**< BG1 Y-Offset               */
-#define GBA_BG2HOFS             0x00000018   /**< BG2 X-Offset               */
-#define GBA_BG2VOFS             0x0000001A   /**< BG2 Y-Offset               */
-#define GBA_BG3HOFS             0x0000001C   /**< BG3 X-Offset               */
-#define GBA_BG3VOFS             0x0000001E   /**< BG3 Y-Offset               */
-#define GBA_BG2PA               0x00000020   /**< BG2 Rotation/Scaling Parameter A (dx)  */
-#define GBA_BG2PB               0x00000022   /**< BG2 Rotation/Scaling Parameter B (dmx) */
-#define GBA_BG2PC               0x00000024   /**< BG2 Rotation/Scaling Parameter C (dy)  */
-#define GBA_BG2PD               0x00000026   /**< BG2 Rotation/Scaling Parameter D (dmy) */
-#define GBA_BG2X                0x00000028   /**< BG2 Reference Point X-Coordinate       */
-#define GBA_BG2X_L              0x00000028   /**< BG2 Reference Point X-Coordinate low   */
-#define GBA_BG2X_H              0x0000002A   /**< BG2 Reference Point X-Coordinate high  */
-#define GBA_BG2Y                0x0000002C   /**< BG2 Reference Point Y-Coordinate       */
-#define GBA_BG2Y_L              0x0000002C   /**< BG2 Reference Point Y-Coordinate low   */
-#define GBA_BG2Y_H              0x0000002E   /**< BG2 Reference Point Y-Coordinate high  */
-#define GBA_BG3PA               0x00000030   /**< BG3 Rotation/Scaling Parameter A (dx)  */
-#define GBA_BG3PB               0x00000032   /**< BG3 Rotation/Scaling Parameter B (dmx) */
-#define GBA_BG3PC               0x00000034   /**< BG3 Rotation/Scaling Parameter C (dy)  */
-#define GBA_BG3PD               0x00000036   /**< BG3 Rotation/Scaling Parameter D (dmy) */
-#define GBA_BG3X                0x00000038   /**< BG3 Reference Point X-Coordinate       */
-#define GBA_BG3X_L              0x00000038   /**< BG3 Reference Point X-Coordinate low   */
-#define GBA_BG3X_H              0x0000003A   /**< BG3 Reference Point X-Coordinate high  */
-#define GBA_BG3Y                0x0000003C   /**< BG3 Reference Point Y-Coordinate       */
-#define GBA_BG3Y_L              0x0000003C   /**< BG3 Reference Point Y-Coordinate low   */
-#define GBA_BG3Y_H              0x0000003E   /**< BG3 Reference Point Y-Coordinate hugh  */
-#define GBA_WIN0H               0x00000040   /**< Window 0 Horizontal Dimensions         */
-#define GBA_WIN1H               0x00000042   /**< Window 1 Horizontal Dimensions         */
-#define GBA_WIN0V               0x00000044   /**< Window 0 Vertical Dimensions           */
-#define GBA_WIN1V               0x00000046   /**< Window 1 Vertical Dimensions           */
-#define GBA_WININ               0x00000048   /**< Control Inside of Window(s)            */
-#define GBA_WINOUT              0x0000004A   /**< Control Outside of Windows & Inside of OBJ Window */
-#define GBA_MOSAIC              0x0000004C   /**< Mosaic Size                            */
-#define GBA_BLDCNT              0x00000050   /**< Color Special Effects Selection        */
-#define GBA_BLDMOD              0x00000050   /**< Color Special Effects Selection       X*/
-#define GBA_BLDALPHA            0x00000052   /**< Alpha Blending Coefficients            */
-#define GBA_COLEV               0x00000052   /**< Alpha Blending Coefficients           X*/
-#define GBA_BLDY                0x00000054   /**< Brightness (Fade-In/Out) Coefficient   */
-#define GBA_COLY                0x00000054   /**< Brightness (Fade-In/Out) Coefficient  X*/
-/* LCD I/O Register addresses */
-#define GBA_REG_DISPCNT_ADDR    GBA_IO_REGS_ADDR + GBA_DISPCNT
-#define GBA_REG_DISPSTAT_ADDR   GBA_IO_REGS_ADDR + GBA_DISPSTAT
-#define GBA_REG_VCOUNT_ADDR     GBA_IO_REGS_ADDR + GBA_VCOUNT
-#define GBA_REG_BG0CNT_ADDR     GBA_IO_REGS_ADDR + GBA_BG0CNT
-#define GBA_REG_BG1CNT_ADDR     GBA_IO_REGS_ADDR + GBA_BG1CNT
-#define GBA_REG_BG2CNT_ADDR     GBA_IO_REGS_ADDR + GBA_BG2CNT
-#define GBA_REG_BG3CNT_ADDR     GBA_IO_REGS_ADDR + GBA_BG3CNT
-#define GBA_REG_BG0HOFS_ADDR    GBA_IO_REGS_ADDR + GBA_BG0HOFS
-#define GBA_REG_BG0VOFS_ADDR    GBA_IO_REGS_ADDR + GBA_BG0VOFS
-#define GBA_REG_BG1HOFS_ADDR    GBA_IO_REGS_ADDR + GBA_BG1HOFS
-#define GBA_REG_BG1VOFS_ADDR    GBA_IO_REGS_ADDR + GBA_BG1VOFS
-#define GBA_REG_BG2HOFS_ADDR    GBA_IO_REGS_ADDR + GBA_BG2HOFS
-#define GBA_REG_BG2VOFS_ADDR    GBA_IO_REGS_ADDR + GBA_BG2VOFS
-#define GBA_REG_BG3HOFS_ADDR    GBA_IO_REGS_ADDR + GBA_BG3HOFS
-#define GBA_REG_BG3VOFS_ADDR    GBA_IO_REGS_ADDR + GBA_BG3VOFS
-#define GBA_REG_BG2PA_ADDR      GBA_IO_REGS_ADDR + GBA_BG2PA
-#define GBA_REG_BG2PB_ADDR      GBA_IO_REGS_ADDR + GBA_BG2PB
-#define GBA_REG_BG2PC_ADDR      GBA_IO_REGS_ADDR + GBA_BG2PC
-#define GBA_REG_BG2PD_ADDR      GBA_IO_REGS_ADDR + GBA_BG2PD
-#define GBA_REG_BG2X_ADDR       GBA_IO_REGS_ADDR + GBA_BG2X
-#define GBA_REG_BG2X_L_ADDR     GBA_IO_REGS_ADDR + GBA_BG2X_L
-#define GBA_REG_BG2X_H_ADDR     GBA_IO_REGS_ADDR + GBA_BG2X_H
-#define GBA_REG_BG2Y_ADDR       GBA_IO_REGS_ADDR + GBA_BG2Y
-#define GBA_REG_BG2Y_L_ADDR     GBA_IO_REGS_ADDR + GBA_BG2Y_L
-#define GBA_REG_BG2Y_H_ADDR     GBA_IO_REGS_ADDR + GBA_BG2Y_H
-#define GBA_REG_BG3PA_ADDR      GBA_IO_REGS_ADDR + GBA_BG3PA
-#define GBA_REG_BG3PB_ADDR      GBA_IO_REGS_ADDR + GBA_BG3PB
-#define GBA_REG_BG3PC_ADDR      GBA_IO_REGS_ADDR + GBA_BG3PC
-#define GBA_REG_BG3PD_ADDR      GBA_IO_REGS_ADDR + GBA_BG3PD
-#define GBA_REG_BG3X_ADDR       GBA_IO_REGS_ADDR + GBA_BG3X
-#define GBA_REG_BG3X_L_ADDR     GBA_IO_REGS_ADDR + GBA_BG3X_L
-#define GBA_REG_BG3X_H_ADDR     GBA_IO_REGS_ADDR + GBA_BG3X_H
-#define GBA_REG_BG3Y_ADDR       GBA_IO_REGS_ADDR + GBA_BG3Y
-#define GBA_REG_BG3Y_L_ADDR     GBA_IO_REGS_ADDR + GBA_BG3Y_L
-#define GBA_REG_BG3Y_H_ADDR     GBA_IO_REGS_ADDR + GBA_BG3Y_H
-#define GBA_REG_WIN0H_ADDR      GBA_IO_REGS_ADDR + GBA_WIN0H
-#define GBA_REG_WIN1H_ADDR      GBA_IO_REGS_ADDR + GBA_WIN1H
-#define GBA_REG_WIN0V_ADDR      GBA_IO_REGS_ADDR + GBA_WIN0V
-#define GBA_REG_WIN1V_ADDR      GBA_IO_REGS_ADDR + GBA_WIN1V
-#define GBA_REG_WININ_ADDR      GBA_IO_REGS_ADDR + GBA_WININ
-#define GBA_REG_WINOUT_ADDR     GBA_IO_REGS_ADDR + GBA_WINOUT
-#define GBA_REG_MOSAIC_ADDR     GBA_IO_REGS_ADDR + GBA_MOSAIC
-#define GBA_REG_BLDCNT_ADDR     GBA_IO_REGS_ADDR + GBA_BLDCNT
-#define GBA_REG_BLDMOD_ADDR     GBA_IO_REGS_ADDR + GBA_BLDMOD
-#define GBA_REG_BLDALPHA_ADDR   GBA_IO_REGS_ADDR + GBA_BLDALPHA
-#define GBA_REG_COLEV_ADDR      GBA_IO_REGS_ADDR + GBA_COLEV
-#define GBA_REG_BLDY_ADDR       GBA_IO_REGS_ADDR + GBA_BLDY
-#define GBA_REG_COLY_ADDR       GBA_IO_REGS_ADDR + GBA_COLY
-/* LCD I/O Registers */
-#ifndef __asm__
-#define GBA_REG_DISPCNT         (*(volatile unsigned short *)(GBA_REG_DISPCNT_ADDR))
-#define GBA_REG_DISPSTAT        (*(volatile unsigned short *)(GBA_REG_DISPSTAT_ADDR))
-#define GBA_REG_VCOUNT          (*(volatile unsigned short *)(GBA_REG_VCOUNT_ADDR))
-#define GBA_REG_BG0CNT          (*(volatile unsigned short *)(GBA_REG_BG0CNT_ADDR))
-#define GBA_REG_BG1CNT          (*(volatile unsigned short *)(GBA_REG_BG1CNT_ADDR))
-#define GBA_REG_BG2CNT          (*(volatile unsigned short *)(GBA_REG_BG2CNT_ADDR))
-#define GBA_REG_BG3CNT          (*(volatile unsigned short *)(GBA_REG_BG3CNT_ADDR))
-#define GBA_REG_BG0HOFS         (*(volatile unsigned short *)(GBA_REG_BG0HOFS_ADDR))
-#define GBA_REG_BG0VOFS         (*(volatile unsigned short *)(GBA_REG_BG0VOFS_ADDR))
-#define GBA_REG_BG1HOFS         (*(volatile unsigned short *)(GBA_REG_BG1HOFS_ADDR))
-#define GBA_REG_BG1VOFS         (*(volatile unsigned short *)(GBA_REG_BG1VOFS_ADDR))
-#define GBA_REG_BG2HOFS         (*(volatile unsigned short *)(GBA_REG_BG2HOFS_ADDR))
-#define GBA_REG_BG2VOFS         (*(volatile unsigned short *)(GBA_REG_BG2VOFS_ADDR))
-#define GBA_REG_BG3HOFS         (*(volatile unsigned short *)(GBA_REG_BG3HOFS_ADDR))
-#define GBA_REG_BG3VOFS         (*(volatile unsigned short *)(GBA_REG_BG3VOFS_ADDR))
-#define GBA_REG_BG2PA           (*(volatile unsigned short *)(GBA_REG_BG2PA_ADDR))
-#define GBA_REG_BG2PB           (*(volatile unsigned short *)(GBA_REG_BG2PB_ADDR))
-#define GBA_REG_BG2PC           (*(volatile unsigned short *)(GBA_REG_BG2PC_ADDR))
-#define GBA_REG_BG2PD           (*(volatile unsigned short *)(GBA_REG_BG2PD_ADDR))
-#define GBA_REG_BG2X            (*(volatile unsigned int   *)(GBA_REG_BG2X_ADDR))
-#define GBA_REG_BG2X_L          (*(volatile unsigned short *)(GBA_REG_BG2X_L_ADDR))
-#define GBA_REG_BG2X_H          (*(volatile unsigned short *)(GBA_REG_BG2X_H_ADDR))
-#define GBA_REG_BG2Y            (*(volatile unsigned int   *)(GBA_REG_BG2Y_ADDR))
-#define GBA_REG_BG2Y_L          (*(volatile unsigned short *)(GBA_REG_BG2Y_L_ADDR))
-#define GBA_REG_BG2Y_H          (*(volatile unsigned short *)(GBA_REG_BG2Y_H_ADDR))
-#define GBA_REG_BG3PA           (*(volatile unsigned short *)(GBA_REG_BG3PA_ADDR))
-#define GBA_REG_BG3PB           (*(volatile unsigned short *)(GBA_REG_BG3PB_ADDR))
-#define GBA_REG_BG3PC           (*(volatile unsigned short *)(GBA_REG_BG3PC_ADDR))
-#define GBA_REG_BG3PD           (*(volatile unsigned short *)(GBA_REG_BG3PD_ADDR))
-#define GBA_REG_BG3X            (*(volatile unsigned int   *)(GBA_REG_BG3X_ADDR))
-#define GBA_REG_BG3X_L          (*(volatile unsigned short *)(GBA_REG_BG3X_L_ADDR))
-#define GBA_REG_BG3X_H          (*(volatile unsigned short *)(GBA_REG_BG3X_H_ADDR))
-#define GBA_REG_BG3Y            (*(volatile unsigned int   *)(GBA_REG_BG3Y_ADDR))
-#define GBA_REG_BG3Y_L          (*(volatile unsigned short *)(GBA_REG_BG3Y_L_ADDR))
-#define GBA_REG_BG3Y_H          (*(volatile unsigned short *)(GBA_REG_BG3Y_H_ADDR))
-#define GBA_REG_WIN0H           (*(volatile unsigned short *)(GBA_REG_WIN0H_ADDR))
-#define GBA_REG_WIN1H           (*(volatile unsigned short *)(GBA_REG_WIN1H_ADDR))
-#define GBA_REG_WIN0V           (*(volatile unsigned short *)(GBA_REG_WIN0V_ADDR))
-#define GBA_REG_WIN1V           (*(volatile unsigned short *)(GBA_REG_WIN1V_ADDR))
-#define GBA_REG_WININ           (*(volatile unsigned short *)(GBA_REG_WININ_ADDR))
-#define GBA_REG_WINOUT          (*(volatile unsigned short *)(GBA_REG_WINOUT_ADDR))
-#define GBA_REG_MOSAIC          (*(volatile unsigned short *)(GBA_REG_MOSAIC_ADDR))
-#define GBA_REG_BLDCNT          (*(volatile unsigned short *)(GBA_REG_BLDCNT_ADDR))
-#define GBA_REG_BLDMOD          (*(volatile unsigned short *)(GBA_REG_BLDMOD_ADDR))
-#define GBA_REG_BLDALPHA        (*(volatile unsigned short *)(GBA_REG_BLDALPHA_ADDR))
-#define GBA_REG_COLEV           (*(volatile unsigned short *)(GBA_REG_COLEV_ADDR))
-#define GBA_REG_BLDY            (*(volatile unsigned short *)(GBA_REG_BLDY_ADDR))
-#define GBA_REG_COLY            (*(volatile unsigned short *)(GBA_REG_COLY_ADDR))
-#endif
-/*---------------------------------------------------------------------------+
-|    SOUND
-+----------------------------------------------------------------------------*/
-#define GBA_SOUND_INIT            0x8000  /**< makes the sound restart       */
-#define GBA_SOUND_DUTY87          0x0000  /**< 87.5% wave duty               */
-#define GBA_SOUND_DUTY75          0x0040  /**< 75% wave duty                 */
-#define GBA_SOUND_DUTY50          0x0080  /**< 50% wave duty                 */
-#define GBA_SOUND_DUTY25          0x00C0  /**< 25% wave duty                 */
-
-#define GBA_SOUND1_PLAYONCE       0x4000  /**< play sound once               */
-#define GBA_SOUND1_PLAYLOOP       0x0000  /**< play sound looped             */
-#define GBA_SOUND1_INIT           0x8000  /**< makes the sound restart       */
-#define GBA_SOUND1_SWEEPSHIFTS(n)(n)      /**< number of sweep shifts (0-7)  */
-#define GBA_SOUND1_SWEEPINC       0x0000  /**< sweep add (freq increase)     */
-#define GBA_SOUND1_SWEEPDEC       0x0008  /**< sweep dec (freq decrese)      */
-#define GBA_SOUND1_SWEEPTIME(n)  (n<<4)   /**< time of sweep (0-7)           */
-#define GBA_SOUND1_ENVSTEPS(n)   (n<<8)   /**< envelope steps (0-7)          */
-#define GBA_SOUND1_ENVINC         0x0800  /**< envelope increase             */
-#define GBA_SOUND1_ENVDEC         0x0000  /**< envelope decrease             */
-#define GBA_SOUND1_ENVINIT(n)    (n<<12)  /**< initial envelope volume (0-15)*/
-
-#define GBA_SOUND2_PLAYONCE       0x4000  /**< play sound once               */
-#define GBA_SOUND2_PLAYLOOP       0x0000  /**< play sound looped             */
-#define GBA_SOUND2_INIT           0x8000  /**< makes the sound restart       */
-#define GBA_SOUND2_ENVSTEPS(n)   (n<<8)   /**< envelope steps (0-7)          */
-#define GBA_SOUND2_ENVINC         0x0800  /**< envelope increase             */
-#define GBA_SOUND2_ENVDEC         0x0000  /**< envelope decrease             */
-#define GBA_SOUND2_ENVINIT(n)    (n<<12)  /**< initial envelope volume (0-15)*/
-
-#define GBA_SOUND3_BANK32         0x0000  /**< Use two banks of 32 steps each*/
-#define GBA_SOUND3_BANK64         0x0020  /**< Use one bank of 64 steps      */
-#define GBA_SOUND3_SETBANK0       0x0000  /**< Bank to play 0 or 1 (non set bank is written to) */
-#define GBA_SOUND3_SETBANK1       0x0040
-#define GBA_SOUND3_PLAY           0x0080  /**< Output sound                  */
-
-#define GBA_SOUND3_OUTPUT0        0x0000  /**< Mute output                   */
-#define GBA_SOUND3_OUTPUT1        0x2000  /**< Output unmodified             */
-#define GBA_SOUND3_OUTPUT12       0x4000  /**< Output 1/2                    */
-#define GBA_SOUND3_OUTPUT14       0x6000  /**< Output 1/4                    */
-#define GBA_SOUND3_OUTPUT34       0x8000  /**< Output 3/4                    */
-
-#define GBA_SOUND3_PLAYONCE       0x4000  /**< Play sound once               */
-#define GBA_SOUND3_PLAYLOOP       0x0000  /**< Play sound looped             */
-#define GBA_SOUND3_INIT           0x8000  /**< Makes the sound restart       */
-
-#define GBA_SOUND4_PLAYONCE       0x4000  /**< play sound once               */
-#define GBA_SOUND4_PLAYLOOP       0x0000  /**< play sound looped             */
-#define GBA_SOUND4_INIT           0x8000  /**< makes the sound restart       */
-#define GBA_SOUND4_ENVSTEPS(n)   (n<<8)   /**< envelope steps (0-7)          */
-#define GBA_SOUND4_ENVINC         0x0800  /**< envelope increase             */
-#define GBA_SOUND4_ENVDEC         0x0000  /**< envelope decrease             */
-#define GBA_SOUND4_ENVINIT(n)    (n<<12)  /**< initial envelope volume (0-15)*/
-
-#define GBA_SOUND4_STEPS7         0x0004
-#define GBA_SOUND4_STEPS15        0x0000
-#define GBA_SOUND4_PLAYONCE       0x4000
-#define GBA_SOUND4_PLAYLOOP       0x0000
-#define GBA_SOUND4_INIT           0x8000
-
-/* Sound Register address offsets */
-#define GBA_SOUND1CNT_L         0x00000060    /**< Channel 1 sweep           */
-#define GBA_SG10                0x00000060    /**< Channel 1 sweep low      X*/
-#define GBA_SG10_L              0x00000060    /**< Channel 1 sweep high     X*/
-#define GBA_SOUND1CNT_H         0x00000062    /**< Channel 1 Duty/Len/Env    */
-#define GBA_SG10_H              0x00000062    /**< Channel 1 Duty/Len/Env   X*/
-#define GBA_SOUND1CNT_X         0x00000064    /**< Channel 1 Freq/Control    */
-#define GBA_SG11                0x00000064    /**< Channel 1 Freq/Control   X*/
-#define GBA_SOUND2CNT_L         0x00000068    /**< Channel 2 Duty/Len/Env    */
-#define GBA_SG20                0x00000068    /**< Channel 2 Duty/Len/Env   X*/
-#define GBA_SOUND2CNT_H         0x0000006C    /**< Channel 2 Freq/Control    */
-#define GBA_SG21                0x0000006C    /**< Channel 2 Freq/Control   X*/
-#define GBA_SOUND3CNT_L         0x00000070    /**< Channel 3 Stop/Wave RAM   */
-#define GBA_SG30                0x00000070    /**< Channel 3 Stop/Wave RAM  X*/
-#define GBA_SG30_L              0x00000070    /**< Channel 3 Stop/Wave RAM  X*/
-#define GBA_SOUND3CNT_H         0x00000072    /**< Channel 3 Len/Vol         */
-#define GBA_SG30_H              0x00000072    /**< Channel 3 Len/Vol        X*/
-#define GBA_SOUND3CNT_X         0x00000074    /**< Channel 3 Freq/Control    */
-#define GBA_SG31                0x00000074    /**< Channel 3 Freq/Control   X*/
-#define GBA_SOUND4CNT_L         0x00000078    /**< Channel 4 Len/Env         */
-#define GBA_SG40                0x00000078    /**< Channel 4 Len/Env        X*/
-#define GBA_SOUND4CNT_H         0x0000007C    /**< Channel 4 Freq/Control    */
-#define GBA_SG41                0x0000007C    /**< Channel 4 Freq/Control   X*/
-#define GBA_SOUNDCNT_L          0x00000080    /**< Control LR/Vol/Enable     */
-#define GBA_SGCNT0_L            0x00000080    /**< Control LR/Vol/Enable    X*/
-#define GBA_SOUNDCNT_H          0x00000082    /**< Control Mixing/DMA        */
-#define GBA_SGCNT0_H            0x00000082    /**< Control Mixing/DMA       X*/
-#define GBA_SOUNDCNT_X          0x00000084    /**< Control Sound on/off      */
-#define GBA_SGCNT1              0x00000084    /**< Control Sound on/off     X*/
-#define GBA_SOUNDBIAS           0x00000088    /**< Sound PWM control         */
-#define GBA_SGBIAS              0x00000088    /**< Sound PWM control        X*/
-#define GBA_SGWR0               0x00000090    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_WAVE_RAM0_L         0x00000090    /**< Ch3 Wave Pattern RAM      */
-#define GBA_SGWR0_L             0x00000090    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_WAVE_RAM0_H         0x00000092    /**< Ch3 Wave Pattern RAM      */
-#define GBA_SGWR0_H             0x00000092    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_SGWR1               0x00000094    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_WAVE_RAM1_L         0x00000094    /**< Ch3 Wave Pattern RAM      */
-#define GBA_SGWR1_L             0x00000094    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_WAVE_RAM1_H         0x00000096    /**< Ch3 Wave Pattern RAM      */
-#define GBA_SGWR1_H             0x00000096    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_SGWR2               0x00000098    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_WAVE_RAM2_L         0x00000098    /**< Ch3 Wave Pattern RAM      */
-#define GBA_SGWR2_L             0x00000098    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_WAVE_RAM2_H         0x0000009A    /**< Ch3 Wave Pattern RAM      */
-#define GBA_SGWR2_H             0x0000009A    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_SGWR3               0x0000009C    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_WAVE_RAM3_L         0x0000009C    /**< Ch3 Wave Pattern RAM      */
-#define GBA_SGWR3_L             0x0000009C    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_WAVE_RAM3_H         0x0000009E    /**< Ch3 Wave Pattern RAM      */
-#define GBA_SGWR3_H             0x0000009E    /**< Ch3 Wave Pattern RAM     X*/
-#define GBA_SGFIF0A             0x000000A0    /**< Sound A FIFO              X*/
-#define GBA_FIFO_A_L            0x000000A0    /**< Sound A FIFO               */
-#define GBA_SGFIFOA_L           0x000000A0    /**< Sound A FIFO              X*/
-#define GBA_FIFO_A_H            0x000000A2    /**< Sound A FIFO               */
-#define GBA_SGFIFOA_H           0x000000A2    /**< Sound A FIFO              X*/
-#define GBA_SGFIFOB             0x000000A4    /**< Sound B FIFO              X*/
-#define GBA_FIFO_B_L            0x000000A4    /**< Sound B FIFO               */
-#define GBA_SGFIFOB_L           0x000000A4    /**< Sound B FIFO              X*/
-#define GBA_FIFO_B_H            0x000000A6    /**< Sound B FIFO               */
-#define GBA_SGFIFOB_H           0x000000A6    /**< Sound B FIFO              X*/
-/* Sound Registers addresses */
-#define GBA_REG_SOUND1CNT_L_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND1CNT_L
-#define GBA_REG_SG10_ADDR         GBA_IO_REGS_ADDR + GBA_SG10
-#define GBA_REG_SG10_L_ADDR       GBA_IO_REGS_ADDR + GBA_SG10_L
-#define GBA_REG_SOUND1CNT_H_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND1CNT_H
-#define GBA_REG_SG10_H_ADDR       GBA_IO_REGS_ADDR + GBA_SG10_H
-#define GBA_REG_SOUND1CNT_X_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND1CNT_X
-#define GBA_REG_SG11_ADDR         GBA_IO_REGS_ADDR + GBA_SG11
-#define GBA_REG_SOUND2CNT_L_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND2CNT_L
-#define GBA_REG_SG20_ADDR         GBA_IO_REGS_ADDR + GBA_SG20
-#define GBA_REG_SOUND2CNT_H_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND2CNT_H
-#define GBA_REG_SG21_ADDR         GBA_IO_REGS_ADDR + GBA_SG21
-#define GBA_REG_SOUND3CNT_L_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND3CNT_L
-#define GBA_REG_SG30_ADDR         GBA_IO_REGS_ADDR + GBA_SG30
-#define GBA_REG_SG30_L_ADDR       GBA_IO_REGS_ADDR + GBA_SG30_L
-#define GBA_REG_SOUND3CNT_H_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND3CNT_H
-#define GBA_REG_SG30_H_ADDR       GBA_IO_REGS_ADDR + GBA_SG30_H
-#define GBA_REG_SOUND3CNT_X_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND3CNT_X
-#define GBA_REG_SG31_ADDR         GBA_IO_REGS_ADDR + GBA_SG31
-#define GBA_REG_SOUND4CNT_L_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND4CNT_L
-#define GBA_REG_SG40_ADDR         GBA_IO_REGS_ADDR + GBA_SG40
-#define GBA_REG_SOUND4CNT_H_ADDR  GBA_IO_REGS_ADDR + GBA_SOUND4CNT_H
-#define GBA_REG_SG41_ADDR         GBA_IO_REGS_ADDR + GBA_SG41
-#define GBA_REG_SOUNDCNT_L_ADDR   GBA_IO_REGS_ADDR + GBA_SOUNDCNT_L
-#define GBA_REG_SGCNT0_L_ADDR     GBA_IO_REGS_ADDR + GBA_SGCNT0_L
-#define GBA_REG_SOUNDCNT_H_ADDR   GBA_IO_REGS_ADDR + GBA_SOUNDCNT_H
-#define GBA_REG_SGCNT0_H_ADDR     GBA_IO_REGS_ADDR + GBA_SGCNT0_H
-#define GBA_REG_SOUNDCNT_X_ADDR   GBA_IO_REGS_ADDR + GBA_SOUNDCNT_X
-#define GBA_REG_SGCNT1_ADDR       GBA_IO_REGS_ADDR + GBA_SGCNT1
-#define GBA_REG_SGBIAS_ADDR       GBA_IO_REGS_ADDR + GBA_SGBIAS
-#define GBA_REG_SOUNDBIAS_ADDR    GBA_IO_REGS_ADDR + GBA_SOUNDBIAS
-#define GBA_REG_SGWR0_ADDR        GBA_IO_REGS_ADDR + GBA_SGWR0
-#define GBA_REG_WAVE_RAM0_L_ADDR  GBA_IO_REGS_ADDR + GBA_WAVE_RAM0_L
-#define GBA_REG_SGWR0_L_ADDR      GBA_IO_REGS_ADDR + GBA_SGWR0_L
-#define GBA_REG_WAVE_RAM0_H_ADDR  GBA_IO_REGS_ADDR + GBA_WAVE_RAM0_H
-#define GBA_REG_SGWR0_H_ADDR      GBA_IO_REGS_ADDR + GBA_SGWR0_H
-#define GBA_REG_SGWR1_ADDR        GBA_IO_REGS_ADDR + GBA_SGWR1
-#define GBA_REG_WAVE_RAM1_L_ADDR  GBA_IO_REGS_ADDR + GBA_WAVE_RAM1_L
-#define GBA_REG_SGWR1_L_ADDR      GBA_IO_REGS_ADDR + GBA_SGWR1_L
-#define GBA_REG_WAVE_RAM1_H_ADDR  GBA_IO_REGS_ADDR + GBA_WAVE_RAM1_H
-#define GBA_REG_SGWR1_H_ADDR      GBA_IO_REGS_ADDR + GBA_SGWR1_H
-#define GBA_REG_SGWR2_ADDR        GBA_IO_REGS_ADDR + GBA_SGWR2
-#define GBA_REG_WAVE_RAM2_L_ADDR  GBA_IO_REGS_ADDR + GBA_WAVE_RAM2_L
-#define GBA_REG_SGWR2_L_ADDR      GBA_IO_REGS_ADDR + GBA_SGWR2_L
-#define GBA_REG_WAVE_RAM2_H_ADDR  GBA_IO_REGS_ADDR + GBA_WAVE_RAM2_H
-#define GBA_REG_SGWR2_H_ADDR      GBA_IO_REGS_ADDR + GBA_SGWR2_H
-#define GBA_REG_SGWR3_ADDR        GBA_IO_REGS_ADDR + GBA_SGWR3
-#define GBA_REG_WAVE_RAM3_L_ADDR  GBA_IO_REGS_ADDR + GBA_WAVE_RAM3_L
-#define GBA_REG_SGWR3_L_ADDR      GBA_IO_REGS_ADDR + GBA_SGWR3_L
-#define GBA_REG_WAVE_RAM3_H_ADDR  GBA_IO_REGS_ADDR + GBA_WAVE_RAM3_H
-#define GBA_REG_SGWR3_H_ADDR      GBA_IO_REGS_ADDR + GBA_SGWR3_H
-#define GBA_REG_SGFIF0A_ADDR      GBA_IO_REGS_ADDR + GBA_SGFIF0A
-#define GBA_REG_FIFO_A_L_ADDR     GBA_IO_REGS_ADDR + GBA_FIFO_A_L
-#define GBA_REG_SGFIFOA_L_ADDR    GBA_IO_REGS_ADDR + GBA_SGFIFOA_L
-#define GBA_REG_FIFO_A_H_ADDR     GBA_IO_REGS_ADDR + GBA_FIFO_A_H
-#define GBA_REG_SGFIFOA_H_ADDR    GBA_IO_REGS_ADDR + GBA_SGFIFOA_H
-#define GBA_REG_SGFIFOB_ADDR      GBA_IO_REGS_ADDR + GBA_SGFIFOB
-#define GBA_REG_FIFO_B_L_ADDR     GBA_IO_REGS_ADDR + GBA_FIFO_B_L
-#define GBA_REG_SGFIFOB_L_ADDR    GBA_IO_REGS_ADDR + GBA_SGFIFOB_L
-#define GBA_REG_FIFO_B_H_ADDR     GBA_IO_REGS_ADDR + GBA_FIFO_B_H
-#define GBA_REG_SGFIFOB_H_ADDR    GBA_IO_REGS_ADDR + GBA_SGFIFOB_H
-/* Sound Registers */
-#ifndef __asm__
-#define GBA_REG_SOUND1CNT_L     (*(volatile unsigned int   *)(GBA_REG_SOUND1CNT_L_ADDR))
-#define GBA_REG_SG10            (*(volatile unsigned int   *)(GBA_REG_SG10_ADDR))
-#define GBA_REG_SG10_L          (*(volatile unsigned short *)(GBA_REG_SG10_L_ADDR))
-#define GBA_REG_SOUND1CNT_H     (*(volatile unsigned short *)(GBA_REG_SOUND1CNT_H_ADDR))
-#define GBA_REG_SG10_H          (*(volatile unsigned short *)(GBA_REG_SG10_H_ADDR))
-#define GBA_REG_SOUND1CNT_X     (*(volatile unsigned short *)(GGBA_REG_SOUND1CNT_X_ADDR))
-#define GBA_REG_SG11            (*(volatile unsigned short *)(GBA_REG_SG11_ADDR))
-#define GBA_REG_SOUND2CNT_L     (*(volatile unsigned short *)(GBA_REG_SOUND2CNT_L_ADDR))
-#define GBA_REG_SG20            (*(volatile unsigned short *)(GBA_REG_SG20_ADDR))
-#define GBA_REG_SOUND2CNT_H     (*(volatile unsigned short *)(GBA_REG_SOUND2CNT_H_ADDR))
-#define GBA_REG_SG21            (*(volatile unsigned short *)(GBA_REG_SG21_ADDR))
-#define GBA_REG_SOUND3CNT_L     (*(volatile unsigned int   *)(GBA_REG_SOUND3CNT_L_ADDR))
-#define GBA_REG_SG30            (*(volatile unsigned int   *)(GBA_REG_SG30_ADDR))
-#define GBA_REG_SG30_L          (*(volatile unsigned short *)(GBA_REG_SG30_L_ADDR))
-#define GBA_REG_SOUND3CNT_H     (*(volatile unsigned short *)(GBA_REG_SOUND3CNT_H_ADDR))
-#define GBA_REG_SG30_H          (*(volatile unsigned short *)(GBA_REG_SG30_H_ADDR))
-#define GBA_REG_SOUND3CNT_X     (*(volatile unsigned short *)(GBA_REG_SOUND3CNT_X_ADDR))
-#define GBA_REG_SG31            (*(volatile unsigned short *)(GBA_REG_SG31_ADDR))
-#define GBA_REG_SOUND4CNT_L     (*(volatile unsigned short *)(GBA_REG_SOUND4CNT_L_ADDR))
-#define GBA_REG_SG40            (*(volatile unsigned short *)(GBA_REG_SG40_ADDR))
-#define GBA_REG_SOUND4CNT_H     (*(volatile unsigned short *)(GBA_REG_SOUND4CNT_H_ADDR))
-#define GBA_REG_SG41            (*(volatile unsigned short *)(GBA_REG_SG41_ADDR))
-#define GBA_REG_SGCNT0          (*(volatile unsigned int   *)(GBA_REG_SGCNT0_ADDR))
-#define GBA_REG_SOUNDCNT_L      (*(volatile unsigned short *)(GBA_REG_SOUNDCNT_L_ADDR))
-#define GBA_REG_SGCNT0_L        (*(volatile unsigned short *)(GBA_REG_SGCNT0_L_ADDR))
-#define GBA_REG_SOUNDCNT_H      (*(volatile unsigned short *)(GBA_REG_SOUNDCNT_H_ADDR))
-#define GBA_REG_SGCNT0_H        (*(volatile unsigned short *)(GBA_REG_SGCNT0_H_ADDR))
-#define GBA_REG_SOUNDCNT_X      (*(volatile unsigned short *)(GBA_REG_SOUNDCNT_X_ADDR))
-#define GBA_REG_SGCNT1          (*(volatile unsigned short *)(GBA_REG_SGCNT1_ADDR))
-#define GBA_REG_SOUNDBIAS       (*(volatile unsigned short *)(GBA_REG_SOUNDBIAS_ADDR))
-#define GBA_REG_SGBIAS          (*(volatile unsigned short *)(GBA_REG_SGBIAS_ADDR))
-#define GBA_REG_SGWR0           (*(volatile unsigned int   *)(GBA_REG_SGWR0_ADDR))
-#define GBA_REG_WAVE_RAM0_L     (*(volatile unsigned short *)(GBA_REG_WAVE_RAM0_L_ADDR))
-#define GBA_REG_SGWR0_L         (*(volatile unsigned short *)(GBA_REG_SGWR0_L_ADDR))
-#define GBA_REG_WAVE_RAM0_H     (*(volatile unsigned short *)(GBA_REG_WAVE_RAM0_H_ADDR))
-#define GBA_REG_SGWR0_H         (*(volatile unsigned short *)(GBA_REG_SGWR0_H_ADDR))
-#define GBA_REG_SGWR1           (*(volatile unsigned int   *)(GBA_REG_SGWR1_ADDR))
-#define GBA_REG_WAVE_RAM1_L     (*(volatile unsigned short *)(GBA_REG_WAVE_RAM1_L_ADDR))
-#define GBA_REG_SGWR1_L         (*(volatile unsigned short *)(GBA_REG_SGWR1_L_ADDR))
-#define GBA_REG_WAVE_RAM1_H     (*(volatile unsigned short *)(GBA_REG_WAVE_RAM1_H_ADDR))
-#define GBA_REG_SGWR1_H         (*(volatile unsigned short *)(GBA_REG_SGWR1_H_ADDR))
-#define GBA_REG_SGWR2           (*(volatile unsigned int   *)(GBA_REG_SGWR2_ADDR))
-#define GBA_REG_WAVE_RAM2_L     (*(volatile unsigned short *)(GBA_REG_WAVE_RAM2_L_ADDR))
-#define GBA_REG_SGWR2_L         (*(volatile unsigned short *)(GBA_REG_SGWR2_L_ADDR))
-#define GBA_REG_WAVE_RAM2_H     (*(volatile unsigned short *)(GGBA_REG_WAVE_RAM2_H_ADDR))
-#define GBA_REG_SGWR2_H         (*(volatile unsigned short *)(GGBA_REG_SGWR2_H_ADDR))
-#define GBA_REG_SGWR3           (*(volatile unsigned int   *)(GBA_REG_SGWR3_ADDR))
-#define GBA_REG_WAVE_RAM3_L     (*(volatile unsigned short *)(GBA_REG_WAVE_RAM3_L)
-#define GBA_REG_SGWR3_L         (*(volatile unsigned short *)(GBA_REG_SGWR3_L)
-#define GBA_REG_WAVE_RAM3_H     (*(volatile unsigned short *)(GBA_REG_WAVE_RAM3_H_ADDR))
-#define GBA_REG_SGWR3_H         (*(volatile unsigned short *)(GBA_REG_SGWR3_H_ADDR))
-#define GBA_REG_SGFIF0A         (*(volatile unsigned int   *)(GBA_REG_SGFIF0A_ADDR))
-#define GBA_REG_FIFO_A_L        (*(volatile unsigned short *)(GBA_REG_FIFO_A_L_ADDR))
-#define GBA_REG_SGFIFOA_L       (*(volatile unsigned short *)(GBA_REG_SGFIFOA_L_ADDR))
-#define GBA_REG_FIFO_A_H        (*(volatile unsigned short *)(GBA_REG_FIFO_A_H_ADDR))
-#define GBA_REG_SGFIFOA_H       (*(volatile unsigned short *)(GBA_REG_SGFIFOA_H_ADDR))
-#define GBA_REG_SGFIFOB         (*(volatile unsigned int   *)(GBA_REG_SGFIFOB_ADDR))
-#define GBA_REG_FIFO_B_L        (*(volatile unsigned short *)(GBA_REG_FIFO_B_L_ADDR))
-#define GBA_REG_SGFIFOB_L       (*(volatile unsigned short *)(GBA_REG_SGFIFOB_L_ADDR))
-#define GBA_REG_FIFO_B_H        (*(volatile unsigned short *)(GBA_REG_FIFO_B_H_ADDR))
-#define GBA_REG_SGFIFOB_H       (*(volatile unsigned short *)(GBA_REG_SGFIFOB_H_ADDR))
-#endif
-
-/*---------------------------------------------------------------------------+
-|    DMA
-+----------------------------------------------------------------------------*/
-#define GBA_DMA_ENABLE            0x80000000  /**<  DMA Enable               */
-#define GBA_DMA_IF_ENABLE         0x40000000  /**<  Interrupt Request Enable */
-#define GBA_DMA_TIMMING_IMM       0x00000000  /**<  Run Immediately          */
-#define GBA_DMA_TIMMING_V_BLANK   0x10000000  /**<  Run V Blank              */
-#define GBA_DMA_TIMMING_H_BLANK   0x20000000  /**<  Run H Blank              */
-#define GBA_DMA_TIMMING_DISP      0x30000000  /**<  Run Display              */
-#define GBA_DMA_TIMMING_SOUND     0x30000000  /**<  Run Sound FIFO Request   */
-#define GBA_DMA_DREQ_ON           0x08000000  /**<  Data Request Synchronize Mode ON */
-#define GBA_DMA_16BIT_BUS         0x00000000  /**<  Select Bus Size 16Bit    */
-#define GBA_DMA_32BIT_BUS         0x04000000  /**<  Select Bus Size 32Bit    */
-#define GBA_DMA_CONTINUOUS_ON     0x02000000  /**<  Continuous Mode ON       */
-#define GBA_DMA_SRC_INC           0x00000000  /**<  Select Source Increment  */
-#define GBA_DMA_SRC_DEC           0x00800000  /**<  Select Source Decrement  */
-#define GBA_DMA_SRC_FIX           0x01000000  /**<  Select Source Fixed      */
-#define GBA_DMA_DEST_INC          0x00000000  /**<  Select Destination Increment */
-#define GBA_DMA_DEST_DEC          0x00200000  /**<  Select Destination Decrement */
-#define GBA_DMA_DEST_FIX          0x00400000  /**<  Select Destination Fixed */
-#define GBA_DMA_DEST_RELOAD       0x00600000  /**<  Select Destination       */
-
-
-/* DMA Transfer Channel address offsets */
-#define GBA_DMA0SAD             0x000000B0   /**< DMA0 Source Address             */
-#define GBA_DMA0SAD_L           0x000000B0   /**< DMA0 Source Address Low Value   */
-#define GBA_DMA0SAD_H           0x000000B2   /**< DMA0 Source Address High Value  */
-#define GBA_DMA0DAD             0x000000B4   /**< DMA0 Destination Address        */
-#define GBA_DMA0DAD_L           0x000000B4   /**< DMA0 Destination Address Low Value  */
-#define GBA_DMA0DAD_H           0x000000B6   /**< DMA0 Destination Address High Value */
-#define GBA_DMA0CNT             0x000000B8   /**< DMA0 Control Word Count          */
-#define GBA_DMA0CNT_L           0x000000B8   /**< DMA0 Control Low Value           */
-#define GBA_DMA0CNT_H           0x000000BA   /**< DMA0 Control High Value          */
-#define GBA_DMA1SAD             0x000000BC   /**< DMA1 Source Address              */
-#define GBA_DMA1SAD_L           0x000000BC   /**< DMA1 Source Address Low Value    */
-#define GBA_DMA1SAD_H           0x000000BE   /**< DMA1 Source Address High Value   */
-#define GBA_DMA1DAD             0x000000C0   /**< DMA1 Destination Address         */
-#define GBA_DMA1DAD_L           0x000000C0   /**< DMA1 Destination Address Low Value  */
-#define GBA_DMA1DAD_H           0x000000C2   /**< DMA1 Destination Address High Value */
-#define GBA_DMA1CNT             0x000000C4   /**< DMA1 Control Word Count          */
-#define GBA_DMA1CNT_L           0x000000C4   /**< DMA1 Control Low Value           */
-#define GBA_DMA1CNT_H           0x000000C6   /**< DMA1 Control High Value          */
-#define GBA_DMA2SAD             0x000000C8   /**< DMA2 Source Address              */
-#define GBA_DMA2SAD_L           0x000000C8   /**< DMA2 Source Address Low Value    */
-#define GBA_DMA2SAD_H           0x000000CA   /**< DMA2 Source Address High Value   */
-#define GBA_DMA2DAD             0x000000CC   /**< DMA2 Destination Address         */
-#define GBA_DMA2DAD_L           0x000000CC   /**< DMA2 Destination Address Low Value  */
-#define GBA_DMA2DAD_H           0x000000CE   /**< DMA2 Destination Address High Value */
-#define GBA_DMA2CNT             0x000000D0   /**< DMA2 Control Word Count          */
-#define GBA_DMA2CNT_L           0x000000D0   /**< DMA2 Control Low Value           */
-#define GBA_DMA2CNT_H           0x000000D2   /**< DMA2 Control High Value          */
-#define GBA_DMA3SAD             0x000000D4   /**< DMA3 Source Address              */
-#define GBA_DMA3SAD_L           0x000000D4   /**< DMA3 Source Address Low Value    */
-#define GBA_DMA3SAD_H           0x000000D6   /**< DMA3 Source Address High Value   */
-#define GBA_DMA3DAD             0x000000D8   /**< DMA3 Destination Address         */
-#define GBA_DMA3DAD_L           0x000000D8   /**< DMA3 Destination Address Low Value  */
-#define GBA_DMA3DAD_H           0x000000DA   /**< DMA3 Destination Address High Value */
-#define GBA_DMA3CNT             0x000000DC   /**< DMA3 Control Word Count          */
-#define GBA_DMA3CNT_L           0x000000DC   /**< DMA3 Control Low Value           */
-#define GBA_DMA3CNT_H           0x000000DE   /**< DMA3 Control High Value          */
-/* DMA Transfer Channel address  */
-#define GBA_REG_DMA0SAD_ADDR    GBA_IO_REGS_ADDR + GBA_DMA0SAD
-#define GBA_REG_DMA0SAD_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA0SAD_L
-#define GBA_REG_DMA0SAD_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA0SAD_H
-#define GBA_REG_DMA0DAD_ADDR    GBA_IO_REGS_ADDR + GBA_DMA0DAD
-#define GBA_REG_DMA0DAD_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA0DAD_L
-#define GBA_REG_DMA0DAD_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA0DAD_H
-#define GBA_REG_DMA0CNT_ADDR    GBA_IO_REGS_ADDR + GBA_DMA0CNT
-#define GBA_REG_DMA0CNT_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA0CNT_L
-#define GBA_REG_DMA0CNT_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA0CNT_H
-#define GBA_REG_DMA1SAD_ADDR    GBA_IO_REGS_ADDR + GBA_DMA1SAD
-#define GBA_REG_DMA1SAD_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA1SAD_L
-#define GBA_REG_DMA1SAD_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA1SAD_H
-#define GBA_REG_DMA1DAD_ADDR    GBA_IO_REGS_ADDR + GBA_DMA1DAD)
-#define GBA_REG_DMA1DAD_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA1DAD_L
-#define GBA_REG_DMA1DAD_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA1DAD_H
-#define GBA_REG_DMA1CNT_ADDR    GBA_IO_REGS_ADDR + GBA_DMA1CNT
-#define GBA_REG_DMA1CNT_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA1CNT_L
-#define GBA_REG_DMA1CNT_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA1CNT_H
-#define GBA_REG_DMA2SAD_ADDR    GBA_IO_REGS_ADDR + GBA_DMA2SAD
-#define GBA_REG_DMA2SAD_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA2SAD_L
-#define GBA_REG_DMA2SAD_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA2SAD_H
-#define GBA_REG_DMA2DAD_ADDR    GBA_IO_REGS_ADDR + GBA_DMA2DAD
-#define GBA_REG_DMA2DAD_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA2DAD_L
-#define GBA_REG_DMA2DAD_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA2DAD_H
-#define GBA_REG_DMA2CNT_ADDR    GBA_IO_REGS_ADDR + GBA_DMA2CNT
-#define GBA_REG_DMA2CNT_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA2CNT_L
-#define GBA_REG_DMA2CNT_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA2CNT_H
-#define GBA_REG_DMA3SAD_ADDR    GBA_IO_REGS_ADDR + GBA_DMA3SAD
-#define GBA_REG_DMA3SAD_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA3SAD_L
-#define GBA_REG_DMA3SAD_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA3SAD_H
-#define GBA_REG_DMA3DAD_ADDR    GBA_IO_REGS_ADDR + GBA_DMA3DAD
-#define GBA_REG_DMA3DAD_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA3DAD_L
-#define GBA_REG_DMA3DAD_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA3DAD_H
-#define GBA_REG_DMA3CNT_ADDR    GBA_IO_REGS_ADDR + GBA_DMA3CNT
-#define GBA_REG_DMA3CNT_L_ADDR  GBA_IO_REGS_ADDR + GBA_DMA3CNT_L
-#define GBA_REG_DMA3CNT_H_ADDR  GBA_IO_REGS_ADDR + GBA_DMA3CNT_H
-/* DMA Transfer Channel registers*/
-#ifndef __asm__
-#define GBA_REG_DMA0SAD         (*(volatile unsigned int   *)(GBA_REG_DMA0SAD_ADDR))
-#define GBA_REG_DMA0SAD_L       (*(volatile unsigned short *)(GBA_REG_DMA0SAD_L_ADDR))
-#define GBA_REG_DMA0SAD_H       (*(volatile unsigned short *)(GBA_REG_DMA0SAD_H_ADDR))
-#define GBA_REG_DMA0DAD         (*(volatile unsigned int   *)(GBA_REG_DMA0DAD_ADDR))
-#define GBA_REG_DMA0DAD_L       (*(volatile unsigned short *)(GBA_REG_DMA0DAD_L_ADDR))
-#define GBA_REG_DMA0DAD_H       (*(volatile unsigned short *)(GBA_REG_DMA0DAD_H_ADDR))
-#define GBA_REG_DMA0CNT         (*(volatile unsigned int   *)(GBA_REG_DMA0CNT_ADDR))
-#define GBA_REG_DMA0CNT_L       (*(volatile unsigned short *)(GBA_REG_DMA0CNT_L_ADDR))
-#define GBA_REG_DMA0CNT_H       (*(volatile unsigned short *)(GBA_REG_DMA0CNT_H_ADDR))
-#define GBA_REG_DMA1SAD         (*(volatile unsigned int   *)(GBA_REG_DMA1SAD_ADDR))
-#define GBA_REG_DMA1SAD_L       (*(volatile unsigned short *)(GBA_REG_DMA1SAD_L_ADDR))
-#define GBA_REG_DMA1SAD_H       (*(volatile unsigned short *)(GBA_REG_DMA1SAD_H_ADDR))
-#define GBA_REG_DMA1DAD         (*(volatile unsigned int   *)(GBA_REG_DMA1DAD_ADDR))
-#define GBA_REG_DMA1DAD_L       (*(volatile unsigned short *)(GBA_REG_DMA1DAD_L_ADDR))
-#define GBA_REG_DMA1DAD_H       (*(volatile unsigned short *)(GBA_REG_DMA1DAD_H_ADDR))
-#define GBA_REG_DMA1CNT         (*(volatile unsigned int   *)(GBA_REG_DMA1CNT_ADDR))
-#define GBA_REG_DMA1CNT_L       (*(volatile unsigned short *)(GBA_REG_DMA1CNT_L_ADDR))
-#define GBA_REG_DMA1CNT_H       (*(volatile unsigned short *)(GBA_REG_DMA1CNT_H_ADDR))
-#define GBA_REG_DMA2SAD         (*(volatile unsigned int   *)(GBA_REG_DMA2SAD_ADDR))
-#define GBA_REG_DMA2SAD_L       (*(volatile unsigned short *)(GBA_REG_DMA2SAD_L_ADDR))
-#define GBA_REG_DMA2SAD_H       (*(volatile unsigned short *)(GBA_REG_DMA2SAD_H_ADDR))
-#define GBA_REG_DMA2DAD         (*(volatile unsigned int   *)(GBA_REG_DMA2DAD_ADDR))
-#define GBA_REG_DMA2DAD_L       (*(volatile unsigned short *)(GBA_REG_DMA2DAD_L_ADDR))
-#define GBA_REG_DMA2DAD_H       (*(volatile unsigned short *)(GBA_REG_DMA2DAD_H_ADDR))
-#define GBA_REG_DMA2CNT         (*(volatile unsigned int   *)(GBA_REG_DMA2CNT_ADDR))
-#define GBA_REG_DMA2CNT_L       (*(volatile unsigned short *)(GBA_REG_DMA2CNT_L_ADDR))
-#define GBA_REG_DMA2CNT_H       (*(volatile unsigned short *)(GBA_REG_DMA2CNT_H_ADDR))
-#define GBA_REG_DMA3SAD         (*(volatile unsigned int   *)(GBA_REG_DMA3SAD_ADDR))
-#define GBA_REG_DMA3SAD_L       (*(volatile unsigned short *)(GBA_REG_DMA3SAD_L_ADDR))
-#define GBA_REG_DMA3SAD_H       (*(volatile unsigned short *)(GBA_REG_DMA3SAD_H_ADDR))
-#define GBA_REG_DMA3DAD         (*(volatile unsigned int   *)(GBA_REG_DMA3DAD_ADDR))
-#define GBA_REG_DMA3DAD_L       (*(volatile unsigned short *)(GBA_REG_DMA3DAD_L_ADDR))
-#define GBA_REG_DMA3DAD_H       (*(volatile unsigned short *)(GBA_REG_DMA3DAD_H_ADDR))
-#define GBA_REG_DMA3CNT         (*(volatile unsigned int *)(GBA_REG_DMA3CNT_ADDR))
-#define GBA_REG_DMA3CNT_L       (*(volatile unsigned short *)(GBA_REG_DMA3CNT_L_ADDR))
-#define GBA_REG_DMA3CNT_H       (*(volatile unsigned short *)(GBA_REG_DMA3CNT_H_ADDR))
-#endif
-
-/*---------------------------------------------------------------------------+
-|    TIMER
-+----------------------------------------------------------------------------*/
-#define GBA_TMR_PRESCALER_1CK     0x0000    /**< Prescaler 1 clock           */
-#define GBA_TMR_PRESCALER_64CK    0x0001    /**<          64 clocks          */
-#define GBA_TMR_PRESCALER_256CK   0x0002    /**<         256 clocks          */
-#define GBA_TMR_PRESCALER_1024CK  0x0003    /**<        1024 clocks          */
-#define GBA_TMR_IF_ENABLE         0x0040    /**< Interrupt Request Enable    */
-#define GBA_TMR_ENABLE            0x0080    /**< Run Timer                   */
-
-/* Timer Register address offsets */
-#define GBA_TM0D                0x00000100  /**< Timer 0 counter value      X*/
-#define GBA_TM0CNT_L            0x00000100  /**< Timer 0 counter value       */
-#define GBA_TM0CNT              0x00000102  /**< Timer 0 Control            X*/
-#define GBA_TM0CNT_H            0x00000102  /**< Timer 0 Control             */
-#define GBA_TM1D                0x00000104  /**< Timer 1 counter value      X*/
-#define GBA_TM1CNT_L            0x00000104  /**< Timer 1 counter value       */
-#define GBA_TM1CNT              0x00000106  /**< Timer 1 control            X*/
-#define GBA_TM1CNT_H            0x00000106  /**< Timer 1 control             */
-#define GBA_TM2D                0x00000108  /**< Timer 2 counter value      X*/
-#define GBA_TM2CNT_L            0x00000108  /**< Timer 2 counter value       */
-#define GBA_TM2CNT              0x0000010A  /**< Timer 2 control            X*/
-#define GBA_TM2CNT_H            0x0000010A  /**< Timer 2 control             */
-#define GBA_TM3D                0x0000010C  /**< Timer 3 counter value      X*/
-#define GBA_TM3CNT_L            0x0000010C  /**< Timer 3 counter value       */
-#define GBA_TM3CNT              0x0000010E  /**< Timer 4 control            X*/
-#define GBA_TM3CNT_H            0x0000010E  /**< Timer 4 control             */
-/* Timer Register addresses */
-#define GBA_REG_TM0D_ADDR       GBA_IO_REGS_ADDR + GBA_TM0D
-#define GBA_REG_TM0CNT_L_ADDR   GBA_IO_REGS_ADDR + GBA_TM0CNT_L
-#define GBA_REG_TM0CNT_ADDR     GBA_IO_REGS_ADDR + GBA_TM0CNT
-#define GBA_REG_TM0CNT_H_ADDR   GBA_IO_REGS_ADDR + GBA_TM0CNT_H
-#define GBA_REG_TM1D_ADDR       GBA_IO_REGS_ADDR + GBA_TM1D
-#define GBA_REG_TM1CNT_L_ADDR   GBA_IO_REGS_ADDR + GBA_TM1CNT_L
-#define GBA_REG_TM1CNT_ADDR     GBA_IO_REGS_ADDR + GBA_TM1CNT
-#define GBA_REG_TM1CNT_H_ADDR   GBA_IO_REGS_ADDR + GBA_TM1CNT_H
-#define GBA_REG_TM2D_ADDR       GBA_IO_REGS_ADDR + GBA_TM2D
-#define GBA_REG_TM2CNT_L_ADDR   GBA_IO_REGS_ADDR + GBA_TM2CNT_L
-#define GBA_REG_TM2CNT_ADDR     GBA_IO_REGS_ADDR + GBA_TM2CNT
-#define GBA_REG_TM2CNT_H_ADDR   GBA_IO_REGS_ADDR + GBA_TM2CNT_H
-#define GBA_REG_TM3D_ADDR       GBA_IO_REGS_ADDR + GBA_TM3D
-#define GBA_REG_TM3CNT_L_ADDR   GBA_IO_REGS_ADDR + GBA_TM3CNT_L
-#define GBA_REG_TM3CNT_ADDR     GBA_IO_REGS_ADDR + GBA_TM3CNT
-#define GBA_REG_TM3CNT_H_ADDR   GBA_IO_REGS_ADDR + GBA_TM3CNT_H
-/* Timer Registers */
-#ifndef __asm__
-#define GBA_REG_TM0D            (*(volatile unsigned short *)(GBA_REG_TM0D_ADDR))
-#define GBA_REG_TM0CNT_L        (*(volatile unsigned short *)(GBA_REG_TM0CNT_L_ADDR))
-#define GBA_REG_TM0CNT          (*(volatile unsigned short *)(GBA_REG_TM0CNT_ADDR))
-#define GBA_REG_TM0CNT_H        (*(volatile unsigned short *)(GBA_REG_TM0CNT_H_ADDR))
-#define GBA_REG_TM1D            (*(volatile unsigned short *)(GBA_REG_TM1D_ADDR))
-#define GBA_REG_TM1CNT_L        (*(volatile unsigned short *)(GBA_REG_TM1CNT_L_ADDR))
-#define GBA_REG_TM1CNT          (*(volatile unsigned short *)(GBA_REG_TM1CNT_ADDR))
-#define GBA_REG_TM1CNT_H        (*(volatile unsigned short *)(GBA_REG_TM1CNT_H_ADDR))
-#define GBA_REG_TM2D            (*(volatile unsigned short *)(GBA_REG_TM2D_ADDR))
-#define GBA_REG_TM2CMT_L        (*(volatile unsigned short *)(GBA_REG_TM2CNT_L_ADDR))
-#define GBA_REG_TM2CNT          (*(volatile unsigned short *)(GBA_REG_TM2CNT_ADDR))
-#define GBA_REG_TM2CNT_H        (*(volatile unsigned short *)(GBA_REG_TM2CNT_H_ADDR))
-#define GBA_REG_TM3D            (*(volatile unsigned short *)(GBA_REG_TM3D_ADDR))
-#define GBA_REG_TM3CNT_L        (*(volatile unsigned short *)(GBA_REG_TM3CNT_L_ADDR))
-#define GBA_REG_TM3CNT          (*(volatile unsigned short *)(GBA_REG_TM3CNT_ADDR))
-#define GBA_REG_TM3CNT_H        (*(volatile unsigned short *)(GBA_REG_TM3CNT_H_ADDR))
-#endif
-
-/*---------------------------------------------------------------------------+
-|    SERIAL set1
-+----------------------------------------------------------------------------*/
-#define GBA_SER_BAUD_MASK       0x0003
-#define GBA_SER_BAUD_9600       0x0000
-#define GBA_SER_BAUD_38400      0x0001
-#define GBA_SER_BAUD_57600      0x0002
-#define GBA_SER_BAUD_115200     0x0003
-#define GBA_SER_CTS             0x0004
-
-/* Serial Communication address offsets */
-#define GBA_SIOMULTI0           0x00000120 /**< SIO Multi-Player Data 0      */
-#define GBA_SCD0                0x00000120 /**< SIO Multi-Player Data 0     X*/
-#define GBA_SIOMULTI1           0x00000122 /**< SIO Multi-Player Data 1      */
-#define GBA_SCD1                0x00000122 /**< SIO Multi-Player Data 1     X*/
-#define GBA_SIOMULTI2           0x00000124 /**< SIO Multi-Player Data 2      */
-#define GBA_SCD2                0x00000124 /**< SIO Multi-Player Data 2     X*/
-#define GBA_SIOMULTI3           0x00000126 /**< SIO Multi-Player Data 3      */
-#define GBA_SCD3                0x00000126 /**< SIO Multi-Player Data 3     X*/
-#define GBA_SIOCNT              0x00000128 /**< SIO Control                  */
-#define GBA_SCCNT               0x00000128 /**< SIO Control                 X*/
-#define GBA_SCCNT_L             0x00000128 /**< SIO Control                 X*/
-#define GBA_SIOMLT_SEND         0x0000012A /**< Data Send Register           */
-#define GBA_SCCNT_H             0x0000012A /**< Data Send Register          X*/
-/* Serial Communication addresses */
-#define GBA_REG_SIOMULTI0_ADDR   GBA_IO_REGS_ADDR + GBA_SIOMULTI0
-#define GBA_REG_SCD0_ADDR        GBA_IO_REGS_ADDR + GBA_SCD0
-#define GBA_REG_SIOMULTI1_ADDR   GBA_IO_REGS_ADDR + GBA_SIOMULTI1
-#define GBA_REG_SCD1_ADDR        GBA_IO_REGS_ADDR + GBA_SCD1
-#define GBA_REG_SIOMULTI2_ADDR   GBA_IO_REGS_ADDR + GBA_SIOMULTI2
-#define GBA_REG_SCD2_ADDR        GBA_IO_REGS_ADDR + GBA_SCD2
-#define GBA_REG_SIOMULTI3_ADDR   GBA_IO_REGS_ADDR + GBA_SIOMULTI3
-#define GBA_REG_SCD3_ADDR        GBA_IO_REGS_ADDR + GBA_SCD3
-#define GBA_REG_SCCNT_ADDR       GBA_IO_REGS_ADDR + GBA_SCCNT
-#define GBA_REG_SIOCNT_ADDR      GBA_IO_REGS_ADDR + GBA_SIOCNT
-#define GBA_REG_SCCNT_L_ADDR     GBA_IO_REGS_ADDR + GBA_SCCNT_L
-#define GBA_REG_SIOMLT_SEND_ADDR GBA_IO_REGS_ADDR + GBA_SIOMLT_SEND
-#define GBA_REG_SCCNT_H_ADDR     GBA_IO_REGS_ADDR + GBA_SCCNT_H
-/* Serial Communication registers */
-#ifndef __asm__
-#define GBA_REG_SIOMULTI0       (*(volatile unsigned short *)(GBA_REG_SIOMULTI0_ADDR))
-#define GBA_REG_SCD0            (*(volatile unsigned short *)(GBA_REG_SCD0_ADDR))
-#define GBA_REG_SIOMULTI1       (*(volatile unsigned short *)(GBA_REG_SIOMULTI1_ADDR))
-#define GBA_REG_SCD1            (*(volatile unsigned short *)(GBA_REG_SCD1_ADDR))
-#define GBA_REG_SIOMULTI2       (*(volatile unsigned short *)(GBA_REG_SIOMULTI2_ADDR))
-#define GBA_REG_SCD2            (*(volatile unsigned short *)(GBA_REG_SCD2_ADDR))
-#define GBA_REG_SIOMULTI3       (*(volatile unsigned short *)(GBA_REG_SIOMULTI3_ADDR))
-#define GBA_REG_SCD3            (*(volatile unsigned short *)(GBA_REG_SCD3_ADDR))
-#define GBA_REG_SCCNT           (*(volatile unsigned int   *)(GBA_REG_SCCNT_ADDR))
-#define GBA_REG_SIOCNT          (*(volatile unsigned short *)(GBA_REG_SIOCNT_ADDR))
-#define GBA_REG_SCCNT_L         (*(volatile unsigned short *)(GBA_REG_SCCNT_L_ADDR))
-#define GBA_REG_SIOMLT_SEND     (*(volatile unsigned short *)(GBA_REG_SIOMLT_SEND_ADDR))
-#define GBA_REG_SCCNT_H         (*(volatile unsigned short *)(GBA_REG_SCCNT_H_ADDR))
-#endif
-
-/*---------------------------------------------------------------------------+
-|    KEYPAD
-+----------------------------------------------------------------------------*/
-/* GBA Keys */
-#define GBA_KEY_A               0x0001
-#define GBA_KEY_B               0x0002
-#define GBA_KEY_SELECT          0x0004
-#define GBA_KEY_START           0x0008
-#define GBA_KEY_RIGHT           0x0010
-#define GBA_KEY_LEFT            0x0020
-#define GBA_KEY_UP              0x0040
-#define GBA_KEY_DOWN            0x0080
-#define GBA_KEY_R               0x0100
-#define GBA_KEY_L               0x0200
-#define GBA_KEY_ALL             0x03FF
-/* Keypad registers address offsets */
-#define GBA_P1                  0x00000130 /**< Key Status                  X*/
-#define GBA_KEYINPUT            0x00000130 /**< Key Status                   */
-#define GBA_P1CNT               0x00000132 /**< Key Interrupt Control       X*/
-#define GBA_KEYCNT              0x00000132 /**< Key Interrupt Control        */
-/* Keypad registers addresses */
-#define GBA_REG_P1_ADDR         GBA_IO_REGS_ADDR + GBA_P1
-#define GBA_REG_KEYINPUT_ADDR   GBA_IO_REGS_ADDR + GBA_KEYINPUT
-#define GBA_REG_P1CNT_ADDR      GBA_IO_REGS_ADDR + GBA_P1CNT
-#define GBA_REG_KEYCNT_ADDR     GBA_IO_REGS_ADDR + GBA_KEYCNT
-/* Keypad registers */
-#ifndef __asm__
-#define GBA_REG_P1              (*(volatile unsigned short *)(GBA_REG_P1_ADDR))
-#define GBA_REG_KEYINPUT        (*(volatile unsigned short *)(GBA_REG_KEYINPUT_ADDR))
-#define GBA_REG_P1CNT           (*(volatile unsigned short *)(GBA_REG_P1CNT_ADDR))
-#define GBA_REG_KEYCNT          (*(volatile unsigned short *)(GBA_REG_KEYCNT_ADDR))
-#endif
-
-/*---------------------------------------------------------------------------+
-|    SERIAL set2
-+----------------------------------------------------------------------------*/
-/* Serial Communication address offsets */
-#define GBA_R                    0x00000134 /**< Mode Selection             X*/
-#define GBA_RCNT                 0x00000134 /**< Mode Selection              */
-#define GBA_HS_CTRL              0x00000140 /**< JOY BUS Control Register   X*/
-#define GBA_JOYCNT               0x00000140 /**< JOY BUS Control Register    */
-#define GBA_JOYRE                0x00000150 /**< Receive Data Register      X*/
-#define GBA_JOYRE_L              0x00000150 /**< Receive Data Register low  X*/
-#define GBA_JOY_RECV_L           0x00000150 /**< Receive Data Register low   */
-#define GBA_JOYRE_H              0x00000152 /**< Receive Data Register high X*/
-#define GBA_JOY_RECV_H           0x00000152 /**< Receive Data Register high  */
-#define GBA_JOYTR                0x00000154 /**< Send Data Register         X*/
-#define GBA_JOYTR_L              0x00000154 /**< Send Data Register low     X*/
-#define GBA_JOY_TRANS_L          0x00000154 /**< Send Data Register low      */
-#define GBA_JOYTR_H              0x00000156 /**< Send Data Register high    X*/
-#define GBA_JOY_TRANS_H          0x00000156 /**< Send Data Register high     */
-#define GBA_JSTAT                0x00000158 /**< Receive Status Register    X*/
-#define GBA_JOYSTAT              0x00000158 /**< Receive Status Register     */
-/* Serial Communication register addresses */
-#define GBA_REG_R_ADDR           GBA_IO_REGS_ADDR + GBA_R
-#define GBA_REG_RCNT_ADDR        GBA_IO_REGS_ADDR + GBA_RCNT
-#define GBA_REG_HS_CTRL_ADDR     GBA_IO_REGS_ADDR + GBA_HS_CTRL
-#define GBA_REG_JOYCNT_ADDR      GBA_IO_REGS_ADDR + GBA_JOYCNT
-#define GBA_REG_JOYRE_ADDR       GBA_IO_REGS_ADDR + GBA_JOYRE
-#define GBA_REG_JOYRE_L_ADDR     GBA_IO_REGS_ADDR + GBA_JOYRE_L
-#define GBA_REG_JOY_RECV_L_ADDR  GBA_IO_REGS_ADDR + GBA_JOY_RECV_L
-#define GBA_REG_JOYRE_H_ADDR     GBA_IO_REGS_ADDR + GBA_JOYRE_H
-#define GBA_REG_JOY_RECV_H_ADDR  GBA_IO_REGS_ADDR + GBA_JOY_RECV_H
-#define GBA_REG_JOYTR_ADDR       GBA_IO_REGS_ADDR + GBA_JOYTR
-#define GBA_REG_JOYTR_L_ADDR     GBA_IO_REGS_ADDR + GBA_JOYTR_L
-#define GBA_REG_JOY_TRANS_L_ADDR GBA_IO_REGS_ADDR + GBA_JOY_TRANS_L
-#define GBA_REG_JOYTR_H_ADDR     GBA_IO_REGS_ADDR + GBA_JOYTR_H
-#define GBA_REG_JOY_TRANS_H_ADDR GBA_IO_REGS_ADDR + GBA_JOY_TRANS_H
-#define GBA_REG_JSTAT_ADDR       GBA_IO_REGS_ADDR + GBA_JSTAT
-#define GBA_REG_JOYSTAT_ADDR     GBA_IO_REGS_ADDR + GBA_JOYSTAT
-/* Serial Communication registers */
-#ifndef __asm__
-#define GBA_REG_R               (*(volatile unsigned short *)(GBA_REG_R_ADDR))
-#define GBA_REG_RCNT            (*(volatile unsigned short *)(GBA_REG_RCNT_ADDR))
-#define GBA_REG_HS_CTRL         (*(volatile unsigned short *)(GBA_REG_HS_CTRL_ADDR))
-#define GBA_REG_JOYCNT          (*(volatile unsigned short *)(GBA_REG_JOYCNT_ADDR))
-#define GBA_REG_JOYRE           (*(volatile unsigned int   *)(GBA_REG_JOYRE_ADDR))
-#define GBA_REG_JOYRE_L         (*(volatile unsigned short *)(GBA_REG_JOYRE_L_ADDR))
-#define GBA_REG_JOY_RECV_L      (*(volatile unsigned short *)(GBA_REG_JOY_RECV_L_ADDR))
-#define GBA_REG_JOYRE_H         (*(volatile unsigned short *)(GBA_REG_JOYRE_H_ADDR))
-#define GBA_REG_JOY_RECV_H      (*(volatile unsigned short *)(GBA_REG_JOY_RECV_H_ADDR))
-#define GBA_REG_JOYTR           (*(volatile unsigned int   *)(GBA_REG_JOYTR_ADDR))
-#define GBA_REG_JOYTR_L         (*(volatile unsigned short *)(GBA_REG_JOYTR_L_ADDR))
-#define GBA_REG_JOY_TRANS_L     (*(volatile unsigned short *)(GBA_REG_JOY_TRANS_L_ADDR))
-#define GBA_REG_JOYTR_H         (*(volatile unsigned short *)(GBA_REG_JOYTR_H_ADDR))
-#define GBA_REG_JOY_TRANS_H     (*(volatile unsigned short *)(GBA_REG_JOY_TRANS_H_ADDR))
-#define GBA_REG_JSTAT           (*(volatile unsigned int   *)(GBA_REG_JSTAT_ADDR))
-#define GBA_REG_JOYSTAT         (*(volatile unsigned short *)(GBA_REG_JOYSTAT_ADDR))
-#endif
-
-/*---------------------------------------------------------------------------+
-|    INTERRUPT
-+----------------------------------------------------------------------------*/
-/* Interrupt sources */
-#define GBA_INT_VBLANK          0x0001
-#define GBA_INT_HBLANK          0x0002
-#define GBA_INT_VCOUNT          0x0004
-#define GBA_INT_TIMER0          0x0008
-#define GBA_INT_TIMER1          0x0010
-#define GBA_INT_TIMER2          0x0020
-#define GBA_INT_TIMER3          0x0040
-#define GBA_INT_SERIAL          0x0080
-#define GBA_INT_DMA0            0x0100
-#define GBA_INT_DMA1            0x0200
-#define GBA_INT_DMA2            0x0400
-#define GBA_INT_DMA3            0x0800
-#define GBA_INT_KEY             0x1000
-#define GBA_INT_CART            0x2000
-/* Interrupt address offsets */
-#define GBA_IE                  0x00000200 /**< Interrupt Enable        */
-#define GBA_IF                  0x00000202 /**< Interrupt Flags         */
-#define GBA_IME                 0x00000208 /**< Interrupt Master Enable */
-/* Interrupt addresses */
-#define GBA_REG_IE_ADDR         GBA_IO_REGS_ADDR + GBA_IE
-#define GBA_REG_IF_ADDR         GBA_IO_REGS_ADDR + GBA_IF
-#define GBA_REG_IME_ADDR        GBA_IO_REGS_ADDR + GBA_IME
-/* Interrupt registers */
-#ifndef __asm__
-#define GBA_REG_IE              (*(volatile unsigned short *)(GBA_REG_IE_ADDR))
-#define GBA_REG_IF              (*(volatile unsigned short *)(GBA_REG_IF_ADDR))
-#define GBA_REG_IME             (*(volatile unsigned short *)(GBA_REG_IME_ADDR))
-#endif
-
-/*---------------------------------------------------------------------------+
-|    Waitstate and Power-Down Control registers
-+----------------------------------------------------------------------------*/
-#define GBA_PHI_MASK            0x1800
-#define GBA_PHI_NONE            0x0000
-#define GBA_PHI_4_19MHZ         0x0800
-#define GBA_PHI_8_38MHZ         0x1000
-#define GBA_PHI_16_76MHZ        0x1800
-/* Waitstate and Power-Down Control address offsets */
-#define GBA_WSCNT               0x00000204 /**< Waitstate Control           X*/
-#define GBA_WAITCNT             0x00000204 /**< Waitstate Control            */
-#define GBA_PAUSE               0x00000300 /**< Power Down Control          X*/
-#define GBA_HALTCNT             0x00000300 /**< Power Down Control           */
-/* Waitstate and Power-Down Control addresses */
-#define GBA_REG_WSCNT_ADDR      GBA_IO_REGS_ADDR + GBA_WSCNT
-#define GBA_REG_WAITCNT_ADDR    GBA_IO_REGS_ADDR + GBA_WAITCNT
-#define GBA_REG_PAUSE_ADDR      GBA_IO_REGS_ADDR + GBA_PAUSE
-#define GBA_REG_HALTCNT_ADDR    GBA_IO_REGS_ADDR + GBA_HALTCNT
-/* Waitstate and Power-Down Control registers */
-#ifndef __asm__
-#define GBA_REG_WSCNT           (*(volatile unsigned short *)(GBA_REG_WSCNT_ADDR))
-#define GBA_REG_WAITCNT         (*(volatile unsigned short *)(GBA_REG_WAITCNT_ADDR))
-#define GBA_REG_PAUSE           (*(volatile unsigned short *)(GBA_REG_PAUSE_ADDR))
-#define GBA_REG_HALTCNT         (*(volatile unsigned short *)(GBA_REG_HALTCNT_ADDR))
-#endif
-
-
-/*
- * @TODO remove UART register defines
- * define for RTEMS UART registers to be able to compile
- */
-#define RSRBR   0
-#define RSTHR   1
-#define RSIER   2
-#define RSIIR   3
-#define RSFCR   4
-#define RSLCR   5
-#define RSLSR   6
-#define RSDLL   7
-#define RSDLH   8
-#define RSCNT   9
-
-
-#endif /* _GBA_REGISTERS_H */
Index: src/lib/libbsp/arm/gba/irq/irq.c
===================================================================
--- c/src/lib/libbsp/arm/gba/irq/irq.c	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,71 +1,0 @@
-/**
- *  @file irq.c
- *
- *  This file contains the implementation of the function described in irq.h.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2010 embedded brains GmbH.
- *
- *  Copyright (c) 2002 by Jay Monkman <jtm@smoothsmoothie.com>
- *
- *  Copyright (c) 2002 by Charlie Steader <charlies@poliac.com>
- *
- *  Copyright (c) 2004 by Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#include <bsp.h>
-#include <bsp/irq.h>
-#include <bsp/irq-generic.h>
-
-#include <gba_registers.h>
-
-/*
- * Prototypes
- */
-void bsp_interrupt_dispatch(void);
-
-void bsp_interrupt_dispatch(void)
-{
-  unsigned reg_ie = GBA_REG_IE;
-  unsigned reg_if = GBA_REG_IF & reg_ie;
-  rtems_vector_number vector = 31 - __builtin_clz(reg_if);
-
-  bsp_interrupt_handler_dispatch(vector);
-
-  GBA_REG_IF = 1 << vector;
-}
-
-rtems_status_code bsp_interrupt_vector_enable(rtems_vector_number vector)
-{
-  GBA_REG_IE |= 1 << vector;
-
-  return RTEMS_SUCCESSFUL;
-}
-
-rtems_status_code bsp_interrupt_vector_disable(rtems_vector_number vector)
-{
-  GBA_REG_IE &= ~(1 << vector);
-
-  return RTEMS_SUCCESSFUL;
-}
-
-rtems_status_code bsp_interrupt_facility_initialize(void)
-{
-  /* clear all interrupt status flags */
-  GBA_REG_IF = 0xffff;
-  /* disable all interrupts */
-  GBA_REG_IE = 0;
-  /* set master interrupt enable */
-  GBA_REG_IME = 1;
-
-  /* Exception handler is already present in the ROM BIOS */
-
-  return RTEMS_SUCCESSFUL;
-}
Index: src/lib/libbsp/arm/gba/irq/irq.h
===================================================================
--- c/src/lib/libbsp/arm/gba/irq/irq.h	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,74 +1,0 @@
-/**
- * @file
- *
- * @ingroup gba_interrupt
- *
- * @brief Interrupt definitions.
- */
-
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2010 embedded brains GmbH.
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#ifndef __asm__
-
-#include <rtems.h>
-#include <rtems/irq.h>
-#include <rtems/irq-extension.h>
-
-#endif /* __asm__ */
-
-#ifndef _IRQ_H_
-#define _IRQ_H_
-
-/**
- * @defgroup gba_interrupt Interrupt Support
- * 
- * @ingroup arm_gba
- * 
- * @brief Interrupt support.
- */
-
-/*---------------------------------------------------------------------------*
- *  MACROS                                                                   *
- *---------------------------------------------------------------------------*/
-
-#define ENABLE_IRQ()   GBA_REG_IME = 1;
-#define DISABLE_IRQ()  GBA_REG_IME = 0;
-
-
-/*-------------------------------------------------------------------------+
-| Constants
-+--------------------------------------------------------------------------*/
-
-#define BSP_IRQ_VBLANK   0
-#define BSP_IRQ_HBLANK   1
-#define BSP_IRQ_VCOUNTER 2
-#define BSP_IRQ_TIMER0   3
-#define BSP_IRQ_TIMER1   4
-#define BSP_IRQ_TIMER2   5
-#define BSP_IRQ_TIMER3   6
-#define BSP_IRQ_SERIAL   7
-#define BSP_IRQ_DMA0     8
-#define BSP_IRQ_DMA1     9
-#define BSP_IRQ_DMA2     10
-#define BSP_IRQ_DMA3     11
-#define BSP_IRQ_KEY      12
-#define BSP_IRQ_CART     13
-#define BSP_IRQ_NA14     14
-#define BSP_IRQ_NA15     15
-#define BSP_MAX_INT      16
-
-#define BSP_INTERRUPT_VECTOR_MIN 0
-
-#define BSP_INTERRUPT_VECTOR_MAX (BSP_MAX_INT - 1)
-
-#endif /* _IRQ_H_ */
Index: src/lib/libbsp/arm/gba/make/custom/gba.cfg
===================================================================
--- c/src/lib/libbsp/arm/gba/make/custom/gba.cfg	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,24 +1,0 @@
-#
-#  Config file for Gameboy Advance ARM --
-#
-
-include $(RTEMS_ROOT)/make/custom/default.cfg
-
-RTEMS_CPU=arm
-RTEMS_CPU_MODEL=arm7tdmi
-
-#  This contains the compiler options necessary to select the CPU model
-#  and (hopefully) optimize for it.
-#
-CPU_CFLAGS = -mcpu=$(RTEMS_CPU_MODEL)
-
-# optimize flag: typically -O2
-CFLAGS_OPTIMIZE_V = -O2 -g
-
-# Some GBA simulators want a .gba extension.
-define bsp-post-link
-	$(OBJCOPY) -O binary --remove-section=.comment \
-	    --remove-section=.note --strip-unneeded \
-	    $(basename $@)$(EXEEXT) $(basename $@)$(DOWNEXT)
-	$(default-bsp-post-link)
-endef
Index: src/lib/libbsp/arm/gba/preinstall.am
===================================================================
--- c/src/lib/libbsp/arm/gba/preinstall.am	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,99 +1,0 @@
-## Automatically generated by ampolish3 - Do not edit
-
-if AMPOLISH3
-$(srcdir)/preinstall.am: Makefile.am
-	$(AMPOLISH3) $(srcdir)/Makefile.am > $(srcdir)/preinstall.am
-endif
-
-PREINSTALL_DIRS =
-DISTCLEANFILES += $(PREINSTALL_DIRS)
-
-all-am: $(PREINSTALL_FILES)
-
-PREINSTALL_FILES =
-CLEANFILES = $(PREINSTALL_FILES)
-
-all-local: $(TMPINSTALL_FILES)
-
-TMPINSTALL_FILES =
-CLEANFILES += $(TMPINSTALL_FILES)
-
-$(PROJECT_LIB)/$(dirstamp):
-	@$(MKDIR_P) $(PROJECT_LIB)
-	@: > $(PROJECT_LIB)/$(dirstamp)
-PREINSTALL_DIRS += $(PROJECT_LIB)/$(dirstamp)
-
-$(PROJECT_INCLUDE)/$(dirstamp):
-	@$(MKDIR_P) $(PROJECT_INCLUDE)
-	@: > $(PROJECT_INCLUDE)/$(dirstamp)
-PREINSTALL_DIRS += $(PROJECT_INCLUDE)/$(dirstamp)
-
-$(PROJECT_INCLUDE)/bsp/$(dirstamp):
-	@$(MKDIR_P) $(PROJECT_INCLUDE)/bsp
-	@: > $(PROJECT_INCLUDE)/bsp/$(dirstamp)
-PREINSTALL_DIRS += $(PROJECT_INCLUDE)/bsp/$(dirstamp)
-
-$(PROJECT_LIB)/bsp_specs: bsp_specs $(PROJECT_LIB)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_LIB)/bsp_specs
-PREINSTALL_FILES += $(PROJECT_LIB)/bsp_specs
-
-$(PROJECT_INCLUDE)/bsp.h: include/bsp.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bsp.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp.h
-
-$(PROJECT_INCLUDE)/arm_mode_bits.h: include/arm_mode_bits.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/arm_mode_bits.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/arm_mode_bits.h
-
-$(PROJECT_INCLUDE)/asm_macros.h: include/asm_macros.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/asm_macros.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/asm_macros.h
-
-$(PROJECT_INCLUDE)/gba_registers.h: include/gba_registers.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/gba_registers.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/gba_registers.h
-
-$(PROJECT_INCLUDE)/conio.h: include/conio.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/conio.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/conio.h
-
-$(PROJECT_INCLUDE)/tm27.h: ../../shared/include/tm27.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/tm27.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/tm27.h
-
-$(PROJECT_INCLUDE)/gba.h: include/gba.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/gba.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/gba.h
-
-$(PROJECT_INCLUDE)/bspopts.h: include/bspopts.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bspopts.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/bspopts.h
-
-$(PROJECT_INCLUDE)/coverhd.h: ../../shared/include/coverhd.h $(PROJECT_INCLUDE)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/coverhd.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/coverhd.h
-
-$(PROJECT_INCLUDE)/bsp/bootcard.h: ../../shared/include/bootcard.h $(PROJECT_INCLUDE)/bsp/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bsp/bootcard.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp/bootcard.h
-
-$(PROJECT_LIB)/start.$(OBJEXT): start.$(OBJEXT) $(PROJECT_LIB)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_LIB)/start.$(OBJEXT)
-TMPINSTALL_FILES += $(PROJECT_LIB)/start.$(OBJEXT)
-
-$(PROJECT_LIB)/linkcmds: startup/linkcmds $(PROJECT_LIB)/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_LIB)/linkcmds
-PREINSTALL_FILES += $(PROJECT_LIB)/linkcmds
-
-$(PROJECT_INCLUDE)/bsp/irq-generic.h: ../../shared/include/irq-generic.h $(PROJECT_INCLUDE)/bsp/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bsp/irq-generic.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp/irq-generic.h
-
-$(PROJECT_INCLUDE)/bsp/irq-info.h: ../../shared/include/irq-info.h $(PROJECT_INCLUDE)/bsp/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bsp/irq-info.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp/irq-info.h
-
-$(PROJECT_INCLUDE)/bsp/irq.h: irq/irq.h $(PROJECT_INCLUDE)/bsp/$(dirstamp)
-	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/bsp/irq.h
-PREINSTALL_FILES += $(PROJECT_INCLUDE)/bsp/irq.h
-
Index: src/lib/libbsp/arm/gba/start/logo.S
===================================================================
--- c/src/lib/libbsp/arm/gba/start/logo.S	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,25 +1,0 @@
-/**
- *  @file logo.S
- *
- *  Nintendo Logo Character Data [offset 0x04].
- */
-/*
- *  RTEMS GBA BSP
- *
- *  THIS CODE WAS NOT MADE IN ASSOCIATION WITH NINTENDO AND DOES NOT MAKE USE
- *  OF ANY INTELLECTUAL PROPERTY CLAIMED BY NINTENDO.
- *
- *  GAMEBOY ADVANCE IS A TRADEMARK OF NINTENDO.
- */
-/* @cond  INCLUDE_ASM */
-        .word   0x51AEFF24, 0x21A29A69, 0x0A82843D, 0xAD09E484
-        .word   0x988B2411, 0x217F81C0, 0x19BE52A3, 0x20CE0993
-        .word   0x4A4A4610, 0xEC3127F8, 0x33E8C758, 0xBFCEE382
-        .word   0x94DFF485, 0xC1094BCE, 0xC08A5694, 0xFCA77213
-        .word   0x734D849F, 0x619ACAA3, 0x27A39758, 0x769803FC
-        .word   0x61C71D23, 0x56AE0403, 0x008438BF, 0xFD0EA740
-        .word   0x03FE52FF, 0xF130956F, 0x85C0FB97, 0x2580D660
-        .word   0x03BE63A9, 0xE2384E01, 0xFF34A2F9, 0x44033EBB
-        .word   0xCB900078, 0x943A1188, 0x637CC065, 0xAF3CF087
-        .word   0x8BE425D6, 0x72AC0A38, 0x07F8D421
-/* @endcond */
Index: src/lib/libbsp/arm/gba/start/start.S
===================================================================
--- c/src/lib/libbsp/arm/gba/start/start.S	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,396 +1,0 @@
-/**
- *  @file start.S
- *
- *  RTEMS entry point.
- */
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) by Jeff Frohwein.
- *
- *  Copyright (c) 2003, Jason Wilkins.
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *  based on crt0.S v1.28 by Jeff Frohwein
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-/*****************************************************************************
- * This source file is based on work by Jeff Frohwein and Jason Wilkins
- *****************************************************************************
- *****************************************************************************
- * crt0.S v1.28 by Jeff Frohwein
- * :
- * This file is released into the public domain for commercial
- * or non-commercial usage with no restrictions placed upon it.
- *****************************************************************************
- * Copyright 2003, Jason Wilkins.  This source code is free for any use except
- * that this copyright notice and the following disclaimers remain intact when
- * the source is distributed.  Object code and binary distributions may be made
- * as if the code were in the public domain.
- *
- * THIS CODE WAS NOT MADE IN ASSOCIATION WITH NINTENDO AND DOES NOT MAKE USE
- * OF ANY INTELLECTUAL PROPERTY CLAIMED BY NINTENDO.
- *
- * GAMEBOY ADVANCE IS A TRADEMARK OF NINTENDO.
- *
- * THIS CODE HAS BEEN PROVIDED "AS-IS" WITHOUT A WARRANTY OF ANY KIND, EITHER
- * EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO IMPLIED WARRANTIES OF
- * MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE.  THE ENTIRE RISK AS TO THE
- * QUALITY OR PERFORMANCE OF THE CODE IS WITH YOU.
- *
- * IN NO EVENT, UNLESS AGREED TO IN WRITING, WILL ANY COPYRIGHT HOLDER, OR ANY
- * OTHER PARTY, BE HELD LIABLE FOR ANY DAMAGES RESULTING FROM THE USE OR
- * INABILITY TO USE THIS CODE.
- *****************************************************************************/
-
-#define __asm__
-#include <rtems/asm.h>
-#include <asm_macros.h>
-#include <arm_mode_bits.h>
-/* @cond  INCLUDE_ASM */
-
-#ifndef NINTENDO_LOGO
-#define NINTENDO_LOGO 1
-#endif
-
-#ifndef GBA_MULTIBOOT
-#define GBA_MULTIBOOT 1
-#endif
-
-#ifndef GAME_TITLE
-#define GAME_TITLE "RTEMS-RTOS  "
-#endif
-
-#ifdef GBA_MULTIBOOT
-  #ifndef GAME_CODE
-  #define GAME_CODE "MB  "
-  #endif
-  #ifndef COMPLEMENT_CHECK
-  #define COMPLEMENT_CHECK 0xE2
-  #endif
-#else
-  #ifndef GAME_CODE
-  #define GAME_CODE "GBA "
-  #endif
-  #ifndef COMPLEMENT_CHECK
-  #define COMPLEMENT_CHECK 0xC7
-  #endif
-#endif
-
-#ifndef MAKER_CODE
-#define MAKER_CODE "00"
-#endif
-
-/**
- *  RTEMS entry point
- *  function void _start(void)
- *
- */
-/*****************************************************************************\
-                           ROM Header
-\*****************************************************************************/
-
-.text
-.align
-.arm
-
-/*---------------------------------------------------------------------------+
-|  Nintendo Header:
-|   A special header is required or the GBA will refuse to run your code.
-|
-|  File offsets from 0x0200000 or 0x08000000.
-+----------------------------------------------------------------------------*/
-    PUBLIC_ARM_FUNCTION(_start)
-         b       SYM(_real_start)    /* 0x00 Entry Point                     */
-    SYM(_gba_rom_header):
-#if NINTENDO_LOGO                    /* 0x04 Nintendo Logo Character Data    */
-#include        "logo.S"
-#else
-        .fill   156, 1, 0            /* 0x04 Nintendo Logo Character Data    */
-#endif
-        .ascii  GAME_TITLE           /* 0xA0 Game Title                      */
-        .ascii  GAME_CODE            /* 0xAC Game Code                       */
-        .ascii  MAKER_CODE           /* 0xB0 Maker Code                      */
-        .byte   0x96                 /* 0xB2 Fixed Value                     */
-        .byte   0                    /* 0xB3 Main Unit Code                  */
-        .byte   0                    /* 0xB4 Device Type                     */
-        .byte   0, 0, 0, 0, 0, 0, 0  /* 0xB5 Reserved (7 Bytes)              */
-        .byte   0                    /* 0xBC Software Version No.            */
-        .byte   COMPLEMENT_CHECK     /* 0xBD Complement Check                */
-        .byte   0, 0                 /* 0xBE Reserved                        */
-    .Lheader_end:
-
-
-#if GBA_MULTIBOOT
-/*---------------------------------------------------------------------------+
-|  Multiboot Header:
-|  The following header is required if the code is meant for Multiboot.
-|
-|  If the code has been downloaded through the serial port, then the GBA BIOS
-|  will set offset 0xC0 depending on the boot method:
-|  1 = JoyBus, 3 = Multiboot
-|  It remains 0 for cartridges.
-|
-|  offset 0xC4 will be set to the GBA's assigned slave number 1-3.
-|  This header also defines the symbols _boot_method and _slave_number for
-|  easy reference to these values.  Some libraries may depend on them whether
-|  or not the code is meant for Multiboot.
-|
-+----------------------------------------------------------------------------*/
-    SYM(_gba_multiboot_start):
-        b       SYM(_real_start)               /* 0xC0 Multiboot Entry Point */
-    OBJECT(_boot_method)
-        .byte   0                              /* 0xC4 Boot Method           */
-    OBJECT(_slave_number)
-        .byte   0                              /* 0xC5 Slave Number (1-3)    */
-        .align
-    STATIC_OBJECT(_gba_mb_reserved)
-        .word   0, 0, 0, 0, 0, 0               /* 0xC8 Reserved (6 words)    */
-    SYM(_gba_joybus_start):
-        b       SYM(_real_start)               /* 0xE0 JoyBus Entry Point    */
-    .Lmultiboot_header_end:
-#endif
-
-/*---------------------------------------------------------------------------+
-|    Restore registers and stack from GBA bios IRQ frame and call ISR_Handler
-+----------------------------------------------------------------------------*/
-    EXTERN(_ISR_Handler)
-    .align
-    PUBLIC_ARM_FUNCTION(_gba_ISR_handler)
-        ldmfd  r13!,{r0-r3,r12,r14}
-        b      _ARMV4_Exception_interrupt
-    LABEL_END(_gba_ISR_handler)
-
-
-/*---------------------------------------------------------------------------+
-|    Code to initialize the low-level BSP environment
-+----------------------------------------------------------------------------*/
-    SYM(_real_start):
-    /* Initialize IRQ and USR Stack Pointers */
-    SYM(_gba_init_stacks):
-        mov     r0, #(Mode_IRQ | Int_Bits)       /* No interrupts            */
-        msr     cpsr, r0                         /* switch to IRQ mode       */
-        ldr     sp, =__sp_irq                    /* defined in linkcmds      */
-        mov     r0, #(ModePriv | Int_Bits)       /* No interrupts            */
-        msr     cpsr, r0                         /* switch to System Mode    */
-        ldr     sp, =__sp_usr                    /* defined in linkcmds      */
-
-    /* Switch to Thumb Mode */
-    SYM(_gba_bx_thumb):
-        adr     r0, .Lthumb + 1
-        bx      r0
-        .thumb
-    .Lthumb:
-    /* Reduce gameboy waitstates */
-    SYM(_reduce_waitstates):
-        ldr     r1, =0x4000204
-        ldrh    r0, =0x4490
-        strh    r0, [r1]
-
-
-#if GBA_MULTIBOOT
-/*---------------------------------------------------------------------------+
-|  Load Multiboot Image from ROM into RAM:
-|  Check to see if the image is meant for Multiboot or GamePak.  If it is for
-|  Multiboot then check if it is currently running from EWRAM or from CARTROM.
-|  If it is running from CARTROM, then it needs to be copied to EWRAM and
-|  re-executed from the beginning.
-|
-|  The reason for all this is to allow a program to be used "as-is" with a
-|  flash-cart, emulator, or MBV2-style Multiboot cable without rebuilding.
-|
-|  NOTE: Any branchs used above this code need to be relative.
-+----------------------------------------------------------------------------*/
-    STATIC_THUMB_FUNCTION(_gba_load_multiboot)
-        ldr     r0, =_start            /* 8000000h=GamePak 2000000h=Multiboot*/
-        ldr     r1, =__gba_rom_start   /* defined in linkcmds                */
-        cmp     r0, r1
-        beq     SYM(_no_load_multiboot)/* skip if GamePak                    */
-        mov     r3, pc
-        cmp     r1, r3                 /* check program counter              */
-        bhi     SYM(_no_load_multiboot)/* skip if already running from EWRAM */
-        sub     r3, r1, r0             /* diff between _start and CARTROM    */
-        ldr     r2, =__load_stop_data  /* defined in linkcmds                */
-        add     r2, r2, r3             /* adjust pointer into ROM            */
-        bl      SYM(gba_move_memory)
-
-        /* patch multiboot header */
-        ldr     r0, =SYM(_boot_method)
-        mov     r1, #3
-        str     r1, [r0]
-
-        /* remember that multiboot image came from GamePak */
-        ldr     r0, =SYM(_gba_flash_loaded_multiboot)
-        mov     r1, #0
-        str     r1, [r0]
-
-        ldr     r0, =SYM(_start)
-        bx      r0                      /* restart                           */
-    LABEL_END(_gba_load_multiboot)
-
-        .align 4
-    OBJECT(_gba_flash_loaded_multiboot)
-        .word -1
-    LABEL_END(_gba_flash_loaded_multiboot)
-    SYM(_no_load_multiboot):
-#endif
-
-/* Initialize Standard Sections */
-    STATIC_THUMB_FUNCTION(_gba_init_std_sections)
-        /* Copy internal work ram (iwram section ROM to RAM)*/
-        ldr     r0,=__iwram_start
-        ldr     r1,=__load_start_iwram
-        ldr     r2,=__load_stop_iwram
-        bl      SYM(gba_move_memory)
-
-        /* Copy external work ram (ewram section ROM to RAM) */
-        ldr     r0,=__ewram_start
-        ldr     r1,=__load_start_ewram
-        ldr     r2,=__load_stop_ewram
-        bl      SYM(gba_move_memory)
-
-        /* load initial values of variables like 'int foo = 42' */
-        ldr     r0, =__data_start      /* defined in linkcmds               */
-        ldr     r1, =__load_start_data /* defined in linkcmds               */
-        ldr     r2, =__load_stop_data  /* defined in linkcmds               */
-        bl      SYM(gba_move_memory)
-
-        /* zero the bss */
-        ldr     r0, =__bss_start       /* defined in linkcmds               */
-        ldr     r1, =__bss_end         /* defined in linkcmds               */
-        bl      SYM(gba_zero_memory)
-    LABEL_END(_gba_init_std_sections)
-
-/* Initialize Interrupt Vector */
-    STATIC_THUMB_FUNCTION(_gba_init_intr_vect)
-        ldr     r1, =__irq_vector    /* defined in linkcmds                 */
-        ldr     r0, =SYM(_gba_ISR_handler)
-        str     r0, [r1]
-    LABEL_END(_gba_init_intr_vect)
-
-
-/* Enter the C code.  If it returns, then restart */
-    STATIC_THUMB_FUNCTION(_gba_call_arm_boot_card)
-        adr     r1, .Larm
-        bx      r1
-        .arm
-    .Larm:
-        ldr     r1, =boot_card
-        mov     r0, #0
-        bl      SYM(_gba_call_via_r1)
-
-        ldr     r0, =SYM(_gba_reset)
-    SYM(_gba_call_via_r1):
-        bx      r1
-
-/* GBA Reset  */
-    PUBLIC_ARM_FUNCTION(_gba_reset)
-        adr     r0, .Lthumb2 + 1
-        bx      r0
-        .thumb
-    .Lthumb2:
-        /* disable interrupts */
-        ldr     r0, =0x04000208
-        mov     r1, #0
-        strb    r1, [r0]
-
-        /* reset stack, default free area */
-        ldr     r0, =0x03007F00
-        mov     sp, r0
-
-#if GBA_MULTIBOOT
-        ldr     r0, =SYM(_gba_flash_loaded_multiboot)
-        ldr     r0, [r0]
-        cmp     r0, #0
-        beq     SYM(_reset)
-#endif
-
-        ldr     r0, =_start            /* defined in linkcmds               */
-        ldr     r1, =__gba_rom_start   /* defined in linkcmds               */
-        sub     r0, r0, r1
-        lsr     r0, r0, #24
-
-   SYM(_reset):
-        /* soft reset (swi 0) parameter: where is _start */
-        ldr     r1, =0x03007FFA
-        strb    r0, [r1]
-        mov     r0, #0xFE              /* clear all but EWRAM               */
-        swi     1
-        swi     0
-    LABEL_END(_gba_reset)
-
-
-/*---------------------------------------------------------------------------+
-|   Library Functions
-+----------------------------------------------------------------------------*/
-
-/* gba_zero_memory */
-    PUBLIC_THUMB_FUNCTION(gba_zero_memory)
-        mov     r2, #0
-        nop
-    LABEL_END(gba_zero_memory)
-
-/* gba_set_memory */
-    PUBLIC_THUMB_FUNCTION(gba_set_memory)
-        cmp     r0, r1
-        bcs     .Lset_memory_return
-
-    .Lset_memory_loop:
-        stmia   r0!, {r2}
-        cmp     r0, r1
-        bcc     .Lset_memory_loop
-
-    .Lset_memory_return:
-        bx      lr
-    LABEL_END(gba_set_memory)
-
-/* gba_move_memory */
-    .align
-    PUBLIC_THUMB_FUNCTION(gba_move_memory)
-        cmp     r0, r1
-        bcc     .Lforward_move  /* if dst < src then forward copy */
-        bhi     .Lreverse_move  /* if dst > src then reverse copy */
-        bx      lr              /* else dst == src, nothing to do */
-
-    .Lforward_move:
-        cmp     r1, r2
-        bcs     .Lmove_memory_return
-
-    .Lforward_move_loop:
-        ldmia   r1!, {r3}
-        stmia   r0!, {r3}
-        cmp     r1, r2
-        bcc     .Lforward_move_loop
-        bx      lr
-
-    .Lreverse_move:
-        cmp     r2, r1
-        bls     .Lmove_memory_return
-        sub     r3, r2, r1
-        add     r0, r0, r3
-
-    .Lreverse_move_loop:
-        sub     r2, r2, #4
-        ldr     r3, [r2]
-        sub     r0, r0, #4
-        str     r3, [r0]
-        cmp     r2, r1
-        bhi     .Lreverse_move_loop
-
-    .Lmove_memory_return:
-        bx      lr
-    LABEL_END(gba_move_memory)
-
-
-/* @todo FIXME: Remove unused handler needed by ../score/cpu_asm.S
- *****************************************************************************/
-        .arm
-        .global SWI_Handler
-SWI_Handler:
-        mov pc, lr
-/* @endcond     */
-
Index: src/lib/libbsp/arm/gba/startup/bspgetworkarea.c
===================================================================
--- c/src/lib/libbsp/arm/gba/startup/bspgetworkarea.c	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,21 +1,0 @@
-/*
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#include <bsp.h>
-#include <bsp/bootcard.h>
-#include <stdint.h>
-
-extern int _end;
-extern int __heap_limit;
-
-void bsp_work_area_initialize(void)
-{
-  void *area_start = (void *)&_end;
-  uintptr_t area_size  = (uintptr_t)&__heap_limit - (uintptr_t)&_end;
-
-  bsp_work_area_initialize_default( area_start, area_size );
-}
-
Index: src/lib/libbsp/arm/gba/startup/bspreset.c
===================================================================
--- c/src/lib/libbsp/arm/gba/startup/bspreset.c	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,14 +1,0 @@
-/*
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#include <bsp.h>
-#include <bsp/bootcard.h>
-
-void bsp_reset(void)
-{
-  __asm__ volatile ("ldr  r0, =_gba_reset");
-  __asm__ volatile ("bx   r0");
-}
Index: src/lib/libbsp/arm/gba/startup/bspstart.c
===================================================================
--- c/src/lib/libbsp/arm/gba/startup/bspstart.c	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,58 +1,0 @@
-/**
- *  @file bspstart.c
- *
- *  This file contains the GBA BSP startup package.
- *  It includes application, board, and monitor specific initialization and
- *  configuration. The generic CPU dependent initialization has been
- *  performed before this routine is invoked.
- */
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- */
-
-#include <stdio.h>
-#include <bsp.h>
-#include <bsp/irq-generic.h>
-#include <rtems/bspIo.h>
-#include <gba.h>
-#include <conio.h>
-
-/** Chip registers */
-volatile unsigned int *Regs = (unsigned int *)GBA_IO_REGS_ADDR;
-
-/**
- *  @brief BSP Start
- *
- *  Called before main is invoked.
- *
- *  @param  None
- *  @return None
- */
-static void bsp_start_default( void )
-{
-  /* Init conio  */
-  gba_textmode(CO60);
-
-  /* Init rtems exceptions management
-   *  !!!!!GBA -- Can't use exception vectors in GBA because they are
-   *  already in GBA ROM BIOS
-   */
-  /* rtems_exception_init_mngt(); */
-
-  /* Init rtems interrupt management */
-  bsp_interrupt_initialize();
-}
-
-/**
- *  @brief weak alias for bsp_start_default
- *
- *  By making this a weak alias for bsp_start_default, a brave soul
- *  can override the actual bsp_start routine used.
- */
-void bsp_start (void) __attribute__ ((weak, alias("bsp_start_default")));
Index: src/lib/libbsp/arm/gba/startup/linkcmds
===================================================================
--- c/src/lib/libbsp/arm/gba/startup/linkcmds	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,386 +1,0 @@
-/**
- *  @file linkcmds
- *
- *  GBA BSP linker script
- */
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) Jeff Frohwein
- *
- *  Copyright (c) 2003  Jason Wilkins
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *
- *  http://www.rtems.org/license/LICENSE.
- */
-
-/*****************************************************************************
- * This Linker Script is based on work by Jeff Frohwein and Jason Wilkins
- *****************************************************************************
- * Linker Script v1.3 by Jeff Frohwein
- * :
- * This file is released into the public domain
- * for commercial or non-commercial use with no
- * restrictions placed upon it.
- *****************************************************************************
- * Copyright 2003, Jason Wilkins.  This source code is free for any use except
- * that this copyright notice and the following disclaimers remain intact when
- * the source is distributed.  There are absolutely no restrictions on use of
- * object code generated from this source, but the disclaimers remain in force.
- *
- * THIS CODE WAS NOT MADE IN ASSOCIATION WITH NINTENDO AND DOES NOT MAKE USE OF
- * ANY INTELLECTUAL PROPERTY CLAIMED BY NINTENDO.
- *
- * GAMEBOY ADVANCE IS A TRADEMARK OF NINTENDO.
- *
- * THIS CODE HAS BEEN PROVIDED "AS-IS" WITHOUT A WARRANTY OF ANY KIND, EITHER
- * EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO IMPLIED WARRANTIES OF
- * MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE.  THE ENTIRE RISK AS TO THE
- * QUALITY OR PERFORMANCE OF THE CODE IS WITH YOU.
- *
- * IN NO EVENT, UNLESS AGREED TO IN WRITING, WILL ANY COPYRIGHT HOLDER, OR ANY
- * OTHER PARTY, BE HELD LIABLE FOR ANY DAMAGES RESULTING FROM THE USE OR
- * INABILITY TO USE THIS CODE.
- *
- *****************************************************************************/
-/* @cond  INCLUDE_ASM */
-
-OUTPUT_FORMAT("elf32-littlearm", "elf32-bigarm", "elf32-littlearm")
-OUTPUT_ARCH(arm)
-ENTRY(_start)
-
-/*************************************************************************
-  The linker script MEMORY directive is not used here due to the fact
-  that  __ro_start is not always a fixed value.
- *************************************************************************
-MEMORY
-{
-  rom       : ORIGIN = 0x08000000 , LENGTH = 96M
-  iwram     : ORIGIN = 0x03000000 , LENGTH = 32K
-  ewram     : ORIGIN = 0x02000000 , LENGTH = 256K
-  sram      : ORIGIN = 0x0E000000 , LENGTH = 64K
-}
- *************************************************************************/
-__gba_ewram_start = 0x02000000;
-__gba_ewram_end   = 0x02040000;
-__gba_iwram_start = 0x03000000;
-__gba_iwram_end   = 0x03008000;
-__gba_rom_start   = 0x08000000;
-__gba_rom_end     = 0x0E000000;
-__gba_sram_start  = 0x0E000000;
-__gba_sram_end    = 0x0E010000;
-
-__sp_irq_size     = 0x2A0;
-_stack_size       = 0xA00;
-__irq_vector      = __gba_iwram_end - 0x0004; /* 0x03007FFC */
-__sp_svc          = __gba_iwram_end - 0x0020; /* 0x03007FE0 */
-__sp_irq          = __gba_iwram_end - 0x0060; /* 0x03007FA0 */
-__sp_usr          = __sp_irq - __sp_irq_size; /* 0x03007D00 */
-__sp_limit        = __sp_usr - _stack_size;   /* 0x03007300 */
-__heap_limit      = DEFINED(__gba_multiboot) ? __gba_ewram_end : ( DEFINED(__gba_iwram_bss) ? __sp_limit :  __gba_ewram_end ) ;
-
-
-SECTIONS
-{
-/*** read-only sections ***/
-/*************************************************************************
-  if 'multiboot' allocate prog in __gba_ewram_start (0x02000000-0x0207FFFF)
-  else allocate prog in __gba_rom_start (0x08000000-0x0DFFFFFF)
- *************************************************************************/
-  __ro_start = DEFINED(__gba_multiboot) ? __gba_ewram_start : __gba_rom_start ;
-  PROVIDE(__text_start__ = __ro_start );
-  .text  __ro_start :
-  {
-    CREATE_OBJECT_SYMBOLS
-    */start.o(.text)
-    *(EXCLUDE_FILE(*.rodata.* *.ewram.o *.iwram.o) .text)
-    *(.stub .text.* .gnu.linkonce.t*)
-
-    /*
-     * Special FreeBSD sysctl sections.
-     */
-    . = ALIGN (16);
-    __start_set_sysctl_set = .;
-    *(set_sysctl_*);
-    __stop_set_sysctl_set = ABSOLUTE(.);
-    *(set_domain_*);
-    *(set_pseudo_*);
-
-    /* .gnu.warning sections are handled specially by elf32.em. */
-    *(.gnu.warning)
-    *(.glue_7)
-    *(.glue_7t)
-    . = ALIGN(4);
-  } =0xFF
-
-  .init :
-  {
-    *(.init)
-    . = ALIGN(4);
-  } =0xFF
-
-  .fini :
-  {
-    *(.fini)
-    . = ALIGN(4);
-  } =0xFF
-
-  __rodata_start = . ;
-  .rodata :
-  {
-    *(.rodata1)
-    *(EXCLUDE_FILE(*.rodata.* *.ewram.o *.iwram.o) .rodata)
-    *(.rodata.* .gnu.linkonce.r*)
-    KEEP (*(SORT(.rtemsroset.*)))
-    *(.roda) /* deprecated: for compatibility with objcopyroda */
-    SORT(CONSTRUCTORS)
-    . = ALIGN(4);
-  } =0xFF
-  .tdata : {
-    _TLS_Data_begin = .;
-    *(.tdata .tdata.* .gnu.linkonce.td.*)
-    _TLS_Data_end = .;
-  } =0xFF
-  .tbss : {
-    _TLS_BSS_begin = .;
-    *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon)
-    _TLS_BSS_end = .;
-  }
-  _TLS_Data_size = _TLS_Data_end - _TLS_Data_begin;
-  _TLS_Data_begin = _TLS_Data_size != 0 ? _TLS_Data_begin : _TLS_BSS_begin;
-  _TLS_Data_end = _TLS_Data_size != 0 ? _TLS_Data_end : _TLS_BSS_begin;
-  _TLS_BSS_size = _TLS_BSS_end - _TLS_BSS_begin;
-  _TLS_Size = _TLS_BSS_end - _TLS_Data_begin;
-  _TLS_Alignment = MAX (ALIGNOF (.tdata), ALIGNOF (.tbss));
-  __rodata_end = . ;
-
-  .eh_frame :
-  {
-    KEEP(*(.eh_frame))
-    . = ALIGN(4);
-  } =0xFF
-
-  .gcc_except_table :
-  {
-    *(.gcc_except_table*)
-    . = ALIGN(4);
-  } =0xFF
-
-  .ctors :
-  {
-    /* gcc uses crtbegin.o to find the start of
-       the constructors, so we make sure it is first.
-       Because this is a wildcard, it doesn't matter
-       if the user does not actually link against crtbegin.o;
-       the linker won't look for a file to match a wildcard.
-       The wildcard also means that it doesn't matter which
-       directory crtbegin.o is in.
-     */
-    KEEP(*crtbegin.o(.ctors))
-    /* We don't want to include the .ctor section from
-       the crtend.o file until after the sorted ctors.
-       The .ctor section from the crtend file contains the
-       end of ctors marker and it must be last
-     */
-     KEEP(*(EXCLUDE_FILE (*crtend.o) .ctors))
-     KEEP(*(SORT(.ctors.*)))
-     KEEP(*(.ctors))
-    . = ALIGN(4);
-  } =0xFF
-
-  .dtors :
-  {
-    KEEP(*crtbegin.o(.dtors))
-    KEEP(*(EXCLUDE_FILE (*crtend.o ) .dtors))
-    KEEP(*(SORT(.dtors.*)))
-    KEEP(*(.dtors))
-    . = ALIGN(4);
-  } =0xFF
-
-  .jcr :
-  {
-    *(.jcr)
-    . = ALIGN(4);
-  } =0xFF
-
-  .ARM.extab : {
-    *(.ARM.extab* .gnu.linkonce.armextab.*)
-  } =0xff
-   __exidx_start = .;
-  .ARM.exidx : {
-    *(.ARM.exidx* .gnu.linkonce.armexidx.*)
-  } =0xff
-   __exidx_end = .;
-  .preinit_array : {
-    PROVIDE_HIDDEN (__preinit_array_start = .);
-    KEEP (*(.preinit_array))
-    PROVIDE_HIDDEN (__preinit_array_end = .);
-  } =0xFF
-  .init_array : {
-     PROVIDE_HIDDEN (__init_array_start = .);
-     KEEP (*(SORT(.init_array.*)))
-     KEEP (*(.init_array))
-     PROVIDE_HIDDEN (__init_array_end = .);
-  } =0xFF
-  .fini_array : {
-    PROVIDE_HIDDEN (__fini_array_start = .);
-    KEEP (*(.fini_array))
-    KEEP (*(SORT(.fini_array.*)))
-    PROVIDE_HIDDEN (__fini_array_end = .);
-  } =0xFF
-
-/*************************************************************************
-  calculate __ro_end
- *************************************************************************/
-  __ro_end = .;
-  PROVIDE(__text_end__ = __ro_end );
-
-/*** IWRAM ***/
-/*************************************************************************
-  allocate iwram in __gba_iwram_start (0x03000000-0x03003FFF)
- *************************************************************************/
-  __load_start_iwram = __ro_end;
-  . = __gba_iwram_start ;
-  __iwram_start = . ;
-  PROVIDE(__iwram_start__ = . );
-  .iwram : AT(__load_start_iwram)
-  {
-    /* put irq_vector_table in stat of iwram  */
-    CREATE_OBJECT_SYMBOLS
-    _irq_vector_table = .;
-    PROVIDE(irq_vector_table = .);
-    . += 4;
-    . = ALIGN(16 * 4);
-    PROVIDE(irq_vector_table_end = .);
-    _irq_vector_table_end = .;
-    *(.iwram .iwram.*)
-    *.iwram.o (.text .rodata .data)
-    . = ALIGN(4);
-  } =0xFF
-  __iwram_end = . ;
-  PROVIDE(__iwram_end__ = . );
-  __load_stop_iwram = __load_start_iwram + SIZEOF(.iwram);
-
- _irq_vector_table_size = _irq_vector_table_end - _irq_vector_table;
- PROVIDE(_irq_max_vector = _irq_vector_table_size / 4 );
-
-
-/*** EWRAM ***/
-/*************************************************************************
-  if 'multiboot' allocate prog+ewram in __gba_ewram
-  else allocate only ewram in __gba_ewram_start
- *************************************************************************/
-  . = DEFINED(__gba_multiboot) ? __load_stop_iwram : __gba_ewram_start ;
-  __load_start_ewram = __load_stop_iwram;
-  __ewram_start = . ;
-  PROVIDE(__ewram_start__ = . );
-  .ewram : AT(__load_start_ewram)
-  {
-    *(.ewram .ewram.*)
-    *.ewram.o (.text .rodata .data)
-    . = ALIGN(4);
-  } =0xFF
-  __ewram_end = . ;
-  PROVIDE(__ewram_end__ = . );
-  __load_stop_ewram = __load_start_ewram + SIZEOF(.ewram) ;
-
-/*************************************************************************
-    if 'multiboot' allocate prog+ewram+data+bss in __gba_ewram
-    else if 'iwram_data' allocate data in __gba_iwram
-    else allocate data in __gba_ewram
- *************************************************************************/
-  . = DEFINED(__gba_multiboot) ? __load_stop_ewram : (DEFINED(__gba_iwram_data) ? __iwram_end : __ewram_end) ;
-  __load_start_data = __load_stop_ewram;
-  __data_start = . ;
-  PROVIDE(__data_start__ = . );
-  .data : AT(__load_start_data)
-  {
-    *(.sdata2 .sdata2.* .gnu.linkonce.s2.*)
-    *(EXCLUDE_FILE(*.rodata.* *.ewram.o *.iwram.o) .data)
-    *(.data.* .gnu.linkonce.d.*)
-    *(.data1)
-    KEEP (*(SORT(.rtemsrwset.*)))
-    *(.sdata .sdata.* .gnu.linkonce.s.*)
-    . = ALIGN(4);
-  } =0xFF
-  __data_end = . ;
-  PROVIDE(__data_end__ = . );
-  __load_stop_data = __load_start_data + SIZEOF(.data);
-
-/*** BSS ***/
-/*************************************************************************
-    if 'multiboot' allocate prog+ewram+data+bss in __gba_ewram
-    else if 'iwram_data' and 'iwram_bss' allocate iwram+data+bss in __gba_iwram
-    else if !'iwram_data' and 'iwram_bss' allocate iwram+bss in __gba_iwram
-    else allocate data+ewram+bss in  __gba_ewram
- *************************************************************************/
-  . = DEFINED(__gba_multiboot) ? __load_stop_data : ( DEFINED(__gba_iwram_data) ? (DEFINED(__gba_iwram_bss) ? __data_end :  __ewram_end) : (DEFINED(__gba_iwram_bss) ? __iwram_end : __data_end) ) ;
-  __bss_start = . ;
-  PROVIDE(__bss_start__ = . );
-  .bss :
-  {
-    *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*)
-    *(.tcommon)
-    *(.sbss .sbss.* .gnu.linkonce.sb.*)
-    *(.scommon)
-    *(.bss .bss.* .gnu.linkonce.b*)
-    *(COMMON)
-    . = ALIGN(4);
-  }
-  __bss_end = . ;
-  PROVIDE(__bss_end__ = . );
-  PROVIDE(_bss_end__ = . );
-
-  PROVIDE(_end = . );
-  PROVIDE(__end__ = _end);
-  PROVIDE(end = _end);
-
-
-/*** debugging info ***/
-  /* Stabs debugging sections.  */
-  .stab 0 : { *(.stab) }
-  .stabstr 0 : { *(.stabstr) }
-  .stab.excl 0 : { *(.stab.excl) }
-  .stab.exclstr 0 : { *(.stab.exclstr) }
-  .stab.index 0 : { *(.stab.index) }
-  .stab.indexstr 0 : { *(.stab.indexstr) }
-  /* DWARF debug sections.
-   Symbols in the DWARF debugging sections are relative to the beginning
-   of the section so we begin them at 0.  */
-  /* DWARF 1 */
-  .debug          0 : { *(.debug) }
-  .line           0 : { *(.line) }
-  /* GNU DWARF 1 extensions */
-  .debug_srcinfo  0 : { *(.debug_srcinfo) }
-  .debug_sfnames  0 : { *(.debug_sfnames) }
-  /* DWARF 1.1 and DWARF 2 */
-  .debug_aranges  0 : { *(.debug_aranges) }
-  .debug_pubnames 0 : { *(.debug_pubnames) }
-  /* DWARF 2 */
-  .debug_info     0 : { *(.debug_info) }
-  .debug_abbrev   0 : { *(.debug_abbrev) }
-  .debug_line     0 : { *(.debug_line) }
-  .debug_frame    0 : { *(.debug_frame) }
-  .debug_str      0 : { *(.debug_str) }
-  .debug_loc      0 : { *(.debug_loc) }
-  .debug_macinfo  0 : { *(.debug_macinfo) }
-  .comment        0 : { *(.comment) }
-  /* SGI/MIPS DWARF 2 extensions */
-  .debug_weaknames 0 : { *(.debug_weaknames) }
-  .debug_funcnames 0 : { *(.debug_funcnames) }
-  .debug_typenames 0 : { *(.debug_typenames) }
-  .debug_varnames  0 : { *(.debug_varnames) }
-  /* DWARF 3 */
-  .debug_pubtypes 0 : { *(.debug_pubtypes) }
-  .debug_ranges   0 : { *(.debug_ranges) }
-  /* DWARF extension */
-  .debug_macro    0 : { *(.debug_macro) }
-  .ARM.attributes 0 : { KEEP (*(.ARM.attributes)) KEEP (*(.gnu.attributes)) }
-  .note.gnu.arm.ident 0 : { KEEP (*(.note.gnu.arm.ident)) }
-  /DISCARD/ : { *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) }
-}
-/* @endcond */
Index: src/lib/libbsp/arm/gba/timer/timer.c
===================================================================
--- c/src/lib/libbsp/arm/gba/timer/timer.c	(revision 32c2cd2be1067ebe32cdabccbc8aa16126ae3a32)
+++ 	(revision )
@@ -1,134 +1,0 @@
-/**
- *  @file timer.c
- *
- *  GBA Timer driver.
- */
-/*
- *  RTEMS GBA BSP
- *
- *  Copyright (c) 2002 by Jay Monkman <jtm@smoothsmoothie.com>
- *
- *  Copyright (c) 2004  Markku Puro <markku.puro@kopteri.net>
- *
- *  The license and distribution terms for this file may be
- *  found in the file LICENSE in this distribution or at
- *  http://www.rtems.org/license/LICENSE.
- *
- *
- * Notes:
- *  This file manages the benchmark timer used by the RTEMS Timing Test
- *  Suite.  Each measured time period is demarcated by calls to
- *  benchmark_timer_initialize() and benchmark_timer_read().  benchmark_timer_read() usually returns
- *  the number of microseconds since benchmark_timer_initialize() exitted.
- *
- *  It is important that the timer start/stop overhead be determined
- *  when porting or modifying this code.
- */
-
-#include <rtems.h>
-#include <bsp.h>
-#include <rtems/btimer.h>
-#include <bsp/irq.h>
-#include <gba.h>
-
-/*
- * Set up the timer hardware
- *    1 / 16.78Mhz  => 59.595 ns
- *   64 / 16.78Mhz  =>  3.814 us
- *  256 / 16.78Mhz  => 15.256 us
- * 1024 / 16.78Mhz  => 61.025 us
- */
-#define  __TimePreScaler      1
-#define  __TickTime_ns        ((1000000000L/__ClockFrequency)*__TimePreScaler)
-#define  __TickTime_us        ((1000000L/__ClockFrequency)*__TimePreScaler)
-
-#if (__TimePreScaler==1)
- #define GBA_TM0CNT_PS    0x0000
-#elif (__TimePreScaler==64)
- #define GBA_TM0CNT_PS    0x0001
-#elif (__TimePreScaler==256)
- #define GBA_TM0CNT_PS    0x0002
-#elif (__TimePreScaler==1024)
- #define GBA_TM0CNT_PS    0x0003
-#else
- #define GBA_TM0CNT_PS    0x0003
-#endif
-
-bool benchmark_timer_find_average_overhead;
-
-/**
- *  @brief benchmark_timer_initialize start TM0 and TM1
- *
- *  @param  None
- *  @return None
- */
-void benchmark_timer_initialize( void )
-{
-  GBA_REG_TM1CNT =  0x0000;                /* Stop Counters         */
-  GBA_REG_TM0CNT =  0x0000;
-  GBA_REG_TM1D   =  0x0000;                /* Reset Counters        */
-  GBA_REG_TM0D   =  0x0000;
-  /* Start Counters */
-  GBA_REG_TM1CNT =  0x0084;                /* Start Count Up timing */
-  GBA_REG_TM0CNT = (0x0080|GBA_TM0CNT_PS); /* Start Count           */
-}
-
-/*
- *  The following controls the behavior of benchmark_timer_read().
- *
- *  AVG_OVEREHAD is the overhead for starting and stopping the timer.  It
- *  is usually deducted from the number returned.
- *
- *  LEAST_VALID is the lowest number this routine should trust.  Numbers
- *  below this are "noise" and zero is returned.
- */
-
-#define AVG_OVERHEAD    3  /**< It typically takes 3 microseconds          */
-#define LEAST_VALID     1  /**< Don't trust a clicks value lower than this */
-
-/**
- *  @brief benchmark_timer_read return timer countervalue in microseconds.
- *
- *  Used in Timing Test Suite.
- *
- *  @param  None
- *  @return Timer value in microseconds
- */
-benchmark_timer_t benchmark_timer_read( void )
-{
-  uint32_t  ticks;
-  uint32_t  total;
-
-  /* Stop Counters */
-  GBA_REG_TM0CNT =  0x0000;
-  GBA_REG_TM1CNT =  0x0000;
-  /* Read Counters */
-  ticks = (GBA_REG_TM1D<<16) | GBA_REG_TM0D;
-  if ( ticks < LEAST_VALID ) {
-      return 0;  /* below timer resolution */
-  }
-  /* convert to uS */
-  total = ((ticks * __TickTime_ns) / 1000);
-  if ( benchmark_timer_find_average_overhead == true ) {
-      return total;          /* in microseconds */
-  }
-  else {
-    if ( total < AVG_OVERHEAD ) {
-        return 0;
-    }
-    return (total - AVG_OVERHEAD);
-  }
-}
-
-/**
- *  @brief Set benchmark_timer_find_average_overhead flag.
- *
- *  Used in Timing Test Suite.
- *
- *  @param  find_flag bool find_flag
- *  @return None
-*/
-void benchmark_timer_disable_subtracting_average_overhead(bool find_flag)
-{
-   benchmark_timer_find_average_overhead = find_flag;
-}
