Commit Graph

23 Commits

Author SHA1 Message Date
christos
b86e6ac858 Systrace support. 2002-06-17 16:23:58 +00:00
jdolecek
d7f811d098 utrace(2): limit size of user data to KTR_USER_MAXLEN (currently 2048); return EINVAL if 'len' is bigger 2001-01-05 22:25:26 +00:00
jdolecek
a80dee65df add utrace(2) - this syscall allows to add user ktrace entries
idea from FreeBSD, but added argument (const char *id) so that it's possible
to differentiate between entries from different sources
2000-12-28 11:10:15 +00:00
jdolecek
d2a0c208d5 add FreeBSD-compatible KTR_USER/KTRFAC_USER 2000-12-17 16:04:51 +00:00
sommerfeld
40339b39f9 Reduce use of curproc in several places:
- Change ktrace interface to pass in the current process, rather than
p->p_tracep, since the various ktr* function need curproc anyway.

 - Add curproc as a parameter to mi_switch() since all callers had it
handy anyway.

 - Add a second proc argument for inferior() since callers all had
curproc handy.

Also, miscellaneous cleanups in ktrace:

 - ktrace now always uses file-based, rather than vnode-based I/O
(simplifies, increases type safety); eliminate KTRFLAG_FD & KTRFAC_FD.
Do non-blocking I/O, and yield a finite number of times when receiving
EWOULDBLOCK before giving up.

 - move code duplicated between sys_fktrace and sys_ktrace into ktrace_common.

 - simplify interface to ktrwrite()
2000-05-27 00:40:29 +00:00
thorpej
2d720e5ff0 Don't truncate syscall return values on LP64 platforms. 1999-08-06 00:11:02 +00:00
kleink
bff1bef006 * Add a comment to ktrgetheader() mentioning that ktr_len and ktr_buf are
being left uninitialized intentionally; addresses PR kern/6987.
* In ktrsysret(), initialize the unused ktr_eosys to avoid writing random junk.
1999-04-11 18:44:00 +00:00
mycroft
fb526e055c Substantial signal handling changes:
* Increase the size of sigset_t to accomodate 128 signals -- adding new
  versions of sys_setprocmask(), sys_sigaction(), sys_sigpending() and
  sys_sigsuspend() to handle the changed arguments.
* Abstract the guts of sys_sigaltstack(), sys_setprocmask(), sys_sigaction(),
  sys_sigpending() and sys_sigsuspend() into separate functions, and call them
  from all the emulations rather than hard-coding everything.  (Avoids uses
  the stackgap crap for these system calls.)
* Add a new flag (p_checksig) to indicate that a process may have signals
  pending and userret() needs to do the full (slow) check.
* Eliminate SAS_ALTSTACK; it's exactly the inverse of SS_DISABLE.
* Correct emulation bugs with restoring SS_ONSTACK.
* Make the signal mask in the sigcontext always use the emulated mask format.
* Store signals internally in sigaction structures, rather than maintaining a
  bunch of little sigsets for each SA_* bit.
* Keep track of where we put the signal trampoline, rather than figuring it out
  in *_sendsig().
* Issue a warning when a non-emulated sigaction bit is observed.
* Add missing emulated signals, and a native SIGPWR (currently not used).
* Implement the `not reset when caught' semantics for relevant signals.

Note: Only code touched by the i386 port has been modified.  Other ports and
emulations need to be updated.
1998-09-11 12:50:05 +00:00
christos
5fa65dfd18 fktrace changes. 1998-05-02 18:41:47 +00:00
fvdl
e5bc90f40c Merge with Lite2 + local changes 1998-03-01 02:20:01 +00:00
perry
d39928a203 add/cleanup multiple inclusion protection. 1998-02-10 00:25:25 +00:00
christos
7da3571dc9 Fix some missing/wrong prototypes so that kern/* compiles again 1996-02-04 02:12:07 +00:00
christos
eee33cdb2a Added a KTR_EMUL record to be used to indicate syscall emulation changes. 1995-07-19 15:27:05 +00:00
briggs
6efcd1b6d4 KERNEL -> _KERNEL 1995-03-29 21:57:43 +00:00
jtc
7c04233887 KERNEL -> _KERNEL 1995-03-26 20:23:52 +00:00
cgd
3a977bd3df syscall tracing: store code and argsize, as ints; update comments. 1995-03-26 07:47:39 +00:00
cgd
fccfa11af5 New RCS ID's, take two. they're more aesthecially pleasant, and use 'NetBSD' 1994-06-29 06:39:25 +00:00
cgd
f21254981e new standard, minimally intrusive ID format 1994-06-27 19:27:39 +00:00
cgd
10ade1de6a add rcsid 1994-05-11 07:21:09 +00:00
cgd
794c5e3130 add support for context switch tracing 1994-05-11 07:20:46 +00:00
cgd
cd1bcbc8ca add rcs ids as necessary, and also clean up headers 1993-05-20 16:21:42 +00:00
mycroft
bcbf85df19 Add consistent multiple-inclusion protection. 1993-04-19 01:22:17 +00:00
cgd
61f282557f initial import of 386bsd-0.1 sources 1993-03-21 09:45:37 +00:00