[GSOC2009] Clean code of gumstix bsp and skyeye shut down support added
Joel Sherrill
joel.sherrill at OARcorp.com
Wed Jun 17 20:12:45 UTC 2009
xi yang wrote:
> Joel, please remove bits.h in pxa255 directory since we don't need it.
>
>
Do you have a ChangeLog entry for this set of changes?
--joel
> Index: c/src/lib/libbsp/arm/gumstix/Makefile.am
> ===================================================================
> RCS file: /usr1/CVS/rtems/c/src/lib/libbsp/arm/gumstix/Makefile.am,v
> retrieving revision 1.1
> diff -u -r1.1 Makefile.am
> --- c/src/lib/libbsp/arm/gumstix/Makefile.am 4 Jun 2009 16:23:11 -0000 1.1
> +++ c/src/lib/libbsp/arm/gumstix/Makefile.am 14 Jun 2009 12:05:47 -0000
> @@ -21,38 +21,28 @@
>
> nodist_include_HEADERS += ../../shared/include/coverhd.h
>
> -EXTRA_DIST = start/start.S
> -start.$(OBJEXT): start/start.S
> - $(CPPASCOMPILE) -o $@ -c $<
> +noinst_LIBRARIES = libbspstart.a
> +libbspstart_a_SOURCES = ./start/start.S
> project_lib_DATA = start.$(OBJEXT)
>
> dist_project_lib_DATA += startup/linkcmds
>
> -noinst_PROGRAMS += startup.rel
> -startup_rel_SOURCES = ../../shared/bsplibc.c ../../shared/bsppost.c \
> +noinst_LIBRARIES += libbsp.a
> +libbsp_a_SOURCES =
> +#startup
> +libbsp_a_SOURCES += ../../shared/bsplibc.c ../../shared/bsppost.c \
> ../../shared/bsppredriverhook.c ../../shared/bspgetworkarea.c \
> ../../shared/bootcard.c ../../shared/sbrk.c \
> - ../../shared/gnatinstallhandler.c ../../shared/bsppretaskinghook.c \
> - ../../shared/bspclean.c ../../shared/bspreset.c \
> - startup/bspstart.c startup/memmap.c
> -
> -startup_rel_CPPFLAGS = $(AM_CPPFLAGS)
> -startup_rel_LDFLAGS = $(RTEMS_RELLDFLAGS)
> -
> -noinst_PROGRAMS += console.rel
> -console_rel_SOURCES = console/uarts.c ../../shared/console.c
> -console_rel_CPPFLAGS = $(AM_CPPFLAGS)
> -console_rel_LDFLAGS = $(RTEMS_RELLDFLAGS)
> + ../../shared/gnatinstallhandler.c ../../shared/bsppretaskinghook.c \
> + ../../shared/bspclean.c \
> + startup/bspstart.c startup/memmap.c
> +
> +#console
> +libbsp_a_SOURCES += console/uarts.c ../../shared/console.c
> +#abort
> +libbsp_a_SOURCES += ../shared/abort/abort.c
>
> -noinst_PROGRAMS += abort.rel
> -abort_rel_SOURCES = ../shared/abort/abort.c
> -abort_rel_CPPFLAGS = $(AM_CPPFLAGS)
> -abort_rel_LDFLAGS = $(RTEMS_RELLDFLAGS)
> -
> -noinst_LIBRARIES = libbsp.a
> -libbsp_a_SOURCES =
> -libbsp_a_LIBADD = startup.rel console.rel abort.rel
> -libbsp_a_LIBADD += ../../../libcpu/@RTEMS_CPU@/shared/arm920.rel \
> +libbsp_a_LIBADD = ../../../libcpu/@RTEMS_CPU@/shared/arm920.rel \
> ../../../libcpu/@RTEMS_CPU@/@RTEMS_CPU_MODEL@/clock.rel \
> ../../../libcpu/@RTEMS_CPU@/@RTEMS_CPU_MODEL@/timer.rel \
> ../../../libcpu/@RTEMS_CPU@/@RTEMS_CPU_MODEL@/ffuart.rel \
> Index: c/src/lib/libbsp/arm/gumstix/bsp_specs
> ===================================================================
> RCS file: /usr1/CVS/rtems/c/src/lib/libbsp/arm/gumstix/bsp_specs,v
> retrieving revision 1.1
> diff -u -r1.1 bsp_specs
> --- c/src/lib/libbsp/arm/gumstix/bsp_specs 4 Jun 2009 16:23:11 -0000 1.1
> +++ c/src/lib/libbsp/arm/gumstix/bsp_specs 14 Jun 2009 12:05:47 -0000
> @@ -4,10 +4,10 @@
>
> *startfile:
> %{!qrtems: %(old_startfile)} \
> -%{!nostdlib: %{qrtems: start.o%s crti.o%s crtbegin.o%s}}
> +%{!nostdlib: %{qrtems: start.o%s crti.o%s crtbegin.o%s -e _start}}
>
> *link:
> -%{!qrtems: %(old_link)} %{qrtems: -Qy -dp -Bstatic -N -e _start}
> +%{!qrtems: %(old_link)} %{qrtems: -dp -Bstatic -N}
>
> *endfile:
> %{!qrtems: *(old_endfiles)} %{qrtems: crtend.o%s crtn.o%s }
> Index: c/src/lib/libbsp/arm/gumstix/start/start.S
> ===================================================================
> RCS file: /usr1/CVS/rtems/c/src/lib/libbsp/arm/gumstix/start/start.S,v
> retrieving revision 1.1
> diff -u -r1.1 start.S
> --- c/src/lib/libbsp/arm/gumstix/start/start.S 4 Jun 2009 16:23:11 -0000 1.1
> +++ c/src/lib/libbsp/arm/gumstix/start/start.S 14 Jun 2009 12:05:47 -0000
> @@ -1,6 +1,6 @@
> /*
> * By Yang Xi <hiyangxi at gmail.com>.
> - * Based upon CSB336
> + * Based upon CSB337
> *
> * The license and distribution terms for this file may be
> * found in the file LICENSE in this distribution or at
> Index: c/src/lib/libbsp/arm/gumstix/startup/bspstart.c
> ===================================================================
> RCS file: /usr1/CVS/rtems/c/src/lib/libbsp/arm/gumstix/startup/bspstart.c,v
> retrieving revision 1.1
> diff -u -r1.1 bspstart.c
> --- c/src/lib/libbsp/arm/gumstix/startup/bspstart.c 4 Jun 2009
> 16:23:11 -0000 1.1
> +++ c/src/lib/libbsp/arm/gumstix/startup/bspstart.c 14 Jun 2009 12:05:47 -0000
> @@ -43,3 +43,11 @@
> * can override the actual bsp_start routine used.
> */
> void bsp_start (void) __attribute__ ((weak, alias("bsp_start_default")));
> +
> +
> +void bsp_reset( void )
> +{
> +#if ON_SKYEYE == 1
> + SKYEYE_MAGIC_ADDRESS = 0xff;
> +#endif
> +}
> Index: c/src/lib/libcpu/arm/pxa255/ffuart/ffuart.c
> ===================================================================
> RCS file: /usr1/CVS/rtems/c/src/lib/libcpu/arm/pxa255/ffuart/ffuart.c,v
> retrieving revision 1.2
> diff -u -r1.2 ffuart.c
> --- c/src/lib/libcpu/arm/pxa255/ffuart/ffuart.c 5 Jun 2009 22:10:42 -0000 1.2
> +++ c/src/lib/libcpu/arm/pxa255/ffuart/ffuart.c 14 Jun 2009 12:05:55 -0000
> @@ -20,6 +20,7 @@
> #include <libchip/sersupp.h>
>
> volatile int dbg_dly;
> +void _start(void);
>
> /* static function prototypes */
> static int ffuart_first_open(int major, int minor, void *arg);
> @@ -126,6 +127,7 @@
> }
>
> c = (char) buf[i];
> +#if ON_SKYEYE != 1
> if(c=='\n'){
> ffuart->rbr = '\r';
> for (x = 0; x < 100; x++) {
> @@ -136,8 +138,8 @@
> break;
> }
> }
> - ffuart->rbr = c;
> }
> +#endif
> ffuart->rbr = c;
>
> /* the TXRDY flag does not seem to update right away (is this true?) */
> Index: c/src/lib/libcpu/arm/pxa255/include/pxa255.h
> ===================================================================
> RCS file: /usr1/CVS/rtems/c/src/lib/libcpu/arm/pxa255/include/pxa255.h,v
> retrieving revision 1.1
> diff -u -r1.1 pxa255.h
> --- c/src/lib/libcpu/arm/pxa255/include/pxa255.h 4 Jun 2009 16:33:31 -0000 1.1
> +++ c/src/lib/libcpu/arm/pxa255/include/pxa255.h 14 Jun 2009 12:05:56 -0000
> @@ -86,8 +86,7 @@
> #define FFUART_BASE 0x40100000
>
>
> -/*Write the MAGIC_NUMBER to the MAGIC_ADDRESS then the Skyeye will exit,
> - we can use this function to automatic test the RTEMS bsp */
> +/*Write to KSYEYE_MAGIC_ADDRESS makes SKYEYE to exits*/
>
> #define SKYEYE_MAGIC_ADDRESS (*(volatile word_t *)(0xb0000000))
> #define SKYEYE_MAGIC_NUMBER (0xf0f0f0f0)
>
--
Joel Sherrill, Ph.D. Director of Research & Development
joel.sherrill at OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (256) 722-9985
More information about the users
mailing list