wiz
e0f60703ab
Bump date for previous. New sentence, new line.
2003-11-16 10:16:56 +00:00
manu
91d6d92c2e
Add an argument to the -x flag to choose between byte per byte display
...
and word per word display in hex dumps.
-x1 gives you byte per byte, -x4 word per word, and -x defaults to -x1
2003-11-16 10:13:48 +00:00
manu
94d3385454
Re-add the static root conditionnal that was removed by mistake.
2003-11-16 10:10:37 +00:00
manu
a0399121cc
kdump now displays Mach services names itself, including a table of
...
id/names in sys/compat/mach/mach_services_names.c
Remove ports and flags displays, the information is already in the message.
2003-11-15 23:10:31 +00:00
dsl
7a7ad1c63b
Look for siginfo in the correct place - otherwise kdump is rebuilt all the time.
2003-11-13 13:07:01 +00:00
matt
9bd74136be
Use envariable AWK
2003-11-13 05:52:12 +00:00
lukem
130ab7336b
Rework how MAKEVERBOSE operates:
...
* Don't bother prefixing commands with a line of ${_MKCMD}\
and instead rely upon "make -s". This is less intrusive on
all the Makefiles than the former. Idea from David Laight.
* Rename the variables use to print messages. The scheme now is:
_MKMSG_FOO Run _MKMSG 'foo'
_MKTARGET_FOO Run _MKMSG_FOO ${.TARGET}
From discussion with Alistair Crooks.
2003-10-21 10:01:19 +00:00
christos
87b62b5af0
KNF:
...
- ansify
- no breaks after returns
- statics where needed
- no exit after errx
2003-10-19 07:34:38 +00:00
lukem
a694177df5
support MAKEVERBOSE and use ${HOST_SH}
2003-10-19 04:25:00 +00:00
matt
fe365eaf9d
Fix printf botch
2003-09-20 22:24:00 +00:00
christos
73bb764e22
improve formatting in the non-siginfo case, by printing the code. This is
...
for compatibility with the old ktrace files.
2003-09-20 00:17:44 +00:00
christos
b612016506
Print siginfo_t information when available.
2003-09-19 22:49:02 +00:00
thorpej
e5adc13bea
* Make it a little easier to add new "ioctl defns are in these files".
...
* Add the ability to decode the cryptodev ioctls.
2003-08-27 20:35:42 +00:00
agc
89aaa1bb64
Move UCB-licensed code from 4-clause to 3-clause licence.
...
Patches provided by Joel Baker in PR 22365, verified by myself.
2003-08-07 11:13:06 +00:00
dsl
fde07830ad
Grok KTR_EXEC_ENV and KTR_EXEC_ARG.
...
Make ktrace -c default to removing all trace points (not just the default ones).
Make kdump default to dumping everything in the trace file.
Add 'A' (all) and '-' (remove following) to valid -t arguments.
Dump data block of UNKNOWN trace points in hex + ascii.
Make first time output with -R 0 (instead of time since epoch).
Use svis() instead of vis() to get " escaped (as \") (needs fixed libc)
Correctly pass unsigned values to svis()
Update man pages.
2003-07-17 09:05:11 +00:00
dsl
a99fe675ab
Change back to print hex bytes. The 'word' print was completely broken
...
on little endian systems. It is also much easier to read misaligned
words in a straight byte hexdump.
Cut offset to 3 hex digits so that it fixs in 80 columns and still
leaves a tab at the start of 'continuation' lines.
The ktrace buffer is limited to 4k, so 3 digits is ample.
2003-07-13 18:54:29 +00:00
he
ac678f8de2
On some ports, pointer differences are not ints, so do a cast
...
before using such a result as a field width.
2003-07-13 15:19:39 +00:00
manu
cbfacd83b6
Make hexdump output fix in 80 char-wide terminal
2003-07-12 19:22:07 +00:00
manu
e9383d7e5d
Use the same code to display hexdump of GIO and MMSG (Mach Messages).
...
While we are there, display offsets in the hexdump, it can be useful.
Remove size display in Mach Messages as user processes don't always
fill it correctly.
2003-07-12 10:07:08 +00:00
wiz
b712736290
Add -x to usage output.
2003-07-11 13:06:11 +00:00
wiz
79093334ef
Bump date for -x addition.
2003-07-11 13:05:26 +00:00
dsl
6ea05bcbfe
Add a '-x' option to display GIO data blocks in hex and ascii (instead of
...
vis(3) format).
Maybe there could be a heuristic to decide whether the data is printable...
2003-07-11 10:59:28 +00:00
fvdl
4fdb86c883
Back out previous.
2003-06-29 22:35:35 +00:00
martin
40ee31ef5e
Since a caddr_t is (mis-)used as the lwp-id, cast it to intptr_t and use
...
apropriate format string.
2003-06-29 18:05:06 +00:00
darrenr
d0ad455673
add appropriate hack to display ktr_buf as the lwpid if -L is supplied on
...
the command line.
2003-06-28 17:15:07 +00:00
mjl
91085f010d
Add sys/sockio.h to needed includes for SIOCGIFASYNCMAP.
2003-06-24 11:27:50 +00:00
dsl
d9380c052a
Print rval[1] if non-zero and present in the trace entry.
...
To get both fd numbers for pipe().
2003-05-15 12:57:54 +00:00
christos
b8dae40722
Don't invoke the grep for cleandir and obj targets. Suggested by
...
Juergen Hannken-Illjes
2003-04-18 14:43:49 +00:00
christos
aa5b09ddbf
PR/21117: Robert Elz: Makefile-ioctl.c mishandles dependencies
2003-04-13 05:04:00 +00:00
wiz
990562bfef
.Nm does not need a dummy argument ("") before punctuation or
...
for correct formatting of the SYNOPSIS any longer.
2003-02-25 10:34:36 +00:00
atatat
9658e47b39
Make "-m0" print no data, so that we agree better with the man page.
2003-01-30 21:43:26 +00:00
manu
6492e2171f
Added support for dumping mach messages in ktrace/kdump. While we are
...
there, KNFify a few functions.
2002-12-09 21:29:20 +00:00
wiz
287a8f7fb0
Sync usage with man page (and actual options).
2002-11-29 19:15:41 +00:00
wiz
75c991f87d
Bump date for -N; sort options.
2002-11-29 19:14:00 +00:00
jdolecek
d51c5abbd9
signame(): if sig == 0, return name " 0", so that the result would be
...
printed as:
CALL kill(0x1e4, SIG 0)
rathern than previous
CALL kill(0x1e4, SIG*unknown 0*)
2002-11-28 16:18:49 +00:00
atatat
a19ac80340
Add -N which inhibits translation of system calls numbers into names.
2002-11-27 21:26:57 +00:00
manu
bcffe04b31
Now properly display Mach traps
2002-11-15 19:58:05 +00:00
manu
0d50171c61
Added support for COMPAT_MACH
2002-10-29 07:17:43 +00:00
wiz
17cf386a88
Bump date for .Op Ar file addition.
2002-09-28 12:40:41 +00:00
atatat
76df260979
Allow passing of the ktrace file as the last argument without a -f.
2002-09-27 20:31:44 +00:00
lukem
2c16ea6f7e
use NETBSDSRCDIR as appropriate
2002-09-19 11:31:21 +00:00
lha
35e64a7b76
remove extra $ from previous commit
2002-09-18 20:50:22 +00:00
lukem
5d4973fe97
makefile delint. use NETBSDSRCDIR as appropriate
2002-09-18 14:00:33 +00:00
lukem
ed401558f2
Implement MKDYNAMICROOT, which currently defaults to "no", but will
...
be changed in the future to "yes".
If MKDYNAMICROOT == "no", there is no change from existing behaviour
of a static /bin and /sbin (and a few programs in elsewhere).
If MKDYNAMICROOT == "yes", the following changes occur:
in <bsd.own.mk>:
SHLIBDIR?= /lib
SHLINKDIR?= /lib
in various Makefiles, the following entry is DISABLED.
LDSTATIC?=-static
This results in all programs (except those "standalone" programs built
in sys/arch/*/stand) are linked dynamically, the shared linker is moved
from /usr/libexec to /lib (with a compat symlink), and the shared
libraries used by /bin and /sbin programs are moved from /usr/lib to
/lib (with compat symlinks).
2002-08-27 14:46:11 +00:00
jdolecek
d733dc2b03
Fix formatting of ktr_user entries so that values of individual bytes
...
of ktrace record are treated as unsigned char, and printed using "%02x".
Change suggested in bin/17832 by Paul Goyette.
2002-08-04 14:26:21 +00:00
atatat
40bd599a90
It's easy for ktrace can generate trace files that contain data from
...
multiple processes, so let's add a "-p pid" option to kdump so that it
can pull out the data for one process easily.
2002-06-20 22:02:32 +00:00
christos
44788ce33b
Fix translation in the native emulation. Noted by veego.
2002-04-08 20:15:59 +00:00
christos
f600368b8f
Provide hooks for signal number to name translation, and use them for kill
...
and PSIG.
XXX[1]: This shows that signal emulation ktrace is slightly busted: posted
signals should really be translated to the emulated ones instead of
producing ktrace records with the signal numbers of the native
emulation.
XXX[2]: There are other places where signal names can be displayed, but this
is not done yet.
2002-03-31 22:44:03 +00:00
christos
35734831f9
reverse the notion of fancy, use plain, and increment it so that we can
...
have multiple levels of plainness. I want to be able to display syscalls
numerically, for that use -nn. This is not documented as it is an wip.
2002-02-12 22:22:37 +00:00
manu
3219730476
reflect iric o32/n32 emulations
2002-01-07 23:45:10 +00:00
manu
bb34193550
Now use IRIX errno translation instead of SVR4 errno translation
2001-12-02 16:18:01 +00:00
wiz
aded0d2cce
Whitespace cleanup.
2001-12-01 16:43:07 +00:00
manu
9a1cd2898a
Added support for IRIX emulation
2001-11-28 10:36:48 +00:00
mycroft
0505c42bda
Quotes around ${CC}...
2001-09-25 14:26:56 +00:00
jdolecek
6f081befa2
set CC and DESTDIR for mkioctls accordingly
...
patch by Chris Jepeway via tech-userlevel.
2001-09-23 08:51:11 +00:00
eeh
7cb49c5859
Add svr4_32 info.
2001-03-11 21:28:59 +00:00
manu
1a6f014301
Cosmetic fix so that RET record after CALL execve get the appropriate syscall
...
even if the emulation changed
2001-02-16 23:28:44 +00:00
jdolecek
d15ae688ce
use 'trstr' for parameter to -t; both 'cenis' (SYNOPSIS) and 'cnis' (DESCRIPTION)
...
were already out of date and we really don't want keep the info on two
places
2001-02-04 20:44:53 +00:00
mrg
05ebb290f5
teach kdump about compat/sunos32
2001-02-02 07:41:54 +00:00
enami
1dcd879fa8
Make files here compile again.
2001-01-19 14:14:03 +00:00
jdolecek
be3807a7c5
adapt to KTR_USER structure changes
2000-12-28 11:11:34 +00:00
itojun
08138ae451
avoid using "errno" as struct member name, to avoid conflict with errno.h.
...
ok by jdolecek
2000-12-20 22:11:16 +00:00
jdolecek
33150dda73
add support for KTR_USER records
2000-12-17 16:09:40 +00:00
jdolecek
53b6556eda
back out previous change - this needs to be discussed first at least
2000-11-14 00:10:16 +00:00
jdolecek
dfc9af3212
don't link these static; if shared libraries are hosed, these utilities would
...
surely not save the situation, not help to recover from it
2000-11-13 21:48:33 +00:00
jdolecek
b837b700fa
map linux ptrace op (number) to it's appropriate name - this is kind of hack,
...
but turned out to be pretty usable for me
2000-11-13 21:43:12 +00:00
jdolecek
862d46845d
adapt to *syscallnames[] change (it's now const char * const foo[]),
...
constify
2000-11-13 21:38:48 +00:00
is
3b5e0e52e8
Format string cleanups
2000-10-12 19:02:17 +00:00
is
135600f947
More format string cleanup by sommerfeld.
2000-10-11 14:46:00 +00:00
mrg
1a3492999b
mark the installed ioctl.h & ioctl_compat.h PRECIOUS; if mkioctls fails, don't delete them!
2000-07-27 11:51:14 +00:00
cgd
100e87de11
'${CC:-cc} -E' rather than 'cpp': want to use a cross-compiler if
...
appropriate, but worse: 'cpp' (real-UNIX or stock gnu) takes args
[infile [outfile]]. I.e., the second arg (ioctl_compat.h) would
end up being nuked by this script if using a vendor or stock gnu cpp!
Our /usr/bin/cpp works Differently.
2000-07-27 01:36:56 +00:00
jdolecek
654400f740
ectx_sanify(): ditch utterly broken 'optimization', which caused incorrect
...
emulation structures to be used in every even case if default emulation
and emulation of process differed.
Bug found by Bill Studenmund.
2000-07-20 20:47:02 +00:00
itohy
07db0e6ae9
Add "pecoff" emulation.
2000-06-13 00:59:22 +00:00
tron
7a721a2672
Prevent "kdump" from causing a segmentation fault if the io buffer that
...
it's printing to stdout ends on a page boundary. Patch supplied by
Andrew Brown in PR bin/9983.
2000-04-26 16:05:37 +00:00
jdolecek
2f5f8663c5
ectx_sanify(): if default_emul is not set, use netbsd emulation (may happen when user passes invalid
...
emulation name via -e argument)
2000-04-10 09:34:18 +00:00
jdolecek
470e7fc568
put setemul(), ectx_* & appropriate structures to separate file, to make it
...
more easily sharable with ktruss(1)
2000-04-10 09:13:45 +00:00
jdolecek
d0dc3a7168
clarify -e usage
2000-04-10 08:05:25 +00:00
jdolecek
3d8f702c2b
Keep track of what pid uses which emulation and ensure proper
...
structures are used when decoding the ktrace records. This makes
kdump of ktrace -i output of a process executing binaries of various
emulations actually useful - before, the code used emulation structures
appropriate for last recently executed process, which is bogus.
2000-04-10 07:58:30 +00:00
kleink
a3c6c197a2
Cast timeval members to types we know the printf conversions of.
2000-03-27 17:03:25 +00:00
eeh
5fc5fe98a8
Add COMPAT_NETBSD32 support.
1999-12-31 22:27:59 +00:00
thorpej
2d720e5ff0
Don't truncate syscall return values on LP64 platforms.
1999-08-06 00:11:02 +00:00
mrg
9abab6de8b
- build with obj dirs.
...
- use .PATH not broken links
- share the make fragment to build "ioctl.c"
- general clean up, RCSID, etc.
this is all happy now AFAICT.
1999-07-12 04:13:34 +00:00
garbled
9e44e9b578
More and more .Os cleanups. .Os is defined in the tmac.doc-common file,
...
so we shouldn't override it with versions in the manpages. Many more to
come.
1999-03-22 18:16:34 +00:00
christos
30c9449a34
Adjust to Eric's recent errno renaming.
1998-10-24 19:04:51 +00:00
christos
9a04d28344
Fix emulation errno translation.
1998-10-18 17:43:43 +00:00
veego
ee0b338314
Fix the include problem of <compat/linux/arch/xxx/linux_syscall.h>.
1998-10-04 10:49:58 +00:00
mycroft
ae0f007e15
Update for signal handling changes.
1998-09-11 23:09:31 +00:00
mrg
71f20d7c82
use static int instead of static
1998-03-30 02:25:33 +00:00
cgd
8aaf609a0a
allow LDSTATIC definition to be overridden by bsd.own.mk/mk.conf
1998-03-02 19:42:25 +00:00
lukem
8ba07ab0b3
use CPPFLAGS instead of CFLAGS
1997-10-24 09:00:17 +00:00
lukem
2f48163c46
add support for freebsd emulation. from Dave Huang <khym@bga.com> [bin/4293]
1997-10-20 04:21:22 +00:00
lukem
0dd4a8e6e5
WARNSify mkioctls output, fix .Nm usage, deprecate register
1997-10-19 03:38:27 +00:00
mikel
e578379504
minor cleanup
1997-08-01 04:37:36 +00:00
mikel
1a90a52019
add explicit return types and prototypes for local functions
...
use __COPYRIGHT and __RCSID macros, fix other gcc -Wall warnings
1997-07-23 05:53:34 +00:00
mikel
3489c99115
RCSid police
1997-07-23 05:51:08 +00:00
mikel
7194732677
nuke duplicate RCSid
1997-07-23 05:47:45 +00:00
phil
992579779c
Add input files to dependency list for ioctl.c build.
1997-07-21 19:29:58 +00:00
pk
585a85d3d0
* NULL => 0 (Arne Juul; PR#3629)
...
* Nuke spacoids
1997-05-17 19:46:27 +00:00
gwr
10e180cc49
Back out the .PATH.c changes. The .depend problem (and others)
...
will be fixed using the new .NOPATH make feature instead.
1997-05-08 21:11:01 +00:00
gwr
012e528f2e
Use .PATH.c: ...
1997-05-06 20:44:56 +00:00
leo
48e267e695
Make it obey the DESTDIR environment.
1997-04-14 13:49:56 +00:00
cgd
0317ced760
fix decode of _IOR/_IOW/_IOWR: 'R' and 'W' were switched (i.e. _IOW ioctls
...
would print out as '_IOR'), and _IOWR ioctls were being printed as
_IORW (which doesn't exist).
1997-01-27 21:39:50 +00:00
tls
9d225a1783
RCS ID police
1997-01-09 20:18:21 +00:00
mikel
43f43a58b0
eliminate multiple inclusion of <sys/errno.h>.
1996-11-21 06:25:26 +00:00
christos
f0f4eea0fd
Decode unknown ioctl commands to _IO{R,W,}('c',x[,y]), instead of 0xabcdef00
1996-05-13 21:12:25 +00:00
jtc
9cffeee5b2
Sync with 4.4lite2
1995-08-31 22:50:22 +00:00
christos
7e8c6bf13c
Add support for displaying and switching between
...
different OS system call emulations
1995-07-19 15:11:19 +00:00
cgd
e75fdcfa2e
only print MAXCOMLEN chars of the process command name. fixes pr 1080.
1995-06-07 07:24:19 +00:00
thorpej
7d7d30315b
Bring in all includes necessary since the multicast changes. Fixes
...
PR #1114 .
1995-06-06 23:45:27 +00:00
cgd
dd6987cafa
don't get syscalls.c with an absolute path
1995-05-11 22:29:04 +00:00
jtc
ae0b9c2010
KERNEL -> _KERNEL
1995-03-28 17:18:59 +00:00
cgd
8c6e0cd884
update for the new data stored in ktrace files:
...
(1) use argsize rather than nargs
(2) print long-sized (assumed == register_t-sized; XXX) items
rather than int-sized ones.
1995-03-26 07:56:27 +00:00
mycroft
feec0fc0c1
Make two variables non-static.
1995-03-21 14:22:38 +00:00
mycroft
e60255f2bc
Update to use timer{add,sub}().
1995-03-21 14:16:23 +00:00
mycroft
7a7adcb788
Gather a more complete ioctl list. From Matt Green (somewhat edited).
1995-01-15 07:51:08 +00:00
mycroft
7e07241514
Some KNF, POSIX, and err*(3)/warn*(3) cleanup. Also, use sys_signame[]
...
rather than a private, home-grown list.
1995-01-15 07:50:44 +00:00
cgd
e3599736d2
val is a long, now.
1994-12-24 16:47:28 +00:00
deraadt
f45b220870
Link these statically to make shared library debugging easier
1994-12-06 14:54:50 +00:00
mycroft
2fd4512058
Add RCS ids.
1994-10-06 15:44:32 +00:00
mycroft
71782585d6
Pass the file names in to mkioctl, to help cross-compilation.
1994-06-18 16:33:22 +00:00
deraadt
450d60fe9d
netbsd does not define PT_STEP for architectures that lack
...
in-kernel single stepping capabilities.
1994-05-18 21:07:34 +00:00
cgd
57935c670a
updated kdump
1994-05-11 07:10:27 +00:00