From ee5171b968d87e2807608c64c8a2692d69299ff4 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Fri, 26 Sep 2003 21:38:59 +0000 Subject: 2003-09-26 Joel Sherrill * hppa1.1/.cvsignore, hppa1.1/ChangeLog, hppa1.1/Makefile.am, hppa1.1/acinclude.m4, hppa1.1/configure.ac, hppa1.1/simhppa/.cvsignore, hppa1.1/simhppa/ChangeLog, hppa1.1/simhppa/Makefile.am, hppa1.1/simhppa/bsp_specs, hppa1.1/simhppa/configure.ac, hppa1.1/simhppa/times, hppa1.1/simhppa/include/.cvsignore, hppa1.1/simhppa/include/Makefile.am, hppa1.1/simhppa/include/bsp.h, hppa1.1/simhppa/include/ttydrv.h, hppa1.1/simhppa/shmsupp/.cvsignore, hppa1.1/simhppa/shmsupp/Makefile.am, hppa1.1/simhppa/shmsupp/README, hppa1.1/simhppa/shmsupp/addrconv.c, hppa1.1/simhppa/shmsupp/cause_intr.c, hppa1.1/simhppa/shmsupp/getcfg.c, hppa1.1/simhppa/shmsupp/lock.c, hppa1.1/simhppa/shmsupp/mpisr.c, hppa1.1/simhppa/start/.cvsignore, hppa1.1/simhppa/start/Makefile.am, hppa1.1/simhppa/start/start.S, hppa1.1/simhppa/startup/.cvsignore, hppa1.1/simhppa/startup/Makefile.am, hppa1.1/simhppa/startup/bspclean.c, hppa1.1/simhppa/startup/bspstart.c, hppa1.1/simhppa/startup/linkcmds, hppa1.1/simhppa/startup/setvec.c, hppa1.1/simhppa/tools/.cvsignore, hppa1.1/simhppa/tools/ChangeLog, hppa1.1/simhppa/tools/Makefile.am, hppa1.1/simhppa/tools/configure.ac, hppa1.1/simhppa/tools/print_dump.c, hppa1.1/simhppa/tty/.cvsignore, hppa1.1/simhppa/tty/Makefile.am, hppa1.1/simhppa/tty/tty.c, hppa1.1/simhppa/wrapup/.cvsignore, hppa1.1/simhppa/wrapup/Makefile.am: Removed. --- c/src/lib/libbsp/hppa1.1/simhppa/tools/.cvsignore | 18 -- c/src/lib/libbsp/hppa1.1/simhppa/tools/ChangeLog | 71 ----- c/src/lib/libbsp/hppa1.1/simhppa/tools/Makefile.am | 16 - .../lib/libbsp/hppa1.1/simhppa/tools/configure.ac | 25 -- .../lib/libbsp/hppa1.1/simhppa/tools/print_dump.c | 338 --------------------- 5 files changed, 468 deletions(-) delete mode 100644 c/src/lib/libbsp/hppa1.1/simhppa/tools/.cvsignore delete mode 100644 c/src/lib/libbsp/hppa1.1/simhppa/tools/ChangeLog delete mode 100644 c/src/lib/libbsp/hppa1.1/simhppa/tools/Makefile.am delete mode 100644 c/src/lib/libbsp/hppa1.1/simhppa/tools/configure.ac delete mode 100644 c/src/lib/libbsp/hppa1.1/simhppa/tools/print_dump.c (limited to 'c/src/lib/libbsp/hppa1.1/simhppa/tools') diff --git a/c/src/lib/libbsp/hppa1.1/simhppa/tools/.cvsignore b/c/src/lib/libbsp/hppa1.1/simhppa/tools/.cvsignore deleted file mode 100644 index d79c64fcb4..0000000000 --- a/c/src/lib/libbsp/hppa1.1/simhppa/tools/.cvsignore +++ /dev/null @@ -1,18 +0,0 @@ -aclocal.m4 -autom4te*.cache -config.cache -config.guess -config.h -config.h.in -config.log -config.status -config.sub -configure -depcomp -install-sh -Makefile -Makefile.in -missing -mkinstalldirs -stamp-h -stamp-h.in diff --git a/c/src/lib/libbsp/hppa1.1/simhppa/tools/ChangeLog b/c/src/lib/libbsp/hppa1.1/simhppa/tools/ChangeLog deleted file mode 100644 index 7a85475959..0000000000 --- a/c/src/lib/libbsp/hppa1.1/simhppa/tools/ChangeLog +++ /dev/null @@ -1,71 +0,0 @@ -2003-08-18 Ralf Corsepius - - * Makefile.am: Reflect having moved aclocal/. - -2003-08-16 Ralf Corsepius - - * Makefile.am: Reflect having moved automake/. - -2003-08-11 Ralf Corsepius - - * configure.ac: Use rtems-bugs@rtems.com as bug report email address. - -2003-03-06 Ralf Corsepius - - * configure.ac: Remove AC_CONFIG_AUX_DIR. - -2003-02-11 Ralf Corsepius - - * configure.ac: AM_INIT_AUTOMAKE([1.7.2]). - -2003-02-11 Ralf Corsepius - - * configure.ac: AC_PREREQ(2.57). - -2002-10-21 Ralf Corsepius - - * .cvsignore: Reformat. - Add autom4te*cache. - Remove autom4te.cache. - -2002-04-01 Ralf Corsepius - - * configure.ac: Remove AC_EXEEXT (obsolete). - -2002-03-27 Ralf Corsepius - - * configure.ac: - AC_INIT(package,_RTEMS_VERSION,_RTEMS_BUGS). - AM_INIT_AUTOMAKE([no-define foreign 1.6]). - * Makefile.am: Remove AUTOMAKE_OPTIONS. - -2001-10-11 Ralf Corsepius - - * .cvsignore: Add autom4te.cache for autoconf > 2.52. - * configure.in: Remove. - * configure.ac: New file, generated from configure.in by autoupdate. - -2001-02-02 Ralf Corsepius - - * .cvsignore: Add stamp-h - -2001-01-24 Ralf Corsepius - - * config.h.in: Automatically generated. Remove from CVS. - -2000-11-09 Ralf Corsepius - - * Makefile.am: Use ... instead of RTEMS_TOPdir in ACLOCAL_AMFLAGS. - -2000-11-02 Ralf Corsepius - - * Makefile.am: Switch to ACLOCAL_AMFLAGS = -I $(RTEMS_TOPdir)/aclocal. - -2000-10-27 Ralf Corsepius - - * Makefile.am: ACLOCAL_AMFLAGS= -I $(RTEMS_TOPdir)/macros. - Switch to GNU canonicalization. - -2000-08-10 Joel Sherrill - - * ChangeLog: New file. diff --git a/c/src/lib/libbsp/hppa1.1/simhppa/tools/Makefile.am b/c/src/lib/libbsp/hppa1.1/simhppa/tools/Makefile.am deleted file mode 100644 index a5caaa371f..0000000000 --- a/c/src/lib/libbsp/hppa1.1/simhppa/tools/Makefile.am +++ /dev/null @@ -1,16 +0,0 @@ -## -## $Id$ -## - -ACLOCAL_AMFLAGS = -I ../../../../../aclocal - -noinst_PROGRAMS = print_dump - -print_dump_SOURCES = print_dump.c - -## HACK: install to build-tree -install-exec-local: $(PROGRAMS) - $(mkinstalldirs) $(PROJECT_ROOT)/simhppa/bin - $(INSTALL_PROGRAM) print_dump $(PROJECT_ROOT)/simhppa/bin - -include $(top_srcdir)/../../../../../automake/local.am diff --git a/c/src/lib/libbsp/hppa1.1/simhppa/tools/configure.ac b/c/src/lib/libbsp/hppa1.1/simhppa/tools/configure.ac deleted file mode 100644 index b60a2a31f0..0000000000 --- a/c/src/lib/libbsp/hppa1.1/simhppa/tools/configure.ac +++ /dev/null @@ -1,25 +0,0 @@ -## Process this file with autoconf to produce a configure script. -## -## $Id$ - -AC_PREREQ(2.57) -AC_INIT([rtems-c-src-lib-libbsp-hppa1.1-simhppa-tools],[_RTEMS_VERSION],[rtems-bugs@rtems.com]) -AC_CONFIG_SRCDIR([print_dump.c]) -RTEMS_TOP(../../../../../../..) - -RTEMS_CANONICAL_TARGET_CPU - -AM_INIT_AUTOMAKE([no-define foreign 1.7.2]) -AM_MAINTAINER_MODE - -AC_PROG_CC - -AC_CHECK_FUNCS(strerror) -AM_CONFIG_HEADER(config.h) - -RTEMS_PROJECT_ROOT -RTEMS_TOOLPATHS - -# Explicitly list all Makefiles here -AC_CONFIG_FILES([Makefile]) -AC_OUTPUT diff --git a/c/src/lib/libbsp/hppa1.1/simhppa/tools/print_dump.c b/c/src/lib/libbsp/hppa1.1/simhppa/tools/print_dump.c deleted file mode 100644 index a9101bed9b..0000000000 --- a/c/src/lib/libbsp/hppa1.1/simhppa/tools/print_dump.c +++ /dev/null @@ -1,338 +0,0 @@ -/* - * print_dump - * - * COPYRIGHT (c) 1994 by Division Incorporated - * - * The license and distribution terms for this file may be - * found in the file LICENSE in this distribution or at - * http://www.rtems.com/license/LICENSE. - * - * $Id$ - */ - -#define GETOPTARGS "v" - -char *USAGE = "\ -usage: print_dump [ -v ] \n\ - -v -- verbose\n\ - Reads HP simulator 'memdump' output of 'print_buffer' structure - on stdin. Dumps it out in vanilla ASCII. -"; - -#include -#include -#include -#include -#include -#include -#include -#include - -#include "config.h" - -#ifndef VMS -#ifndef HAVE_STRERROR -#if defined(__linux__) && (__GLIBC__ < 2) -extern char *sys_errlist[]; -#endif - -#define strerror( _err ) \ - ((_err) < sys_nerr) ? sys_errlist [(_err)] : "unknown error" - -#else /* HAVE_STRERROR */ -char *strerror (); -#endif -#else /* VMS */ -char *strerror (int,...); -#endif - -#define Failed(x) (((int) (x)) == -1) -#define TRUE 1 -#define FALSE 0 -#define STREQ(a,b) (strcmp(a,b) == 0) -#define NUMELEMS(arr) (sizeof(arr) / sizeof(arr[0])) - -/* - * Definitions for unsigned "ints"; especially for use in data structures - * that will be shared among (potentially) different cpu's (we punt on - * byte ordering problems tho) - */ - -typedef unsigned char u8; -typedef unsigned short u16; -typedef unsigned int u32; - -typedef union uval { - u8 uv_chars[4]; - u16 uv_words[2]; - u32 uv_long; - void *uv_ptr[sizeof(long) / sizeof(void *)]; -} uval_t; - - -/* - * vars controlled by command line options - */ - -int verbose = FALSE; /* be verbose */ - -extern char *optarg; /* getopt(3) control vars */ -extern int optind, opterr; -extern int errno; - -char *progname; /* for error() */ - -void error(int errn, ...); - -#define ERR_ERRNO (1<<((sizeof(int) * 8) - 2)) /* hi bit; use 'errno' */ -#define ERR_FATAL (ERR_ERRNO / 2) /* error is fatal; no return */ -#define ERR_ABORT (ERR_ERRNO / 4) /* error is fatal; abort */ -#define ERR_MASK (ERR_ERRNO | ERR_FATAL | ERR_ABORT) /* all */ - -int process(void); -void prchar(unsigned int ch); - - -int -main(int argc, char **argv, char **env) -{ - register int c; - int showusage = FALSE; /* usage error? */ - - /* - * figure out invocation leaf-name - */ - - if ((progname = strrchr(argv[0], '/')) == (char *) NULL) - progname = argv[0]; - else - progname++; - - argv[0] = progname; /* for getopt err reporting */ - - /* - * Check options and arguments. - */ - - opterr = 0; /* we'll report all errors */ - while ((c = getopt(argc, argv, GETOPTARGS)) != EOF) - switch (c) - { - case 'v': /* toggle verbose */ - verbose = ! verbose; - break; - - case '?': - showusage = TRUE; - } - - if (showusage) - { - (void) fprintf(stderr, "%s", USAGE); - exit(1); - } - - return process(); -} - - -/* - * process(arg) - * - * Input looks like this - * - * Starting address: 00000001.480035a0 - * ----------------------------------- - -+0000 / 0d0a0d0a 2a2a2a20 53454d20 54455354 202d2d20 4e4f4445 2032202a 2a2a0d0a -+0020 / 73703a20 30783433 30303030 31300d0a 30783438 30613161 38383a20 676f7420 - .... -+0b40 / xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx - - * - * The 'xxxxxxxxx' shows up if the page has not been allocated. - */ - -int -process(void) -{ - uval_t b[8]; - u32 ignore; - char *p; - int i; - int failed_once; - - char line[1024]; - -#define PRINT_BUFFER_SIZE (16 * 1024) - struct { - int index; - int size; - u8 buffer[PRINT_BUFFER_SIZE]; - } print_buffer; - - /* we stuff the data into print_buffer using memcpy() */ - p = (char *) &print_buffer; - - failed_once = 0; - - while (gets(line)) - { - char *cp; - - /* hack; deal with the 'xxxxxxxx' problem noted above */ - for (cp=line; *cp; cp++) - if (*cp == 'x') - *cp = '0'; - - if (*line != '+') - continue; - if (sscanf(line, "+%x / %x %x %x %x %x %x %x %x\n", - &ignore, - &b[0].uv_long, - &b[1].uv_long, - &b[2].uv_long, - &b[3].uv_long, - &b[4].uv_long, - &b[5].uv_long, - &b[6].uv_long, - &b[7].uv_long) != 9) - { - if (failed_once) - error(ERR_FATAL, "2nd format problem; giving up"); - error(0, "format problem in line: `%s`", line); - failed_once = 1; - } - - memcpy((void *) p, (void *) b, sizeof(b)); - p += sizeof(b); - } - - if (verbose) - printf("buffer size: %d\n", print_buffer.size); - - if (print_buffer.size < 0) - error(ERR_FATAL, "size is too small"); - - if (print_buffer.size != sizeof(print_buffer.buffer)) - { - error(ERR_FATAL, "buffer size mismatch, expected %d", - sizeof(print_buffer.buffer)); - /* XXX we really should just dynamically allocate the buffer */ - } - - i = print_buffer.index + 1; - while (i != print_buffer.index) - { - unsigned int c; - c = print_buffer.buffer[i++]; - if (c && (c != '\r')) - prchar(c); - i %= print_buffer.size; - } - printf("\n"); - return 0; -} - -/* de-controlify */ -char *de_control[] = { - "^@", "^A", "^B", "^C", "^D", "^E", "^F", "^G", "^H", "^I", "^J", "^K", - "^L", "^M", "^N", "^O", "^P", "^Q", "^R", "^S", "^T", "^U", "^V", "^W", - "^X", "^Y", "^Z", "^[", "^\\", "^]", "^~", "^_", - " ", "!", "\"", "#", "$", "%", "&", "'", "(", ")", "*", "+", ",", "-", - ".", "/", "0", "1", "2", "3", "4", "5", "6", "7", "8", "9", ":", ";", - "<", "=", ">", "?", "@", "A", "B", "C", "D", "E", "F", "G", "H", "I", - "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", - "X", "Y", "Z", "[", "\\", "]", "^", "_", "`", "a", "b", "c", "d", "e", - "f", "g", "h", "i", "j", "k", "l", "m", "n", "o", "p", "q", "r", "s", - "t", "u", "v", "w", "x", "y", "z", "{", "|", "}", "~", "^?", - "M-^@", "M-^A", "M-^B", "M-^C", "M-^D", "M-^E", "M-^F", "M-^G", - "M-^H", "M-^I", "M-^J", "M-^K", "M-^L", "M-^M", "M-^N", "M-^O", - "M-^P", "M-^Q", "M-^R", "M-^S", "M-^T", "M-^U", "M-^V", "M-^W", - "M-^X", "M-^Y", "M-^Z", "M-^[", "M-^\\", "M-^]", "M-^~", "M-^_", - "M- ", "M-!", "M-\"", "M-#", "M-$", "M-%", "M-&", "M-'", - "M-(", "M-)", "M-*", "M-+", "M-,", "M--", "M-.", "M-/", - "M-0", "M-1", "M-2", "M-3", "M-4", "M-5", "M-6", "M-7", - "M-8", "M-9", "M-:", "M-;", "M-<", "M-=", "M->", "M-?", - "M-@", "M-A", "M-B", "M-C", "M-D", "M-E", "M-F", "M-G", - "M-H", "M-I", "M-J", "M-K", "M-L", "M-M", "M-N", "M-O", - "M-P", "M-Q", "M-R", "M-S", "M-T", "M-U", "M-V", "M-W", - "M-X", "M-Y", "M-Z", "M-[", "M-\\", "M-]", "M-^", "M-_", - "M-`", "M-a", "M-b", "M-c", "M-d", "M-e", "M-f", "M-g", - "M-h", "M-i", "M-j", "M-k", "M-l", "M-m", "M-n", "M-o", - "M-p", "M-q", "M-r", "M-s", "M-t", "M-u", "M-v", "M-w", - "M-x", "M-y", "M-z", "M-{", "M-|", "M-}", "M-~", "M-^?" -}; - -/* - * prchar(ch); print ch in a readable format, ie ^X or X or ~^X or DEL, etc. - */ - -void -prchar(unsigned int ch) -{ - if (isprint(ch) || isspace(ch)) - putchar(ch); - else - printf("%s", de_control[ch]); -} - - -/* - * error(errn, arglist) - * report an error to stderr using printf(3) conventions. - * Any output is preceded by ': ' - * - * Uses ERR_EXIT bit to request exit(errn) - * ERR_ABORT to request abort() - * ERR_ERRNO to indicate use of errno instead of argument. - * - * If resulting 'errn' is non-zero, it is assumed to be an 'errno' and its - * associated error message is appended to the output. - */ - -/*VARARGS*/ - -void -error(int error_flag, ...) -{ - va_list arglist; - register char *format; - int local_errno; - - extern int errno; - - (void) fflush(stdout); /* in case stdout/stderr same */ - - local_errno = error_flag & ~ERR_MASK; - if (error_flag & ERR_ERRNO) /* use errno? */ - local_errno = errno; - - va_start(arglist, error_flag); - format = va_arg(arglist, char *); - (void) fprintf(stderr, "%s: ", progname); - (void) vfprintf(stderr, format, arglist); - va_end(arglist); - - if (local_errno) - (void) fprintf(stderr, " (%s)\n", strerror(local_errno)); - else - (void) fprintf(stderr, "\n"); - - (void) fflush(stderr); - - if (error_flag & (ERR_FATAL | ERR_ABORT)) - { - if (error_flag & ERR_FATAL) - { - error(0, local_errno ? "fatal error, exiting" : "exiting"); - exit(local_errno); - } - else - { - error(0, "fatal error, aborting"); - abort(); - } - } -} - -- cgit v1.2.3