diff options
Diffstat (limited to 'c/src/lib/libbsp/hppa1.1/simhppa')
-rw-r--r-- | c/src/lib/libbsp/hppa1.1/simhppa/startup/Makefile.in | 2 | ||||
-rw-r--r-- | c/src/lib/libbsp/hppa1.1/simhppa/startup/bspstart.c | 28 |
2 files changed, 3 insertions, 27 deletions
diff --git a/c/src/lib/libbsp/hppa1.1/simhppa/startup/Makefile.in b/c/src/lib/libbsp/hppa1.1/simhppa/startup/Makefile.in index 894abe0d42..05f8abd940 100644 --- a/c/src/lib/libbsp/hppa1.1/simhppa/startup/Makefile.in +++ b/c/src/lib/libbsp/hppa1.1/simhppa/startup/Makefile.in @@ -11,7 +11,7 @@ PROJECT_ROOT = @PROJECT_ROOT@ PGM=${ARCH}/startup.rel # C source names, if any, go here -- minus the .c -C_PIECES=bspclean bspstart main sbrk setvec +C_PIECES=bspclean bsppost bspstart main sbrk setvec C_FILES=$(C_PIECES:%=%.c) C_O_FILES=$(C_PIECES:%=${ARCH}/%.o) diff --git a/c/src/lib/libbsp/hppa1.1/simhppa/startup/bspstart.c b/c/src/lib/libbsp/hppa1.1/simhppa/startup/bspstart.c index ecb7a69d48..dbcbecd1d2 100644 --- a/c/src/lib/libbsp/hppa1.1/simhppa/startup/bspstart.c +++ b/c/src/lib/libbsp/hppa1.1/simhppa/startup/bspstart.c @@ -29,7 +29,6 @@ #include <libcsupport.h> #include <string.h> -#include <fcntl.h> #ifdef STACK_CHECKER_ON #include <stackchk.h> @@ -229,33 +228,10 @@ bsp_pretasking_hook(void) } /* - * After drivers are setup, register some "filenames" - * and open stdin, stdout, stderr files - * - * Newlib will automatically associate the files with these - * (it hardcodes the numbers) + * Use the shared bsp_postdriver_hook() implementation */ - -void -bsp_postdriver_hook(void) -{ - int stdin_fd, stdout_fd, stderr_fd; - int error_code; - - error_code = 'S' << 24 | 'T' << 16; - if ((stdin_fd = __rtems_open("/dev/console", O_RDONLY, 0)) == -1) - rtems_fatal_error_occurred( error_code | 'D' << 8 | '0' ); - - if ((stdout_fd = __rtems_open("/dev/console", O_WRONLY, 0)) == -1) - rtems_fatal_error_occurred( error_code | 'D' << 8 | '1' ); - - if ((stderr_fd = __rtems_open("/dev/console", O_WRONLY, 0)) == -1) - rtems_fatal_error_occurred( error_code | 'D' << 8 | '2' ); - - if ((stdin_fd != 0) || (stdout_fd != 1) || (stderr_fd != 2)) - rtems_fatal_error_occurred( error_code | 'I' << 8 | 'O' ); -} +void bsp_postdriver_hook(void); /* * Function: bsp_start |