mirror of
https://sourceware.org/git/binutils-gdb.git
synced 2024-11-21 01:12:32 +08:00
2004-11-13 Andrew Cagney <cagney@gnu.org>
* configure.tgt: Delete i[34567]86-*-vxworks*, m68*-netx-*, m68*-*-vxworks*, mips*-*-vxworks*, powerpc-*-vxworks*, and sparc-*-vxworks*. * NEWS: Mention that vxworks was deleted. * config/m68k/tm-vx68.h, config/mips/tm-vxmips.h: Delete. * config/powerpc/tm-vxworks.h, config/tm-vxworks.h: Delete. * config/i386/vxworks.mt, config/m68k/vxworks68.mt: Delete. * config/mips/vxmips.mt, config/powerpc/vxworks.mt: Delete. * config/sparc/vxworks.mt, vx-share/dbgRpcLib.h: Delete. * vx-share/ptrace.h, vx-share/regPacket.h: Delete. * vx-share/vxTypes.h, vx-share/vxWorks.h: Delete. * vx-share/wait.h, vx-share/xdr_ld.c: Delete. * vx-share/xdr_ld.h, vx-share/xdr_ptrace.c: Delete. * vx-share/xdr_ptrace.h, vx-share/xdr_rdb.c: Delete. * vx-share/xdr_rdb.h, remote-vxsparc.c: Delete. * remote-vxmips.c, remote-vx.c: Delete. * remote-vx68.c: Delete. * config/m68k/tm-os68k.h: Remove reference to VxWorks. * config/m68k/os68k.mt, ada-lang.h: Ditto. * Makefile.in (HFILES_NO_SRCDIR, ALLDEPFILES, remote-vx68.o) (remote-vx.o, remote-vxmips.o, remote-vxsparc.o): Delete vx files.
This commit is contained in:
parent
603e93b5b7
commit
e84ecc995d
@ -1,3 +1,27 @@
|
||||
2004-11-13 Andrew Cagney <cagney@gnu.org>
|
||||
|
||||
* configure.tgt: Delete i[34567]86-*-vxworks*, m68*-netx-*,
|
||||
m68*-*-vxworks*, mips*-*-vxworks*, powerpc-*-vxworks*, and
|
||||
sparc-*-vxworks*.
|
||||
* NEWS: Mention that vxworks was deleted.
|
||||
* config/m68k/tm-vx68.h, config/mips/tm-vxmips.h: Delete.
|
||||
* config/powerpc/tm-vxworks.h, config/tm-vxworks.h: Delete.
|
||||
* config/i386/vxworks.mt, config/m68k/vxworks68.mt: Delete.
|
||||
* config/mips/vxmips.mt, config/powerpc/vxworks.mt: Delete.
|
||||
* config/sparc/vxworks.mt, vx-share/dbgRpcLib.h: Delete.
|
||||
* vx-share/ptrace.h, vx-share/regPacket.h: Delete.
|
||||
* vx-share/vxTypes.h, vx-share/vxWorks.h: Delete.
|
||||
* vx-share/wait.h, vx-share/xdr_ld.c: Delete.
|
||||
* vx-share/xdr_ld.h, vx-share/xdr_ptrace.c: Delete.
|
||||
* vx-share/xdr_ptrace.h, vx-share/xdr_rdb.c: Delete.
|
||||
* vx-share/xdr_rdb.h, remote-vxsparc.c: Delete.
|
||||
* remote-vxmips.c, remote-vx.c: Delete.
|
||||
* remote-vx68.c: Delete.
|
||||
* config/m68k/tm-os68k.h: Remove reference to VxWorks.
|
||||
* config/m68k/os68k.mt, ada-lang.h: Ditto.
|
||||
* Makefile.in (HFILES_NO_SRCDIR, ALLDEPFILES, remote-vx68.o)
|
||||
(remote-vx.o, remote-vxmips.o, remote-vxsparc.o): Delete vx files.
|
||||
|
||||
2004-11-13 Eli Zaretskii <eliz@gnu.org>
|
||||
|
||||
* config/i386/xm-go32.h: Don't include fopen-bin.h.
|
||||
|
@ -854,9 +854,7 @@ HFILES_NO_SRCDIR = bcache.h buildsym.h call-cmds.h coff-solib.h defs.h \
|
||||
jv-lang.h \
|
||||
m2-lang.h p-lang.h \
|
||||
complaints.h valprint.h \
|
||||
vx-share/dbgRpcLib.h vx-share/ptrace.h vx-share/vxTypes.h \
|
||||
vx-share/vxWorks.h vx-share/wait.h vx-share/xdr_ld.h \
|
||||
vx-share/xdr_ptrace.h vx-share/xdr_rdb.h gdbthread.h \
|
||||
gdbthread.h \
|
||||
dcache.h remote-utils.h top.h somsolib.h
|
||||
|
||||
# Header files that already have srcdir in them, or which are in objdir.
|
||||
@ -1411,7 +1409,6 @@ ALLDEPFILES = \
|
||||
remote-hms.c remote-m32r-sdi.c remote-mips.c \
|
||||
remote-rdp.c remote-sim.c \
|
||||
remote-st.c remote-utils.c dcache.c \
|
||||
remote-vx.c \
|
||||
rs6000-nat.c rs6000-tdep.c \
|
||||
s390-tdep.c s390-nat.c \
|
||||
ser-go32.c ser-pipe.c ser-tcp.c \
|
||||
@ -1425,7 +1422,6 @@ ALLDEPFILES = \
|
||||
sparcnbsd-nat.c sparcnbsd-tdep.c sparcobsd-tdep.c \
|
||||
symm-tdep.c symm-nat.c \
|
||||
vax-nat.c vax-tdep.c vaxbsd-nat.c vaxnbsd-tdep.c \
|
||||
vx-share/xdr_ld.c vx-share/xdr_ptrace.c vx-share/xdr_rdb.c \
|
||||
win32-nat.c \
|
||||
xcoffread.c xcoffsolib.c \
|
||||
xstormy16-tdep.c
|
||||
@ -2421,23 +2417,6 @@ remote-st.o: remote-st.c $(defs_h) $(gdbcore_h) $(target_h) $(gdb_string_h) \
|
||||
remote-utils.o: remote-utils.c $(defs_h) $(gdb_string_h) $(gdbcmd_h) \
|
||||
$(target_h) $(serial_h) $(gdbcore_h) $(inferior_h) $(remote_utils_h) \
|
||||
$(regcache_h)
|
||||
remote-vx68.o: remote-vx68.c $(defs_h) $(vx_share_regPacket_h) $(frame_h) \
|
||||
$(inferior_h) $(target_h) $(gdbcore_h) $(command_h) $(symtab_h) \
|
||||
$(symfile_h) $(regcache_h) $(gdb_string_h) $(vx_share_ptrace_h) \
|
||||
$(vx_share_xdr_ptrace_h) $(vx_share_xdr_ld_h) $(vx_share_xdr_rdb_h) \
|
||||
$(vx_share_dbgRpcLib_h)
|
||||
remote-vx.o: remote-vx.c $(defs_h) $(frame_h) $(inferior_h) $(target_h) \
|
||||
$(gdbcore_h) $(command_h) $(symtab_h) $(complaints_h) $(gdbcmd_h) \
|
||||
$(bfd_h) $(symfile_h) $(objfiles_h) $(gdb_stabs_h) $(regcache_h) \
|
||||
$(gdb_string_h) $(vx_share_ptrace_h) $(vx_share_xdr_ptrace_h) \
|
||||
$(vx_share_xdr_ld_h) $(vx_share_xdr_rdb_h) $(vx_share_dbgRpcLib_h)
|
||||
remote-vxmips.o: remote-vxmips.c $(defs_h) $(vx_share_regPacket_h) \
|
||||
$(frame_h) $(inferior_h) $(target_h) $(gdbcore_h) $(command_h) \
|
||||
$(symtab_h) $(symfile_h) $(regcache_h) $(gdb_string_h) \
|
||||
$(vx_share_ptrace_h) $(vx_share_xdr_ptrace_h) $(vx_share_xdr_ld_h) \
|
||||
$(vx_share_xdr_rdb_h) $(vx_share_dbgRpcLib_h)
|
||||
remote-vxsparc.o: remote-vxsparc.c $(defs_h) $(regcache_h) $(gdb_string_h) \
|
||||
$(sparc_tdep_h) $(vx_share_ptrace_h) $(vx_share_regPacket_h)
|
||||
rom68k-rom.o: rom68k-rom.c $(defs_h) $(gdbcore_h) $(target_h) $(monitor_h) \
|
||||
$(serial_h) $(regcache_h) $(value_h) $(m68k_tdep_h)
|
||||
rs6000-nat.o: rs6000-nat.c $(defs_h) $(inferior_h) $(target_h) $(gdbcore_h) \
|
||||
@ -3089,20 +3068,4 @@ tui-winsource.o: $(srcdir)/tui/tui-winsource.c $(defs_h) $(symtab_h) \
|
||||
$(gdb_curses_h)
|
||||
$(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/tui/tui-winsource.c
|
||||
|
||||
#
|
||||
# vx-share sub-directory
|
||||
#
|
||||
|
||||
xdr_ld.o: vx-share/xdr_ld.c $(defs_h) vx-share/vxTypes.h \
|
||||
vx-share/vxWorks.h vx-share/xdr_ld.h
|
||||
$(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/vx-share/xdr_ld.c
|
||||
|
||||
xdr_ptrace.o: vx-share/xdr_ptrace.c $(defs_h) vx-share/vxTypes.h \
|
||||
vx-share/vxWorks.h vx-share/xdr_ptrace.h
|
||||
$(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/vx-share/xdr_ptrace.c
|
||||
|
||||
xdr_rdb.o: vx-share/xdr_rdb.c $(defs_h) vx-share/vxTypes.h \
|
||||
vx-share/vxWorks.h vx-share/xdr_rdb.h
|
||||
$(CC) -c $(INTERNAL_CFLAGS) $(srcdir)/vx-share/xdr_rdb.c
|
||||
|
||||
### end of the gdb Makefile.in.
|
||||
|
3
gdb/NEWS
3
gdb/NEWS
@ -3,6 +3,9 @@
|
||||
|
||||
*** Changes since GDB 6.3
|
||||
|
||||
* REMOVED configurations and files
|
||||
|
||||
VxWorks and the XDR protocol *-*-vxworks
|
||||
|
||||
*** Changes in GDB 6.3:
|
||||
|
||||
|
@ -32,7 +32,7 @@ struct frame_info;
|
||||
system and that might consider (confusing) debugging information.
|
||||
Each name (a basic regular expression string) is followed by a
|
||||
comma. FIXME: Should be part of a configuration file. */
|
||||
#if defined(__alpha__) && defined(__osf__) && !defined(VXWORKS_TARGET)
|
||||
#if defined(__alpha__) && defined(__osf__)
|
||||
#define ADA_KNOWN_RUNTIME_FILE_NAME_PATTERNS \
|
||||
"^[agis]-.*\\.ad[bs]$", \
|
||||
"/usr/shlib/libpthread\\.so",
|
||||
|
@ -1,3 +0,0 @@
|
||||
# Target: i386 running VxWorks
|
||||
TDEPFILES= i386-tdep.o i387-tdep.o
|
||||
DEPRECATED_TM_FILE= config/tm-vxworks.h
|
@ -1,3 +1,3 @@
|
||||
# Target: VxWorks running on a 68000
|
||||
# Target: os68k running on a 68000
|
||||
TDEPFILES= m68k-tdep.o
|
||||
DEPRECATED_TM_FILE= tm-os68k.h
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* Parameters for execution on VxWorks m68k's, for GDB, the GNU debugger.
|
||||
/* Parameters for execution on os68k's, for GDB, the GNU debugger.
|
||||
Copyright 1986, 1987, 1989, 1991, 1998, 2003 Free Software Foundation, Inc.
|
||||
Contributed by Cygnus Support.
|
||||
|
||||
|
@ -1,65 +0,0 @@
|
||||
/* Target machine description for VxWorks m68k's, for GDB, the GNU debugger.
|
||||
Copyright 1986, 1987, 1989, 1991, 1992, 1993, 1996, 1998, 1999, 2000,
|
||||
2002, 2003
|
||||
Free Software Foundation, Inc.
|
||||
Contributed by Cygnus Support.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
/* GCC is probably the only compiler used on this configuration. So
|
||||
get this right even if the code which detects gcc2_compiled. is
|
||||
still broken. */
|
||||
|
||||
#define BELIEVE_PCC_PROMOTION 1
|
||||
|
||||
/* We have more complex, useful breakpoints on the target. */
|
||||
#define DECR_PC_AFTER_BREAK 0
|
||||
|
||||
#include "config/tm-vxworks.h"
|
||||
|
||||
/* Takes the current frame-struct pointer and returns the chain-pointer
|
||||
to get to the calling frame.
|
||||
|
||||
If our current frame pointer is zero, we're at the top; else read out
|
||||
the saved FP from memory pointed to by the current FP. */
|
||||
|
||||
#undef DEPRECATED_FRAME_CHAIN
|
||||
#define DEPRECATED_FRAME_CHAIN(thisframe) ((thisframe)->frame? read_memory_integer ((thisframe)->frame, 4): 0)
|
||||
|
||||
/* FIXME, Longjmp information stolen from Sun-3 config. Dunno if right. */
|
||||
/* Offsets (in target ints) into jmp_buf. Not defined by Sun, but at least
|
||||
documented in a comment in <machine/setjmp.h>! */
|
||||
|
||||
#define JB_ELEMENT_SIZE 4
|
||||
|
||||
#define JB_ONSSTACK 0
|
||||
#define JB_SIGMASK 1
|
||||
#define JB_SP 2
|
||||
#define JB_PC 3
|
||||
#define JB_PSL 4
|
||||
#define JB_D2 5
|
||||
#define JB_D3 6
|
||||
#define JB_D4 7
|
||||
#define JB_D5 8
|
||||
#define JB_D6 9
|
||||
#define JB_D7 10
|
||||
#define JB_A2 11
|
||||
#define JB_A3 12
|
||||
#define JB_A4 13
|
||||
#define JB_A5 14
|
||||
#define JB_A6 15
|
@ -1,3 +0,0 @@
|
||||
# Target: Motorola m68k running VxWorks
|
||||
TDEPFILES= m68k-tdep.o remote-vx.o remote-vx68.o xdr_ld.o xdr_ptrace.o xdr_rdb.o
|
||||
DEPRECATED_TM_FILE= tm-vx68.h
|
@ -1,22 +0,0 @@
|
||||
/* Target machine description for VxWorks MIPS's, for GDB, the GNU debugger.
|
||||
Copyright 1996, 1999 Free Software Foundation, Inc.
|
||||
Contributed by Cygnus Support.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
#include "config/tm-vxworks.h"
|
@ -1,3 +0,0 @@
|
||||
# Target: MIPS running VxWorks
|
||||
TDEPFILES= mips-tdep.o remote-vx.o remote-vxmips.o xdr_ld.o xdr_ptrace.o xdr_rdb.o
|
||||
DEPRECATED_TM_FILE= tm-vxmips.h
|
@ -1,28 +0,0 @@
|
||||
/* Target machine description for VxWorks on the PowerPC,
|
||||
for GDB, the GNU debugger.
|
||||
Copyright 1999 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
#ifndef TM_VXWORKS_H
|
||||
#define TM_VXWORKS_H
|
||||
|
||||
#include "powerpc/tm-ppc-eabi.h"
|
||||
#include "config/tm-vxworks.h"
|
||||
|
||||
#endif /* ifndef TM_VXWORKS_H */
|
@ -1,3 +0,0 @@
|
||||
# Target: Powerpc running VxWorks
|
||||
TDEPFILES= rs6000-tdep.o ppc-sysv-tdep.o solib.o solib-svr4.o
|
||||
DEPRECATED_TM_FILE= tm-vxworks.h
|
@ -1,4 +0,0 @@
|
||||
# Target: VxWorks SPARC
|
||||
TDEPFILES= sparc-tdep.o \
|
||||
remote-vx.o remote-vxsparc.o xdr_ld.o xdr_ptrace.o xdr_rdb.o
|
||||
DEPRECATED_TM_FILE= config/tm-vxworks.h
|
@ -1,23 +0,0 @@
|
||||
/* Target machine description for VxWorks, for GDB, the GNU debugger.
|
||||
Copyright 1999 Free Software Foundation, Inc.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
#define GDBINIT_FILENAME ".vxgdbinit"
|
||||
|
||||
#define DEFAULT_PROMPT "(vxgdb) "
|
@ -98,7 +98,6 @@ i[34567]86-*-gnu*) gdb_target=i386gnu ;;
|
||||
i[34567]86-*-netware*) gdb_target=i386
|
||||
configdirs="${configdirs} nlm" ;;
|
||||
i[34567]86-*-cygwin*) gdb_target=cygwin ;;
|
||||
i[34567]86-*-vxworks*) gdb_target=vxworks ;;
|
||||
i[34567]86-*-*) gdb_target=i386 ;;
|
||||
|
||||
ia64-*-aix*) gdb_target=aix ;;
|
||||
@ -113,7 +112,6 @@ m32r*-*-*) gdb_target=m32r ;;
|
||||
m68hc11*-*-*|m6811*-*-*) gdb_target=m68hc11 ;;
|
||||
|
||||
m68*-cisco*-*) gdb_target=cisco ;;
|
||||
m68*-netx-*) gdb_target=vxworks68 ;;
|
||||
m68*-tandem-*) gdb_target=st2000 ;;
|
||||
m68*-*-aout*) gdb_target=monitor ;;
|
||||
m68*-*-coff*) gdb_target=monitor ;;
|
||||
@ -126,7 +124,6 @@ m68*-*-netbsd* | m68*-*-knetbsd*-gnu)
|
||||
m68*-*-openbsd*) gdb_target=obsd ;;
|
||||
m68*-*-os68k*) gdb_target=os68k ;;
|
||||
m68*-*-uclinux*) gdb_target=monitor ;;
|
||||
m68*-*-vxworks*) gdb_target=vxworks68 ;;
|
||||
|
||||
m88*-*-openbsd*) gdb_target=obsd ;;
|
||||
|
||||
@ -141,7 +138,6 @@ mips*-*-linux*) gdb_target=linux
|
||||
mips*-*-netbsd* | mips*-*-knetbsd*-gnu)
|
||||
gdb_target=nbsd ;;
|
||||
mips64*-*-openbsd*) gdb_target=obsd64 ;;
|
||||
mips*-*-vxworks*) gdb_target=vxmips ;;
|
||||
mips*-*-*) gdb_target=embed ;;
|
||||
|
||||
mn10300-*-*) gdb_target=mn10300 ;;
|
||||
@ -156,7 +152,6 @@ powerpc-*-linux*) gdb_target=linux
|
||||
build_gdbserver=yes
|
||||
;;
|
||||
powerpc64-*-linux*) gdb_target=linux ;;
|
||||
powerpc-*-vxworks*) gdb_target=vxworks ;;
|
||||
powerpc*-*-*) if test -f ../sim/ppc/Makefile; then
|
||||
gdb_target=ppc-sim
|
||||
else
|
||||
@ -197,7 +192,6 @@ sparc-*-solaris2.[0-6] | sparc-*-solaris2.[0-6].*)
|
||||
sparc-*-solaris2* | sparcv9-*-solaris2* | sparc64-*-solaris2*)
|
||||
gdb_target=sol2-64
|
||||
;;
|
||||
sparc-*-vxworks*) gdb_target=vxworks ;;
|
||||
sparc-*-*) gdb_target=sparc ;;
|
||||
sparc64-*-*) gdb_target=sparc64 ;;
|
||||
|
||||
|
1401
gdb/remote-vx.c
1401
gdb/remote-vx.c
File diff suppressed because it is too large
Load Diff
@ -1,163 +0,0 @@
|
||||
/* 68k-dependent portions of the RPC protocol
|
||||
used with a VxWorks target
|
||||
|
||||
Contributed by Wind River Systems.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
#include <stdio.h>
|
||||
#include "defs.h"
|
||||
|
||||
#include "vx-share/regPacket.h"
|
||||
#include "frame.h"
|
||||
#include "inferior.h"
|
||||
#include "target.h"
|
||||
#include "gdbcore.h"
|
||||
#include "command.h"
|
||||
#include "symtab.h"
|
||||
#include "symfile.h"
|
||||
#include "regcache.h"
|
||||
|
||||
#include "gdb_string.h"
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/socket.h>
|
||||
|
||||
#ifdef _AIX /* IBM claims "void *malloc()" not char * */
|
||||
#define malloc bogon_malloc
|
||||
#endif
|
||||
|
||||
#include <rpc/rpc.h>
|
||||
|
||||
#ifdef _AIX
|
||||
#undef malloc
|
||||
#endif
|
||||
|
||||
#include <sys/time.h> /* UTek's <rpc/rpc.h> doesn't #incl this */
|
||||
#include <netdb.h>
|
||||
#include "vx-share/ptrace.h"
|
||||
#include "vx-share/xdr_ptrace.h"
|
||||
#include "vx-share/xdr_ld.h"
|
||||
#include "vx-share/xdr_rdb.h"
|
||||
#include "vx-share/dbgRpcLib.h"
|
||||
|
||||
/* get rid of value.h if possible */
|
||||
#include <value.h>
|
||||
#include <symtab.h>
|
||||
|
||||
/* Flag set if target has fpu */
|
||||
|
||||
extern int target_has_fp;
|
||||
|
||||
/* Generic register read/write routines in remote-vx.c. */
|
||||
|
||||
extern void net_read_registers ();
|
||||
extern void net_write_registers ();
|
||||
|
||||
/* Read a register or registers from the VxWorks target.
|
||||
REGNO is the register to read, or -1 for all; currently,
|
||||
it is ignored. FIXME look at regno to improve efficiency. */
|
||||
|
||||
void
|
||||
vx_read_register (int regno)
|
||||
{
|
||||
char mc68k_greg_packet[MC68K_GREG_PLEN];
|
||||
char mc68k_fpreg_packet[MC68K_FPREG_PLEN];
|
||||
|
||||
/* Get general-purpose registers. */
|
||||
|
||||
net_read_registers (mc68k_greg_packet, MC68K_GREG_PLEN, PTRACE_GETREGS);
|
||||
|
||||
memcpy (deprecated_registers,
|
||||
&mc68k_greg_packet[MC68K_R_D0]
|
||||
16 * MC68K_GREG_SIZE);
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (PS_REGNUM)],
|
||||
&mc68k_greg_packet[MC68K_R_SR],
|
||||
MC68K_GREG_SIZE);
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (PC_REGNUM)],
|
||||
&mc68k_greg_packet[MC68K_R_PC],
|
||||
MC68K_GREG_SIZE);
|
||||
|
||||
/* Get floating-point registers, if the target system has them.
|
||||
Otherwise, zero them. */
|
||||
|
||||
if (target_has_fp)
|
||||
{
|
||||
net_read_registers (mc68k_fpreg_packet, MC68K_FPREG_PLEN,
|
||||
PTRACE_GETFPREGS);
|
||||
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FP0_REGNUM)],
|
||||
&mc68k_fpreg_packet[MC68K_R_FP0],
|
||||
MC68K_FPREG_SIZE * 8);
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FPC_REGNUM)],
|
||||
&mc68k_fpreg_packet[MC68K_R_FPCR],
|
||||
MC68K_FPREG_PLEN - (MC68K_FPREG_SIZE * 8));
|
||||
}
|
||||
else
|
||||
{
|
||||
memset (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FP0_REGNUM)],
|
||||
0, MC68K_FPREG_SIZE * 8);
|
||||
memset (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FPC_REGNUM)],
|
||||
0, MC68K_FPREG_PLEN - (MC68K_FPREG_SIZE * 8));
|
||||
}
|
||||
|
||||
/* Mark the register cache valid. */
|
||||
|
||||
deprecated_registers_fetched ();
|
||||
}
|
||||
|
||||
/* Store a register or registers into the VxWorks target.
|
||||
REGNO is the register to store, or -1 for all; currently,
|
||||
it is ignored. FIXME look at regno to improve efficiency. */
|
||||
|
||||
void
|
||||
vx_write_register (int regno)
|
||||
{
|
||||
char mc68k_greg_packet[MC68K_GREG_PLEN];
|
||||
char mc68k_fpreg_packet[MC68K_FPREG_PLEN];
|
||||
|
||||
/* Store general-purpose registers. */
|
||||
|
||||
memcpy (&mc68k_greg_packet[MC68K_R_D0], deprecated_registers,
|
||||
16 * MC68K_GREG_SIZE);
|
||||
memcpy (&mc68k_greg_packet[MC68K_R_SR],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (PS_REGNUM)],
|
||||
MC68K_GREG_SIZE);
|
||||
memcpy (&mc68k_greg_packet[MC68K_R_PC],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (PC_REGNUM)],
|
||||
MC68K_GREG_SIZE);
|
||||
|
||||
net_write_registers (mc68k_greg_packet, MC68K_GREG_PLEN, PTRACE_SETREGS);
|
||||
|
||||
/* Store floating point registers if the target has them. */
|
||||
|
||||
if (target_has_fp)
|
||||
{
|
||||
memcpy (&mc68k_fpreg_packet[MC68K_R_FP0],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (FP0_REGNUM)],
|
||||
MC68K_FPREG_SIZE * 8);
|
||||
memcpy (&mc68k_fpreg_packet[MC68K_R_FPCR],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (FPC_REGNUM)],
|
||||
MC68K_FPREG_PLEN - (MC68K_FPREG_SIZE * 8));
|
||||
|
||||
net_write_registers (mc68k_fpreg_packet, MC68K_FPREG_PLEN,
|
||||
PTRACE_SETFPREGS);
|
||||
}
|
||||
}
|
@ -1,209 +0,0 @@
|
||||
/* MIPS-dependent portions of the RPC protocol
|
||||
used with a VxWorks target
|
||||
|
||||
Contributed by Wind River Systems.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
#include <stdio.h>
|
||||
#include "defs.h"
|
||||
|
||||
#include "vx-share/regPacket.h"
|
||||
#include "frame.h"
|
||||
#include "inferior.h"
|
||||
#include "target.h"
|
||||
#include "gdbcore.h"
|
||||
#include "command.h"
|
||||
#include "symtab.h"
|
||||
#include "symfile.h"
|
||||
#include "regcache.h"
|
||||
|
||||
#include "gdb_string.h"
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/socket.h>
|
||||
#include <rpc/rpc.h>
|
||||
#include <sys/time.h> /* UTek's <rpc/rpc.h> doesn't #incl this */
|
||||
#include <netdb.h>
|
||||
#include "vx-share/ptrace.h"
|
||||
#include "vx-share/xdr_ptrace.h"
|
||||
#include "vx-share/xdr_ld.h"
|
||||
#include "vx-share/xdr_rdb.h"
|
||||
#include "vx-share/dbgRpcLib.h"
|
||||
|
||||
/* get rid of value.h if possible */
|
||||
#include <value.h>
|
||||
#include <symtab.h>
|
||||
|
||||
/* Flag set if target has fpu */
|
||||
|
||||
extern int target_has_fp;
|
||||
|
||||
/* Generic register read/write routines in remote-vx.c. */
|
||||
|
||||
extern void net_read_registers ();
|
||||
extern void net_write_registers ();
|
||||
|
||||
/* Read a register or registers from the VxWorks target.
|
||||
REGNO is the register to read, or -1 for all; currently,
|
||||
it is ignored. FIXME look at regno to improve efficiency. */
|
||||
|
||||
void
|
||||
vx_read_register (int regno)
|
||||
{
|
||||
char mips_greg_packet[MIPS_GREG_PLEN];
|
||||
char mips_fpreg_packet[MIPS_FPREG_PLEN];
|
||||
|
||||
/* Get general-purpose registers. */
|
||||
|
||||
net_read_registers (mips_greg_packet, MIPS_GREG_PLEN, PTRACE_GETREGS);
|
||||
|
||||
/* this code copies the registers obtained by RPC
|
||||
stored in a structure(s) like this :
|
||||
|
||||
Register(s) Offset(s)
|
||||
gp 0-31 0x00
|
||||
hi 0x80
|
||||
lo 0x84
|
||||
sr 0x88
|
||||
pc 0x8c
|
||||
|
||||
into a stucture like this:
|
||||
|
||||
0x00 GP 0-31
|
||||
0x80 SR
|
||||
0x84 LO
|
||||
0x88 HI
|
||||
0x8C BAD --- Not available currently
|
||||
0x90 CAUSE --- Not available currently
|
||||
0x94 PC
|
||||
0x98 FP 0-31
|
||||
0x118 FCSR
|
||||
0x11C FIR --- Not available currently
|
||||
0x120 FP --- Not available currently
|
||||
|
||||
structure is 0x124 (292) bytes in length */
|
||||
|
||||
/* Copy the general registers. */
|
||||
|
||||
memcpy (&deprecated_registers[0], &mips_greg_packet[MIPS_R_GP0],
|
||||
32 * MIPS_GREG_SIZE);
|
||||
|
||||
/* Copy SR, LO, HI, and PC. */
|
||||
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (MIPS_PS_REGNUM)],
|
||||
&mips_greg_packet[MIPS_R_SR],
|
||||
MIPS_GREG_SIZE);
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (mips_regnum (current_gdbarch)->lo)],
|
||||
&mips_greg_packet[MIPS_R_LO],
|
||||
MIPS_GREG_SIZE);
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (mips_regnum (current_gdbarch)->hi)],
|
||||
&mips_greg_packet[MIPS_R_HI],
|
||||
MIPS_GREG_SIZE);
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (mips_regnum (current_gdbarch)->pc)],
|
||||
&mips_greg_packet[MIPS_R_PC],
|
||||
MIPS_GREG_SIZE);
|
||||
|
||||
/* If the target has floating point registers, fetch them.
|
||||
Otherwise, zero the floating point register values in
|
||||
registers[] for good measure, even though we might not
|
||||
need to. */
|
||||
|
||||
if (target_has_fp)
|
||||
{
|
||||
net_read_registers (mips_fpreg_packet, MIPS_FPREG_PLEN,
|
||||
PTRACE_GETFPREGS);
|
||||
|
||||
/* Copy the floating point registers. */
|
||||
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FP0_REGNUM)],
|
||||
&mips_fpreg_packet[MIPS_R_FP0],
|
||||
register_size (current_gdbarch, FP0_REGNUM) * 32);
|
||||
|
||||
/* Copy the floating point control/status register (fpcsr). */
|
||||
|
||||
memcpy (&deprecated_registers[DEPRECATED_REGISTER_BYTE (mips_regnum (current_gdbarch)->fp_control_status)],
|
||||
&mips_fpreg_packet[MIPS_R_FPCSR],
|
||||
register_size (current_gdbarch, mips_regnum (current_gdbarch)->fp_control_status));
|
||||
}
|
||||
else
|
||||
{
|
||||
memset (&deprecated_registers[DEPRECATED_REGISTER_BYTE (FP0_REGNUM)],
|
||||
0, register_size (current_gdbarch, FP0_REGNUM) * 32);
|
||||
memset (&deprecated_registers[DEPRECATED_REGISTER_BYTE (mips_regnum (current_gdbarch)->fp_control_status)],
|
||||
0, register_size (current_gdbarch, mips_regnum (current_gdbarch)->fp_control_status));
|
||||
}
|
||||
|
||||
/* Mark the register cache valid. */
|
||||
|
||||
deprecated_registers_fetched ();
|
||||
}
|
||||
|
||||
/* Store a register or registers into the VxWorks target.
|
||||
REGNO is the register to store, or -1 for all; currently,
|
||||
it is ignored. FIXME look at regno to improve efficiency. */
|
||||
|
||||
vx_write_register (int regno)
|
||||
{
|
||||
char mips_greg_packet[MIPS_GREG_PLEN];
|
||||
char mips_fpreg_packet[MIPS_FPREG_PLEN];
|
||||
|
||||
/* Store general registers. */
|
||||
|
||||
memcpy (&mips_greg_packet[MIPS_R_GP0], &deprecated_registers[0],
|
||||
32 * MIPS_GREG_SIZE);
|
||||
|
||||
/* Copy SR, LO, HI, and PC. */
|
||||
|
||||
memcpy (&mips_greg_packet[MIPS_R_SR],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (MIPS_PS_REGNUM)],
|
||||
MIPS_GREG_SIZE);
|
||||
memcpy (&mips_greg_packet[MIPS_R_LO],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (mips_regnum (current_gdbarch)->lo)],
|
||||
MIPS_GREG_SIZE);
|
||||
memcpy (&mips_greg_packet[MIPS_R_HI],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (mips_regnum (current_gdbarch)->hi)],
|
||||
MIPS_GREG_SIZE);
|
||||
memcpy (&mips_greg_packet[MIPS_R_PC],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (mips_regnum (current_gdbarch)->pc)],
|
||||
MIPS_GREG_SIZE);
|
||||
|
||||
net_write_registers (mips_greg_packet, MIPS_GREG_PLEN, PTRACE_SETREGS);
|
||||
|
||||
/* Store floating point registers if the target has them. */
|
||||
|
||||
if (target_has_fp)
|
||||
{
|
||||
/* Copy the floating point data registers. */
|
||||
|
||||
memcpy (&mips_fpreg_packet[MIPS_R_FP0],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (FP0_REGNUM)],
|
||||
register_size (current_gdbarch, FP0_REGNUM) * 32);
|
||||
|
||||
/* Copy the floating point control/status register (fpcsr). */
|
||||
|
||||
memcpy (&mips_fpreg_packet[MIPS_R_FPCSR],
|
||||
&deprecated_registers[DEPRECATED_REGISTER_BYTE (mips_regnum (current_gdbarch)->fp_control_status)],
|
||||
register_size (current_gdbarch, mips_regnum (current_gdbarch)->fp_control_status));
|
||||
|
||||
net_write_registers (mips_fpreg_packet, MIPS_FPREG_PLEN,
|
||||
PTRACE_SETFPREGS);
|
||||
}
|
||||
}
|
@ -1,128 +0,0 @@
|
||||
/* SPARC-specific portions of the RPC protocol for VxWorks.
|
||||
|
||||
Contributed by Wind River Systems.
|
||||
|
||||
This file is part of GDB.
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330,
|
||||
Boston, MA 02111-1307, USA. */
|
||||
|
||||
#include "defs.h"
|
||||
#include "regcache.h"
|
||||
|
||||
#include "gdb_string.h"
|
||||
|
||||
#include "sparc-tdep.h"
|
||||
|
||||
#include "vx-share/ptrace.h"
|
||||
#include "vx-share/regPacket.h"
|
||||
|
||||
#define SPARC_R_G1 (SPARC_R_G0 + SPARC_GREG_SIZE)
|
||||
|
||||
const struct sparc_gregset vxsparc_gregset =
|
||||
{
|
||||
SPARC_R_PSR, /* %psr */
|
||||
SPARC_R_PC, /* %pc */
|
||||
SPARC_R_NPC, /* %npc */
|
||||
SPARC_R_Y, /* %y */
|
||||
SPARC_R_WIM, /* %wim */
|
||||
SPARC_R_TBR, /* %tbr */
|
||||
SPARC_R_G1, /* %g1 */
|
||||
SPARC_R_I0 /* %l0 */
|
||||
};
|
||||
|
||||
/* Flag set if target has an FPU. */
|
||||
|
||||
extern int target_has_fp;
|
||||
|
||||
/* Generic register read/write routines in remote-vx.c. */
|
||||
|
||||
extern void net_read_registers ();
|
||||
extern void net_write_registers ();
|
||||
|
||||
/* Read a register or registers from the VxWorks target. REGNUM is
|
||||
the register to read, or -1 for all; currently, it is ignored.
|
||||
FIXME: Look at REGNUM to improve efficiency. */
|
||||
|
||||
void
|
||||
vx_read_register (int regnum)
|
||||
{
|
||||
struct regcache *regcache = current_regcache;
|
||||
char gregs[SPARC_GREG_PLEN];
|
||||
char fpregs[SPARC_FPREG_PLEN];
|
||||
CORE_ADDR sp;
|
||||
|
||||
/* Get the general-purpose registers. */
|
||||
net_read_registers (gregs, SPARC_GREG_PLEN, PTRACE_GETREGS);
|
||||
sparc32_supply_gregset (&vxsparc_gregset, regcache, -1, gregs);
|
||||
|
||||
/* If the target has floating-point registers, fetch them.
|
||||
Otherwise, zero the floating-point register values in GDB's
|
||||
register cache for good measure, even though we might not need
|
||||
to. */
|
||||
if (target_has_fp)
|
||||
net_read_registers (fpregs, SPARC_FPREG_PLEN, PTRACE_GETFPREGS);
|
||||
else
|
||||
memset (fpregs, 0, SPARC_FPREG_PLEN);
|
||||
sparc32_supply_fpregset (regcache, -1, fpregs);
|
||||
}
|
||||
|
||||
/* Store a register or registers into the VxWorks target. REGNUM is
|
||||
the register to store, or -1 for all; currently, it is ignored.
|
||||
FIXME: Look at REGNUM to improve efficiency. */
|
||||
|
||||
void
|
||||
vx_write_register (int regnum)
|
||||
{
|
||||
struct regcache *regcache = current_regcache;
|
||||
char gregs[SPARC_GREG_PLEN];
|
||||
char fpregs[SPARC_FPREG_PLEN];
|
||||
int gregs_p = 1;
|
||||
int fpregs_p = 1;
|
||||
CORE_ADDR sp;
|
||||
|
||||
if (regnum != -1)
|
||||
{
|
||||
if ((SPARC_G0_REGNUM <= regnum && regnum <= SPARC_I7_REGNUM)
|
||||
|| (SPARC32_Y_REGNUM <= regnum && regnum <= SPARC32_NPC_REGNUM))
|
||||
fpregs_p = 0;
|
||||
else
|
||||
gregs_p = 0;
|
||||
}
|
||||
|
||||
/* Store the general-purpose registers. */
|
||||
if (gregs_p)
|
||||
{
|
||||
sparc32_collect_gregset (&vxsparc_gregset, regcache, -1, gregs);
|
||||
net_write_registers (gregs, SPARC_GREG_PLEN, PTRACE_SETREGS);
|
||||
|
||||
/* Deal with the stack regs. */
|
||||
if (regnum == -1 || regnum == SPARC_SP_REGNUM
|
||||
|| (regnum >= SPARC_L0_REGNUM && regnum <= SPARC_I7_REGNUM))
|
||||
{
|
||||
ULONGEST sp;
|
||||
|
||||
regcache_cooked_read_unsigned (regcache, SPARC_SP_REGNUM, &sp);
|
||||
sparc_collect_rwindow (regcache, sp, regnum);
|
||||
}
|
||||
}
|
||||
|
||||
/* Store the floating-point registers if the target has them. */
|
||||
if (fpregs_p && target_has_fp)
|
||||
{
|
||||
sparc32_collect_fpregset (regcache, -1, fpregs);
|
||||
net_write_registers (fpregs, SPARC_FPREG_PLEN, PTRACE_SETFPREGS);
|
||||
}
|
||||
}
|
@ -1,32 +0,0 @@
|
||||
/* Copyright 1992 Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc.
|
||||
|
||||
dbgRpcLib.h - header file for remote debugging via rpc */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01b,04oct90,maf added VX_BOOT_FILE_INQ.
|
||||
01a,05jun90,llk extracted from xdr_dbx.h.
|
||||
*/
|
||||
|
||||
#ifndef INCdbxRpcLibh
|
||||
#define INCdbxRpcLibh 1
|
||||
|
||||
#define PROCESS_START 50
|
||||
#define PROCESS_WAIT 51
|
||||
#define VX_STATE_INQ 60
|
||||
#define VX_LOAD 61
|
||||
#define VX_SYMBOL_INQ 62
|
||||
#define VX_BREAK_ADD 63
|
||||
#define VX_BREAK_DELETE 64
|
||||
#define VX_FP_INQUIRE 65
|
||||
#define VX_TASK_SUSPEND 66
|
||||
#define VX_CALL_FUNC 67
|
||||
#define VX_CONV_FROM_68881 68
|
||||
#define VX_CONV_TO_68881 69
|
||||
#define VX_BOOT_FILE_INQ 70
|
||||
#define VX_SOURCE_STEP 71
|
||||
|
||||
#endif INCdbxRpcLibh
|
@ -1,44 +0,0 @@
|
||||
/* @(#)ptrace.h 1.1 86/07/07 SMI */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1985 by Sun Microsystems, Inc.
|
||||
*/
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01a,05jun90,llk borrowed.
|
||||
*/
|
||||
|
||||
#ifndef _PTRACE_
|
||||
#define _PTRACE_
|
||||
|
||||
/*
|
||||
* Request values for the ptrace system call
|
||||
*/
|
||||
enum ptracereq {
|
||||
PTRACE_TRACEME = 0, /* 0, by tracee to begin tracing */
|
||||
PTRACE_CHILDDONE = 0, /* 0, tracee is done with his half */
|
||||
PTRACE_PEEKTEXT, /* 1, read word from text segment */
|
||||
PTRACE_PEEKDATA, /* 2, read word from data segment */
|
||||
PTRACE_PEEKUSER, /* 3, read word from user struct */
|
||||
PTRACE_POKETEXT, /* 4, write word into text segment */
|
||||
PTRACE_POKEDATA, /* 5, write word into data segment */
|
||||
PTRACE_POKEUSER, /* 6, write word into user struct */
|
||||
PTRACE_CONT, /* 7, continue process */
|
||||
PTRACE_KILL, /* 8, terminate process */
|
||||
PTRACE_SINGLESTEP, /* 9, single step process */
|
||||
PTRACE_ATTACH, /* 10, attach to an existing process */
|
||||
PTRACE_DETACH, /* 11, detach from a process */
|
||||
PTRACE_GETREGS, /* 12, get all registers */
|
||||
PTRACE_SETREGS, /* 13, set all registers */
|
||||
PTRACE_GETFPREGS, /* 14, get all floating point regs */
|
||||
PTRACE_SETFPREGS, /* 15, set all floating point regs */
|
||||
PTRACE_READDATA, /* 16, read data segment */
|
||||
PTRACE_WRITEDATA, /* 17, write data segment */
|
||||
PTRACE_READTEXT, /* 18, read text segment */
|
||||
PTRACE_WRITETEXT, /* 19, write text segment */
|
||||
PTRACE_GETFPAREGS, /* 20, get all fpa regs */
|
||||
PTRACE_SETFPAREGS /* 21, set all fpa regs */
|
||||
};
|
||||
#endif !_PTRACE
|
@ -1,160 +0,0 @@
|
||||
/* regPacket.h - register packet definitions for rdb */
|
||||
|
||||
/* Copyright 1992-1993 Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01d,30nov93,pad Added Am29K target definitions.
|
||||
01c,14jun93,maf additional definitions for documentation purposes.
|
||||
fixed reversal of MIPS_R_LO and MIPS_R_HI.
|
||||
01b,08feb93,scy added SPARC target definitions. changed to WRS code convetion.
|
||||
01a,20feb92,j_w created.
|
||||
*/
|
||||
|
||||
#ifndef __INCregPacketh
|
||||
#define __INCregPacketh
|
||||
|
||||
|
||||
/* MC68K */
|
||||
|
||||
#define MC68K_GREG_SIZE 0x04 /* size of general-purpose reg */
|
||||
#define MC68K_GREG_PLEN 0x48 /* size of general-purpose reg block */
|
||||
|
||||
/* offsets into general-purpose register block */
|
||||
|
||||
#define MC68K_R_D0 0x00 /* d0; d1 - d7 follow in sequence */
|
||||
#define MC68K_R_A0 0x20 /* a0; a1 - a7 follow in sequence */
|
||||
#define MC68K_R_SR 0x40 /* sr (represented as a 4-byte val) */
|
||||
#define MC68K_R_PC 0x44 /* pc */
|
||||
|
||||
#define MC68K_FPREG_SIZE 0x0c /* size of floating-point data reg */
|
||||
#define MC68K_FPREG_PLEN 0x6c /* size of floating-point reg block */
|
||||
|
||||
/* offsets into floating-point register block */
|
||||
|
||||
#define MC68K_R_FP0 0x00 /* fp0; fp1 - fp7 follow in sequence */
|
||||
#define MC68K_R_FPCR 0x60 /* fpcr */
|
||||
#define MC68K_R_FPSR 0x64 /* fpsr */
|
||||
#define MC68K_R_FPIAR 0x68 /* fpiar */
|
||||
|
||||
|
||||
/* I960 */
|
||||
|
||||
#define I960_GREG_SIZE 0x04 /* size of general-purpose reg */
|
||||
#define I960_GREG_PLEN 0x8c /* size of general-purpose reg block */
|
||||
|
||||
/* offsets into general-purpose register block */
|
||||
|
||||
#define I960_R_R0 0x00 /* r0; r1 - r15 follow in sequence */
|
||||
#define I960_R_G0 0x40 /* g0; g1 - g15 follow in sequence */
|
||||
#define I960_R_PCW 0x80 /* pcw */
|
||||
#define I960_R_ACW 0x84 /* acw */
|
||||
#define I960_R_TCW 0x88 /* tcw */
|
||||
|
||||
#define I960_FPREG_SIZE 0x10 /* size of floating-point reg */
|
||||
#define I960_FPREG_PLEN 0x28 /* size of floating-point reg block */
|
||||
|
||||
/* offsets into floating-point register block */
|
||||
|
||||
#define I960_R_FP0 0x00 /* fp0; fp1 - fp3 follow in sequence */
|
||||
|
||||
|
||||
/* SPARC */
|
||||
|
||||
#define SPARC_GREG_SIZE 0x04 /* size of general-purpose reg */
|
||||
#define SPARC_GREG_PLEN 0x98 /* size of general-purpose reg block */
|
||||
|
||||
/* offsets into general-purpose register block */
|
||||
|
||||
#define SPARC_R_G0 0x00 /* g0; g1 - g7 follow in sequence */
|
||||
#define SPARC_R_O0 0x20 /* o0; o1 - o7 follow in sequence */
|
||||
#define SPARC_R_L0 0x40 /* l0; l1 - l7 follow in sequence */
|
||||
#define SPARC_R_I0 0x60 /* i0; i1 - i7 follow in sequence */
|
||||
#define SPARC_R_Y 0x80 /* y */
|
||||
#define SPARC_R_PSR 0x84 /* psr */
|
||||
#define SPARC_R_WIM 0x88 /* wim */
|
||||
#define SPARC_R_TBR 0x8c /* tbr */
|
||||
#define SPARC_R_PC 0x90 /* pc */
|
||||
#define SPARC_R_NPC 0x94 /* npc */
|
||||
|
||||
#define SPARC_FPREG_SIZE 0x04 /* size of floating-point reg */
|
||||
#define SPARC_FPREG_PLEN 0x84 /* size of floating-point reg block */
|
||||
|
||||
/* offsets into floating-point register block */
|
||||
|
||||
#define SPARC_R_FP0 0x00 /* f0; f1 - f31 follow in sequence */
|
||||
#define SPARC_R_FSR 0x80 /* fsr */
|
||||
|
||||
|
||||
/* MIPS */
|
||||
|
||||
#define MIPS_GREG_SIZE 0x04 /* size of general-purpose reg */
|
||||
#define MIPS_GREG_PLEN 0x90 /* size of general-purpose reg block */
|
||||
|
||||
/* offsets into general-purpose register block */
|
||||
|
||||
#define MIPS_R_GP0 0x00 /* gp0 (zero) */
|
||||
#define MIPS_R_AT 0x04 /* at */
|
||||
#define MIPS_R_V0 0x08 /* v0 */
|
||||
#define MIPS_R_V1 0x0c /* v1 */
|
||||
#define MIPS_R_A0 0x10 /* a0 */
|
||||
#define MIPS_R_A1 0x14 /* a1 */
|
||||
#define MIPS_R_A2 0x18 /* a2 */
|
||||
#define MIPS_R_A3 0x1c /* a3 */
|
||||
#define MIPS_R_T0 0x20 /* t0 */
|
||||
#define MIPS_R_T1 0x24 /* t1 */
|
||||
#define MIPS_R_T2 0x28 /* t2 */
|
||||
#define MIPS_R_T3 0x2c /* t3 */
|
||||
#define MIPS_R_T4 0x30 /* t4 */
|
||||
#define MIPS_R_T5 0x34 /* t5 */
|
||||
#define MIPS_R_T6 0x38 /* t6 */
|
||||
#define MIPS_R_T7 0x3c /* t7 */
|
||||
#define MIPS_R_S0 0x40 /* s0 */
|
||||
#define MIPS_R_S1 0x44 /* s1 */
|
||||
#define MIPS_R_S2 0x48 /* s2 */
|
||||
#define MIPS_R_S3 0x4c /* s3 */
|
||||
#define MIPS_R_S4 0x50 /* s4 */
|
||||
#define MIPS_R_S5 0x54 /* s5 */
|
||||
#define MIPS_R_S6 0x58 /* s6 */
|
||||
#define MIPS_R_S7 0x5c /* s7 */
|
||||
#define MIPS_R_T8 0x60 /* t8 */
|
||||
#define MIPS_R_T9 0x64 /* t9 */
|
||||
#define MIPS_R_K0 0x68 /* k0 */
|
||||
#define MIPS_R_K1 0x6c /* k1 */
|
||||
#define MIPS_R_GP 0x70 /* gp */
|
||||
#define MIPS_R_SP 0x74 /* sp */
|
||||
#define MIPS_R_S8 0x78 /* s8 */
|
||||
#define MIPS_R_LO 0x80 /* lo */
|
||||
#define MIPS_R_HI 0x84 /* hi */
|
||||
#define MIPS_R_SR 0x88 /* sr */
|
||||
#define MIPS_R_PC 0x8c /* pc */
|
||||
|
||||
#define MIPS_FPREG_SIZE 0x04 /* size of floating-point data reg */
|
||||
#define MIPS_FPREG_PLEN 0x84 /* size of floating-point reg block */
|
||||
|
||||
/* offsets into floating-point register block */
|
||||
|
||||
#define MIPS_R_FP0 0x00 /* f0; f1 - f31 follow in sequence */
|
||||
#define MIPS_R_FPCSR 0x80 /* offset of fpcsr in reg block */
|
||||
|
||||
|
||||
/* General registers for the Am29k */
|
||||
|
||||
#define AM29K_GREG_SIZE 0x04
|
||||
#define AM29K_GREG_PLEN 0x2d4
|
||||
|
||||
#define AM29K_R_GR96 0x0
|
||||
#define AM29K_R_VAB 0x280
|
||||
#define AM29K_R_INTE 0x2bc
|
||||
#define AM29K_R_RSP 0x2c0
|
||||
|
||||
/* Floating Point registers for the Am29k */
|
||||
|
||||
#define AM29K_FPREG_SIZE 0x04
|
||||
#define AM29K_FPREG_PLEN 0x8
|
||||
|
||||
#define AM29K_R_FPE 0x0
|
||||
#define AM29K_R_FPS 0x4
|
||||
|
||||
#endif /* __INCregPacketh */
|
@ -1,72 +0,0 @@
|
||||
/* vxTypes.h - VxWorks type definition header */
|
||||
|
||||
/* Copyright 1984, 1985, 1986, 1987, 1988, 1989, 1990, 1992 Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01c,05oct90,shl added copyright notice.
|
||||
made #endif ANSI style.
|
||||
01b,10aug90,dnw added VOIDFUNCPTR
|
||||
01a,29may90,del written.
|
||||
*/
|
||||
|
||||
#ifndef INCvxTypesh
|
||||
#define INCvxTypesh
|
||||
|
||||
/* The following stuff must NOT be included if this include file is used
|
||||
* from assembly language. Just #define ASMLANGUAGE before the include,
|
||||
* to get rid of it.
|
||||
*/
|
||||
|
||||
#ifndef ASMLANGUAGE
|
||||
|
||||
/* vxWorks types */
|
||||
|
||||
typedef char INT8;
|
||||
typedef short INT16;
|
||||
typedef int INT32;
|
||||
|
||||
typedef unsigned char UINT8;
|
||||
typedef unsigned short UINT16;
|
||||
typedef unsigned int UINT32;
|
||||
|
||||
typedef unsigned char UCHAR;
|
||||
typedef unsigned short USHORT;
|
||||
typedef unsigned int UINT;
|
||||
typedef unsigned long ULONG;
|
||||
|
||||
typedef int BOOL;
|
||||
typedef int VOID;
|
||||
typedef int STATUS;
|
||||
typedef int ARGINT;
|
||||
|
||||
typedef int (*FUNCPTR) (); /* ptr to function returning int */
|
||||
typedef VOID (*VOIDFUNCPTR) (); /* ptr to function returning VOID */
|
||||
|
||||
|
||||
/* historical definitions - now obsolete */
|
||||
|
||||
typedef char TINY; /* obsolete */
|
||||
typedef char TBOOL; /* obsolete */
|
||||
typedef unsigned char UTINY; /* obsolete */
|
||||
|
||||
|
||||
/* architecture dependent typedefs */
|
||||
|
||||
#ifdef CPU_FAMILY
|
||||
|
||||
#if CPU_FAMILY==MC680X0
|
||||
typedef unsigned short INSTR; /* word-aligned instructions */
|
||||
#endif /* CPU_FAMILY==MC680X0 */
|
||||
|
||||
#if CPU_FAMILY==SPARC
|
||||
typedef unsigned long INSTR; /* 32 bit word-aligned instructions */
|
||||
#endif /* CPU_FAMILY==SPARC */
|
||||
|
||||
#endif
|
||||
|
||||
#endif /* ASMLANGUAGE */
|
||||
#endif /* INCvxTypesh */
|
@ -1,172 +0,0 @@
|
||||
/* vxWorks.h - VxWorks standard definitions header */
|
||||
|
||||
/* Copyright 1984, 1985, 1986, 1987, 1988, 1989, 1990, 1992, 1993
|
||||
Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01z,05oct90,shl added copyright notice.
|
||||
made #endif ANSI style.
|
||||
01y,28sep90,del added I960 defines.
|
||||
01x,29may90,del moved types to vxTypes.h
|
||||
01w,09apr90,jcf added timeout definitions.
|
||||
01v,24jan90,gae moved network configuration flags here from makefile's.
|
||||
01u,01sep88,mcl definition of INSTR dependent on processor family; added SPARC.
|
||||
+gae added MC680X0 and defined CPU_FAMILY.
|
||||
01t,08apr89,dnw added ifdef to prevent inclusion of vxWorks.h more than once.
|
||||
01s,22jun88,dnw moved READ, WRITE, and UPDATE back here from ioLib.h.
|
||||
01r,22apr88,gae oops! forgot some #endif's in 01q.
|
||||
01q,12apr88,gae removed QUICK & WAIT; added STD_{IN,OUT,ERR}.
|
||||
fixed #define's of FALSE, TRUE, etc.
|
||||
moved READ, WRITE, and UPDATE to ioLib.h.
|
||||
01p,04dec87,dnw added undefine of MC68000 to get around Green Hills bug that
|
||||
pre-defines MC68000.
|
||||
01o,12nov87,ecs added type ULONG.
|
||||
01n,08feb86,dnw added types INSTR, UINT, USHORT.
|
||||
01m,14oct85,rdc added BUS types.
|
||||
01l,16jul85,jlf added conditional for NULL and EOF.
|
||||
01k,24jun85,rdc installed condtional compile so we can include in
|
||||
assembly language files. See instructions below.
|
||||
Added System type macro and CPU type macro.
|
||||
01j,13jun85,dnw cleaned-up, removed more obsolete stuff to wrs.h
|
||||
01i,11sep84,jlf changed name from wrs.h to vxWorks.h. removed GLOBAL.
|
||||
01h,03jun84,dnw removed IGNORE declaration.
|
||||
01g,09apr84,jlf added MEMBER_SIZE macro.
|
||||
01f,14dec83,dnw added MSB, LSB macros
|
||||
01e,17nov83,jlf added STATUS type, for routines which return a status.
|
||||
01d,13jul83,dnw added NELEMENTS macro
|
||||
01c,14May83,dnw added OFFSET macro
|
||||
01b,17Feb83,dnw added stuff from Whitesmiths std.h
|
||||
01a,15Feb83,dnw written
|
||||
*/
|
||||
|
||||
#ifndef INCvxWorksh
|
||||
#define INCvxWorksh
|
||||
|
||||
#if !defined(EOF) || (EOF!=(-1))
|
||||
#define EOF (-1)
|
||||
#endif
|
||||
|
||||
#if !defined(FALSE) || (FALSE!=0)
|
||||
#define FALSE 0
|
||||
#endif
|
||||
|
||||
#if !defined(TRUE) || (TRUE!=1)
|
||||
#define TRUE 1
|
||||
#endif
|
||||
|
||||
|
||||
#define NONE (-1) /* for times when NULL won't do */
|
||||
#define EOS '\0' /* C string terminator */
|
||||
|
||||
|
||||
/* return status values */
|
||||
|
||||
#define OK 0
|
||||
#define ERROR (-1)
|
||||
|
||||
/* timeout defines */
|
||||
|
||||
#define NO_WAIT 0
|
||||
#define WAIT_FOREVER (-1)
|
||||
|
||||
/* low-level I/O input, output, error fd's */
|
||||
|
||||
#define STD_IN 0
|
||||
#define STD_OUT 1
|
||||
#define STD_ERR 2
|
||||
|
||||
/* modes - must match O_RDONLY/O_WRONLY/O_RDWR in ioLib.h! */
|
||||
|
||||
#define READ 0
|
||||
#define WRITE 1
|
||||
#define UPDATE 2
|
||||
|
||||
/* SYSTEM types */
|
||||
|
||||
#define V7 1 /* ATT version 7 */
|
||||
#define SYS_V 2 /* ATT System 5 */
|
||||
#define BSD_4_2 3 /* Berkeley BSD 4.2 */
|
||||
|
||||
/* CPU types */
|
||||
|
||||
/* The Green Hills compiler pre-defines "MC68000"!! */
|
||||
#ifdef MC68000
|
||||
#undef MC68000
|
||||
#endif
|
||||
|
||||
#define MC68000 1
|
||||
#define MC68010 2
|
||||
#define MC68020 3
|
||||
#define MC68030 4
|
||||
#define MC68040 5
|
||||
#define MC680X0 9
|
||||
|
||||
#define SPARC 10
|
||||
|
||||
#ifndef I960
|
||||
#define I960 20
|
||||
#endif
|
||||
|
||||
#define I960KB 21
|
||||
#define I960CA 22
|
||||
|
||||
#if CPU==MC68000 || CPU==MC68010 || CPU==MC68020 || CPU==MC68030
|
||||
#define CPU_FAMILY MC680X0
|
||||
#endif /* CPU==MC68000 || CPU==MC68010 || CPU==MC68020 || CPU==MC68030 */
|
||||
|
||||
#if CPU==SPARC
|
||||
#define CPU_FAMILY SPARC
|
||||
#endif /* CPU==SPARC */
|
||||
|
||||
#if CPU==I960KB
|
||||
#define CPU_FAMILY I960
|
||||
#endif /* CPU==I960KB */
|
||||
|
||||
#if CPU==I960CA
|
||||
#define CPU_FAMILY I960
|
||||
#endif /* CPU==I960CA */
|
||||
|
||||
/* BUS types */
|
||||
|
||||
#define VME_BUS 1
|
||||
#define MULTI_BUS 2
|
||||
|
||||
/* network configuration parameters */
|
||||
|
||||
#define INET /* include internet protocols */
|
||||
#define BSD 43 /* BSD 4.3 -like OS */
|
||||
#define BSDDEBUG /* turn on debug */
|
||||
#define GATEWAY /* tables to be initialized for gateway routing */
|
||||
|
||||
/* common macros */
|
||||
|
||||
#define MSB(x) (((x) >> 8) & 0xff) /* most signif byte of 2-byte integer */
|
||||
#define LSB(x) ((x) & 0xff) /* least signif byte of 2-byte integer*/
|
||||
|
||||
#define OFFSET(structure, member) /* byte offset of member in structure*/\
|
||||
((int) &(((structure *) 0) -> member))
|
||||
|
||||
#define MEMBER_SIZE(structure, member) /* size of a member of a structure */\
|
||||
(sizeof (((structure *) 0) -> member))
|
||||
|
||||
#define NELEMENTS(array) /* number of elements in an array */ \
|
||||
(sizeof (array) / sizeof ((array) [0]))
|
||||
|
||||
#define FOREVER for (;;)
|
||||
|
||||
/* storage class specifier definitions */
|
||||
|
||||
#define FAST register
|
||||
#define IMPORT extern
|
||||
#define LOCAL static
|
||||
|
||||
|
||||
/* include typedefs - must come after CPU_FAMILY definitions above */
|
||||
|
||||
#include "vxTypes.h"
|
||||
|
||||
#endif /* INCvxWorksh */
|
@ -1,46 +0,0 @@
|
||||
/* wait.h - header file for remote wait call */
|
||||
|
||||
/* Copyright 1992 Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01a,05jun90,llk borrowed.
|
||||
*/
|
||||
|
||||
/* Define how to access the structure that the wait system call
|
||||
stores. On many systems, there is a structure defined for
|
||||
this. */
|
||||
|
||||
#ifndef HAVE_WAIT_STRUCT
|
||||
#define WAITTYPE int
|
||||
#define WIFSTOPPED(w) (((w)&0377) == 0177)
|
||||
#define WIFSIGNALED(w) (((w)&0377) != 0177 && ((w)&~0377) == 0)
|
||||
#define WIFEXITED(w) (((w)&0377) == 0)
|
||||
#define WRETCODE(w) ((w) >> 8)
|
||||
#define WSTOPSIG(w) ((w) >> 8)
|
||||
#define WCOREDUMP(w) (((w)&0200) != 0)
|
||||
#define WTERMSIG(w) ((w) & 0177)
|
||||
#define WSETEXIT(w, status) ((w) = (status))
|
||||
#define WSETSTOP(w,sig) ((w) = (0177 | ((sig) << 8)))
|
||||
#else
|
||||
#if FALSE
|
||||
#ifndef ORIG
|
||||
|
||||
/* don't include sys/wait.h */
|
||||
|
||||
#else ORIG
|
||||
#include <sys/wait.h>
|
||||
#endif ORIG
|
||||
#endif FALSE
|
||||
#define WAITTYPE union wait
|
||||
#define WRETCODE(w) (w).w_retcode
|
||||
#define WSTOPSIG(w) (w).w_stopsig
|
||||
#define WCOREDUMP(w) (w).w_coredump
|
||||
#define WTERMSIG(w) (w).w_termsig
|
||||
#define WSETEXIT(w, status) ((w).w_status = (status))
|
||||
#define WSETSTOP(w,sig) \
|
||||
((w).w_stopsig = (sig), (w).w_coredump = 0, (w).w_termsig = 0177)
|
||||
#endif
|
@ -1,85 +0,0 @@
|
||||
/* xdr_ld.c - xdr routines for remote dbx interface to VxWorks */
|
||||
|
||||
/* Copyright 1984, 1985, 1986, 1987, 1988, 1989, 1992, 1993, 1998
|
||||
Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01a,05jun90,llk extracted from xdr_dbx.c.
|
||||
*/
|
||||
|
||||
/*
|
||||
DESCRIPTION
|
||||
This module contains the eXternal Data Representation (XDR) routines
|
||||
for object files that are downloaded to VxWorks. They are used by
|
||||
remote debuggers that use RPC (such as dbxWorks and vxGdb).
|
||||
*/
|
||||
|
||||
#include "defs.h"
|
||||
#include "vxWorks.h"
|
||||
#include "rpc/rpc.h"
|
||||
#include "xdr_ld.h"
|
||||
|
||||
/* forward declarations */
|
||||
|
||||
bool_t xdr_String(); /* xdr routine for argument list */
|
||||
|
||||
|
||||
/*******************************************************************************
|
||||
*
|
||||
* xdr_String - xdr routine for strings.
|
||||
*
|
||||
* Used by xdr_arg_info to handle the actual argument
|
||||
* strings. normally calls xdr_string - but does something
|
||||
* reasonable encode of null pointer.
|
||||
*/
|
||||
|
||||
bool_t xdr_String (xdrs, strp)
|
||||
XDR *xdrs;
|
||||
char **strp;
|
||||
|
||||
{
|
||||
if ((*strp == NULL) & (xdrs->x_op == XDR_ENCODE))
|
||||
return(FALSE);
|
||||
else
|
||||
return(xdr_string(xdrs, strp, MAXSTRLEN));
|
||||
}
|
||||
/*******************************************************************************
|
||||
*
|
||||
* xdr_ldfile - xdr routine for a single element in the load table
|
||||
*/
|
||||
|
||||
bool_t xdr_ldfile (xdrs, objp)
|
||||
XDR *xdrs;
|
||||
ldfile *objp;
|
||||
|
||||
{
|
||||
if (! xdr_String(xdrs, &objp->name))
|
||||
return(FALSE);
|
||||
if (! xdr_int(xdrs, &objp->txt_addr))
|
||||
return(FALSE);
|
||||
if (! xdr_int(xdrs, &objp->data_addr))
|
||||
return(FALSE);
|
||||
if (! xdr_int(xdrs, &objp->bss_addr))
|
||||
return(FALSE);
|
||||
|
||||
return(TRUE);
|
||||
}
|
||||
/*******************************************************************************
|
||||
*
|
||||
* xdr_ldtabl -
|
||||
*
|
||||
* xdr routine for a list of files and load addresses loaded into VxWorks.
|
||||
*/
|
||||
|
||||
bool_t xdr_ldtabl (xdrs,objp)
|
||||
XDR *xdrs;
|
||||
ldtabl *objp;
|
||||
|
||||
{
|
||||
return (xdr_array (xdrs, (char **) &objp->tbl_ent, (UINT *) &objp->tbl_size,
|
||||
MAXTBLSZ, sizeof(ldfile), xdr_ldfile));
|
||||
}
|
@ -1,45 +0,0 @@
|
||||
/* xdr_ld.h - xdr for additional dbxWorks structures */
|
||||
|
||||
/* Copyright 1992 Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01a,05jun90,llk extracted from xdr_dbx.h.
|
||||
*/
|
||||
|
||||
#ifndef INCxdrldh
|
||||
#define INCxdrldh
|
||||
|
||||
#define MAXSTRLEN 256
|
||||
#define MAXTBLSZ 100
|
||||
|
||||
/*
|
||||
* structure used to pass back the information for a single file
|
||||
* loaded in VxWorks
|
||||
*/
|
||||
struct ldfile {
|
||||
char *name;
|
||||
int txt_addr;
|
||||
int data_addr;
|
||||
int bss_addr;
|
||||
};
|
||||
typedef struct ldfile ldfile;
|
||||
|
||||
/*
|
||||
* structure used to return a list of all files loaded over to
|
||||
* VxWorks. (VX_STATE_INQ return)
|
||||
*/
|
||||
struct ldtabl {
|
||||
u_int tbl_size;
|
||||
ldfile *tbl_ent;
|
||||
};
|
||||
typedef struct ldtabl ldtabl;
|
||||
|
||||
|
||||
bool_t xdr_ldfile();
|
||||
bool_t xdr_ldtabl();
|
||||
|
||||
#endif INCxdrldh
|
@ -1,119 +0,0 @@
|
||||
/* xdr_ptrace.c - xdr routines for remote ptrace calls */
|
||||
|
||||
/* Copyright 1984, 1985, 1986, 1987, 1988, 1989, 1991, 1992, 1993, 1998
|
||||
Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01b,25may91,maf now uses counted bytes struct to transfer registers.
|
||||
removed xdr_regs_ptr (), xdr_fp_status_ptr (), and
|
||||
xdr_fpa_regs_ptr ().
|
||||
01a,05jun90,llk extracted from xdr_ptrace.h, version 01c.
|
||||
*/
|
||||
|
||||
#include "defs.h"
|
||||
#include "vxWorks.h"
|
||||
#include <rpc/rpc.h>
|
||||
#include "xdr_ptrace.h"
|
||||
|
||||
#define MAX_LEN 32000
|
||||
|
||||
/********************************************************************
|
||||
*
|
||||
* xdr_c_bytes -
|
||||
*
|
||||
* xdr routine for counted bytes
|
||||
*
|
||||
*/
|
||||
bool_t xdr_c_bytes(xdrs,objp)
|
||||
XDR *xdrs;
|
||||
C_bytes *objp;
|
||||
{
|
||||
return(xdr_bytes(xdrs, &objp->bytes, (u_int *) &objp->len, MAX_LEN));
|
||||
} /* xdr_c_bytes */
|
||||
|
||||
/********************************************************************
|
||||
*
|
||||
* xdr_c_bytes_ptr -
|
||||
*
|
||||
* xdr routine for counted bytes branch of ptrace_info
|
||||
*
|
||||
*/
|
||||
|
||||
LOCAL bool_t xdr_c_bytes_ptr(xdrs,objp)
|
||||
XDR *xdrs;
|
||||
C_bytes **objp;
|
||||
{
|
||||
return(xdr_pointer(xdrs, (char **) objp, sizeof(C_bytes), xdr_c_bytes));
|
||||
} /* xdr_c_bytes_ptr */
|
||||
|
||||
/********************************************************************
|
||||
*
|
||||
* xdr_ptrace_info -
|
||||
*
|
||||
* xdr routine for discriminated union ptrace_info
|
||||
*
|
||||
*/
|
||||
|
||||
bool_t xdr_ptrace_info(xdrs,objp)
|
||||
XDR *xdrs;
|
||||
Ptrace_info *objp;
|
||||
{
|
||||
static struct xdr_discrim choices[] =
|
||||
{
|
||||
{ (int) DATA, xdr_c_bytes_ptr },
|
||||
{ __dontcare__, NULL }
|
||||
};
|
||||
|
||||
return(xdr_union(xdrs, (enum_t *) &objp->ttype,
|
||||
(char *) &objp->more_data, choices, xdr_void));
|
||||
} /* xdr_ptrace_info */
|
||||
|
||||
/********************************************************************
|
||||
*
|
||||
* xdr_rptrace -
|
||||
*
|
||||
* xdr routine for remote ptrace data into server
|
||||
*
|
||||
*/
|
||||
|
||||
bool_t xdr_rptrace(xdrs,objp)
|
||||
XDR *xdrs;
|
||||
Rptrace *objp;
|
||||
{
|
||||
if (! xdr_int(xdrs, &objp->pid))
|
||||
return(FALSE);
|
||||
if (! xdr_int(xdrs, &objp->data))
|
||||
return(FALSE);
|
||||
if (! xdr_int(xdrs, &objp->addr))
|
||||
return(FALSE);
|
||||
if (! xdr_ptrace_info(xdrs, &objp->info))
|
||||
return(FALSE);
|
||||
|
||||
return(TRUE);
|
||||
} /* xdr_rptrace */
|
||||
|
||||
/********************************************************************
|
||||
*
|
||||
* xdr_ptrace_return -
|
||||
*
|
||||
* xdr routine for remote ptrace data returned by server
|
||||
*
|
||||
*/
|
||||
|
||||
bool_t xdr_ptrace_return(xdrs, objp)
|
||||
XDR *xdrs;
|
||||
Ptrace_return *objp;
|
||||
{
|
||||
if (! xdr_int(xdrs, &objp->status))
|
||||
return(FALSE);
|
||||
if (! xdr_int(xdrs, &objp->errno_num))
|
||||
return(FALSE);
|
||||
if (! xdr_ptrace_info(xdrs, &objp->info))
|
||||
return(FALSE);
|
||||
|
||||
return(TRUE);
|
||||
} /* xdr_ptrace_return */
|
@ -1,72 +0,0 @@
|
||||
/* xdr_ptrace.h - xdr header for remote ptrace structures */
|
||||
|
||||
/* Copyright 1992, 1998 Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01b,25may91,maf now uses counted bytes struct to transfer registers;
|
||||
removed references to old xdr_regs functions.
|
||||
removed includes of "xdr_regs.h" and "reg.h".
|
||||
01a,05jun90,llk extracted from xdr_ptrace.h.
|
||||
*/
|
||||
|
||||
|
||||
/*
|
||||
* Counted byte structure used by READ/WRITE TEXT/DATA
|
||||
* and GET/SET REGS/FPREGS
|
||||
*/
|
||||
struct c_bytes {
|
||||
u_int len;
|
||||
caddr_t bytes;
|
||||
};
|
||||
typedef struct c_bytes C_bytes;
|
||||
|
||||
/*
|
||||
* enum for discriminated union ptrace_info
|
||||
*/
|
||||
enum ptype {
|
||||
NOINFO = 0, /* no additional infomation */
|
||||
DATA = 1 /* c_bytes */
|
||||
};
|
||||
typedef enum ptype ptype;
|
||||
|
||||
/*
|
||||
* discrimnated union for passing additional data to be
|
||||
* written to the debugged process.
|
||||
*/
|
||||
struct ptrace_info {
|
||||
ptype ttype;
|
||||
caddr_t more_data;
|
||||
};
|
||||
typedef struct ptrace_info Ptrace_info;
|
||||
|
||||
/*
|
||||
* structure passed to server on all remote ptrace calls
|
||||
*/
|
||||
struct rptrace {
|
||||
int pid;
|
||||
int data;
|
||||
int addr; /* FIX! this really should be caddr_t or something */
|
||||
Ptrace_info info;
|
||||
};
|
||||
typedef struct rptrace Rptrace;
|
||||
|
||||
/*
|
||||
* structure returned by server on all remote ptrace calls
|
||||
*/
|
||||
/* This used to have a field called errno, but that fails on hosts which
|
||||
define errno to be a macro, so it was changed to errno_num. */
|
||||
struct ptrace_return {
|
||||
int status;
|
||||
int errno_num;
|
||||
Ptrace_info info;
|
||||
};
|
||||
typedef struct ptrace_return Ptrace_return;
|
||||
|
||||
bool_t xdr_c_bytes();
|
||||
bool_t xdr_ptrace_info();
|
||||
bool_t xdr_rptrace();
|
||||
bool_t xdr_ptrace_return();
|
@ -1,212 +0,0 @@
|
||||
/* xdr_rdb.c - xdr routines for Remote Debug interface to VxWorks */
|
||||
|
||||
/* Copyright 1992, 1993 Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01a,21mar90,llk created using modification 01d of xdr_dbx.c.
|
||||
*/
|
||||
|
||||
/*
|
||||
DESCRIPTION
|
||||
This module contains the eXternal Data Representation (XDR) routines
|
||||
for the RDB interface for VxWorks.
|
||||
*/
|
||||
|
||||
#include "defs.h"
|
||||
#include "vxWorks.h"
|
||||
#include <rpc/rpc.h>
|
||||
#include "xdr_rdb.h"
|
||||
|
||||
/* forward declarations */
|
||||
|
||||
bool_t
|
||||
xdr_arg_type(xdrs, objp)
|
||||
XDR *xdrs;
|
||||
arg_type *objp;
|
||||
{
|
||||
if (!xdr_enum(xdrs, (enum_t *)objp)) {
|
||||
return (FALSE);
|
||||
}
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
bool_t
|
||||
xdr_arg_value(xdrs, objp)
|
||||
XDR *xdrs;
|
||||
arg_value *objp;
|
||||
{
|
||||
if (!xdr_arg_type(xdrs, &objp->type)) {
|
||||
return (FALSE);
|
||||
}
|
||||
switch (objp->type) {
|
||||
case T_BYTE:
|
||||
if (!xdr_char(xdrs, &objp->arg_value_u.v_byte)) {
|
||||
return (FALSE);
|
||||
}
|
||||
break;
|
||||
case T_WORD:
|
||||
if (!xdr_short(xdrs, &objp->arg_value_u.v_word)) {
|
||||
return (FALSE);
|
||||
}
|
||||
break;
|
||||
case T_INT:
|
||||
if (!xdr_int(xdrs, &objp->arg_value_u.v_int)) {
|
||||
return (FALSE);
|
||||
}
|
||||
break;
|
||||
case T_FLOAT:
|
||||
if (!xdr_float(xdrs, &objp->arg_value_u.v_fp)) {
|
||||
return (FALSE);
|
||||
}
|
||||
break;
|
||||
case T_DOUBLE:
|
||||
if (!xdr_double(xdrs, &objp->arg_value_u.v_dp)) {
|
||||
return (FALSE);
|
||||
}
|
||||
break;
|
||||
case T_UNKNOWN:
|
||||
break;
|
||||
}
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
bool_t
|
||||
xdr_func_call(xdrs, objp)
|
||||
XDR *xdrs;
|
||||
func_call *objp;
|
||||
{
|
||||
if (!xdr_int(xdrs, &objp->func_addr)) {
|
||||
return (FALSE);
|
||||
}
|
||||
if (!xdr_array(xdrs, (char **)&objp->args.args_val, (u_int *)&objp->args.args_len, MAX_FUNC_ARGS, sizeof(arg_value), xdr_arg_value)) {
|
||||
return (FALSE);
|
||||
}
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
bool_t
|
||||
xdr_arg_one(xdrs, objp)
|
||||
XDR *xdrs;
|
||||
arg_one *objp;
|
||||
{
|
||||
if (!xdr_string(xdrs, objp, MAX_ARG_LEN)) {
|
||||
return (FALSE);
|
||||
}
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
bool_t
|
||||
xdr_arg_array(xdrs, objp)
|
||||
XDR *xdrs;
|
||||
arg_array *objp;
|
||||
{
|
||||
if (!xdr_array(xdrs, (char **)&objp->arg_array_val, (u_int *)&objp->arg_array_len, MAX_ARG_CNT, sizeof(arg_one), xdr_arg_one)) {
|
||||
return (FALSE);
|
||||
}
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
*
|
||||
* xdr_EVENT_TYPE -
|
||||
*
|
||||
*/
|
||||
|
||||
bool_t xdr_EVENT_TYPE(xdrs, objp)
|
||||
XDR *xdrs;
|
||||
EVENT_TYPE *objp;
|
||||
|
||||
{
|
||||
if (!xdr_enum (xdrs, (enum_t *) objp))
|
||||
return (FALSE);
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
*
|
||||
* xdr_RDB_EVENT -
|
||||
*
|
||||
*/
|
||||
|
||||
bool_t xdr_RDB_EVENT (xdrs, objp)
|
||||
XDR *xdrs;
|
||||
RDB_EVENT *objp;
|
||||
|
||||
{
|
||||
if (!xdr_int (xdrs, &objp->status))
|
||||
return (FALSE);
|
||||
if (!xdr_int (xdrs, &objp->taskId))
|
||||
return (FALSE);
|
||||
if (!xdr_EVENT_TYPE (xdrs, &objp->eventType))
|
||||
return (FALSE);
|
||||
if (!xdr_int (xdrs, &objp->sigType))
|
||||
return (FALSE);
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
*
|
||||
* xdr_TASK_START -
|
||||
*
|
||||
*/
|
||||
|
||||
bool_t
|
||||
xdr_TASK_START (xdrs, objp)
|
||||
XDR *xdrs;
|
||||
TASK_START *objp;
|
||||
|
||||
{
|
||||
if (!xdr_int (xdrs, &objp->status))
|
||||
return (FALSE);
|
||||
if (!xdr_int (xdrs, &objp->pid))
|
||||
return (FALSE);
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
|
||||
/*********************************************************************
|
||||
*
|
||||
* xdr_SYMBOL_ADDR -
|
||||
*
|
||||
*/
|
||||
|
||||
bool_t
|
||||
xdr_SYMBOL_ADDR (xdrs, objp)
|
||||
XDR *xdrs;
|
||||
SYMBOL_ADDR *objp;
|
||||
|
||||
{
|
||||
if (!xdr_int (xdrs, &objp->status))
|
||||
return (FALSE);
|
||||
if (!xdr_u_int (xdrs, &objp->addr))
|
||||
return (FALSE);
|
||||
return (TRUE);
|
||||
}
|
||||
|
||||
/*********************************************************************
|
||||
*
|
||||
* xdr_SOURCE_STEP -
|
||||
*
|
||||
*/
|
||||
|
||||
bool_t
|
||||
xdr_SOURCE_STEP (xdrs, objp)
|
||||
XDR *xdrs;
|
||||
SOURCE_STEP *objp;
|
||||
|
||||
{
|
||||
if (!xdr_int (xdrs, &objp->taskId))
|
||||
return (FALSE);
|
||||
if (!xdr_u_int (xdrs, &objp->startAddr))
|
||||
return (FALSE);
|
||||
if (!xdr_u_int (xdrs, &objp->endAddr))
|
||||
return (FALSE);
|
||||
return (TRUE);
|
||||
}
|
@ -1,137 +0,0 @@
|
||||
/* xdr_rdb.h - xdr for additional rdb structures */
|
||||
|
||||
/* Copyright 1992 Free Software Foundation, Inc.
|
||||
|
||||
This code was donated by Wind River Systems, Inc. */
|
||||
|
||||
/*
|
||||
modification history
|
||||
--------------------
|
||||
01c,25may91,maf rolled RDBVERS for VxGDB 1.0 version.
|
||||
01b,12apr91,maf rolled RDBVERS.
|
||||
01a,09jan91,maf created using v1a of xdr_rdb.h for 4.0.2 VxWorks 68k.
|
||||
added struct SOURCE_STEP.
|
||||
*/
|
||||
|
||||
#ifndef INCxdrrdbh
|
||||
#define INCxdrrdbh
|
||||
|
||||
enum arg_type {
|
||||
T_UNKNOWN = 0,
|
||||
T_BYTE = 1,
|
||||
T_WORD = 2,
|
||||
T_INT = 3,
|
||||
T_FLOAT = 4,
|
||||
T_DOUBLE = 5
|
||||
};
|
||||
typedef enum arg_type arg_type;
|
||||
bool_t xdr_arg_type();
|
||||
|
||||
|
||||
struct arg_value {
|
||||
arg_type type;
|
||||
union {
|
||||
char v_byte;
|
||||
short v_word;
|
||||
int v_int;
|
||||
float v_fp;
|
||||
double v_dp;
|
||||
} arg_value_u;
|
||||
};
|
||||
typedef struct arg_value arg_value;
|
||||
bool_t xdr_arg_value();
|
||||
|
||||
struct func_call {
|
||||
int func_addr;
|
||||
struct {
|
||||
u_int args_len;
|
||||
arg_value *args_val;
|
||||
} args;
|
||||
};
|
||||
typedef struct func_call func_call;
|
||||
bool_t xdr_func_call();
|
||||
|
||||
|
||||
typedef char *arg_one;
|
||||
bool_t xdr_arg_one();
|
||||
|
||||
|
||||
typedef struct {
|
||||
u_int arg_array_len;
|
||||
arg_one *arg_array_val;
|
||||
} arg_array;
|
||||
bool_t xdr_arg_array();
|
||||
|
||||
|
||||
/*
|
||||
* Structures used to pass structures required for
|
||||
* process control but not part of the standard ptrace interface
|
||||
*/
|
||||
|
||||
/*
|
||||
* arg_info is used to pass arguments into process start
|
||||
*/
|
||||
struct arg_info {
|
||||
int rargc;
|
||||
char **rargv;
|
||||
};
|
||||
typedef struct arg_info Arg_info;
|
||||
|
||||
|
||||
enum EVENT_TYPE {
|
||||
EVENT_BREAK = 0,
|
||||
EVENT_STOP = 1,
|
||||
EVENT_EXIT = 2,
|
||||
EVENT_BUS_ERR = 3,
|
||||
EVENT_SUSPEND = 4,
|
||||
EVENT_ZERO_DIV = 5,
|
||||
EVENT_SIGNAL = 6,
|
||||
EVENT_START = 7
|
||||
};
|
||||
typedef enum EVENT_TYPE EVENT_TYPE;
|
||||
|
||||
|
||||
struct RDB_EVENT {
|
||||
int status;
|
||||
int taskId;
|
||||
EVENT_TYPE eventType;
|
||||
int sigType;
|
||||
};
|
||||
typedef struct RDB_EVENT RDB_EVENT;
|
||||
|
||||
|
||||
struct TASK_START {
|
||||
int status;
|
||||
int pid;
|
||||
};
|
||||
typedef struct TASK_START TASK_START;
|
||||
|
||||
|
||||
struct SYMBOL_ADDR {
|
||||
int status;
|
||||
u_int addr;
|
||||
};
|
||||
typedef struct SYMBOL_ADDR SYMBOL_ADDR;
|
||||
|
||||
struct SOURCE_STEP {
|
||||
int taskId;
|
||||
u_int startAddr;
|
||||
u_int endAddr;
|
||||
};
|
||||
typedef struct SOURCE_STEP SOURCE_STEP;
|
||||
|
||||
#define MAX_ARG_CNT 10
|
||||
#define MAX_FUNC_ARGS 100
|
||||
#define MAX_ARG_LEN 100
|
||||
|
||||
|
||||
bool_t xdr_arg_info();
|
||||
bool_t xdr_EVENT_TYPE();
|
||||
bool_t xdr_RDB_EVENT();
|
||||
bool_t xdr_TASK_START();
|
||||
bool_t xdr_SYMBOL_ADDR();
|
||||
bool_t xdr_SOURCE_STEP();
|
||||
|
||||
#define RDBPROG (u_long) 0x44444444
|
||||
#define RDBVERS (u_long) 3
|
||||
#endif INCxdrrdbh
|
Loading…
Reference in New Issue
Block a user