summaryrefslogtreecommitdiffstats
path: root/sys/amd64/include/signal.h
Commit message (Collapse)AuthorAgeFilesLines
* Begin all license/copyright comments with /*-imp2005-01-051-1/+1
|
* Remove advertising clause from University of California Regent's license,imp2004-04-051-4/+0
| | | | | | per letter dated July 22, 1999 and email from Peter Wemm. Approved by: core, peter
* Update the graffiti.peter2003-11-081-0/+1
|
* Rename npx* to fpu*. I haven't done the flags/function names yet.peter2003-11-081-1/+1
|
* Pull the tier-2 card one last time and break the get/setcontext andpeter2003-10-151-2/+2
| | | | | | | | | | | | | | | | | | | | | | sigreturn() ABI and the signal context on the stack. Make the trapframe (and its shadows in the ucontext and sigframe etc) 8 bytes larger in order to preserve 16 byte stack alignment for the following C code calls. I could have done some padding after the trapframe was saved, but some of the C code still expects an argument of 'struct trapframe'. Anyway, this gives me a spare field that can be used to store things like 'partial trapframe' status or something else in the future. The runtime impact is fairly small, *except* for threaded apps and things that decode contexts and the signal stack (eg: cvsup binary). Signal delivery isn't too badly affected because the kernel generates the sigframe that sigreturn uses after the handler has been called. The size of mcontext_t and struct sigframe hasn't changed. Only the last few fields (sc_eip etc) got moved a little and I eliminated a spare field. mc_len/sc_len did change location though so the sanity checks there will still trap it.
* Argh. This file was completely out of sync with mcontext/trapframe.peter2003-09-081-11/+12
|
* Hmm. Two copies of the mcontext...peter2003-09-081-1/+1
|
* Commit MD parts of a loosely functional AMD64 port. This is based onpeter2003-05-011-60/+30
| | | | | | | | | | | | | | | | | | | | | | a heavily stripped down FreeBSD/i386 (brutally stripped down actually) to attempt to get a stable base to start from. There is a lot missing still. Worth noting: - The kernel runs at 1GB in order to cheat with the pmap code. pmap uses a variation of the PAE code in order to avoid having to worry about 4 levels of page tables yet. - It boots in 64 bit "long mode" with a tiny trampoline embedded in the i386 loader. This simplifies locore.s greatly. - There are still quite a few fragments of i386-specific code that have not been translated yet, and some that I cheated and wrote dumb C versions of (bcopy etc). - It has both int 0x80 for syscalls (but using registers for argument passing, as is native on the amd64 ABI), and the 'syscall' instruction for syscalls. int 0x80 preserves all registers, 'syscall' does not. - I have tried to minimize looking at the NetBSD code, except in a couple of places (eg: to find which register they use to replace the trashed %rcx register in the syscall instruction). As a result, there is not a lot of similarity. I did look at NetBSD a few times while debugging to get some ideas about what I might have done wrong in my first attempt.
* Align the FPU state in the ucontext and sigcontext to 16 bytesdeischen2002-12-021-2/+2
| | | | | | | | | to accomodate the new SSE/XMM floating point save/restore instructions. This commit is mostly from bde and includes some style nits. Approved by: re (jhb)
* Add getcontext, setcontext, and swapcontext as system calls.deischen2002-11-161-2/+2
| | | | | | | | | | | Previously these were libc functions but were requested to be made into system calls for atomicity and to coalesce what might be two entrances into the kernel (signal mask setting and floating point trap) into one. A few style nits and comments from bde are also included. Tested on alpha by: gallatin
* Split 4.x and 5.x signal handling so that we can keep 4.x signalpeter2002-10-251-3/+1
| | | | | | | | | | | | | | | | handling clean and functional as 5.x evolves. This allows some of the nasty bandaids in the 5.x codepaths to be unwound. Encapsulate 4.x signal handling under COMPAT_FREEBSD4 (there is an anti-foot-shooting measure in place, 5.x folks need this for a while) and finish encapsulating the older stuff under COMPAT_43. Since the ancient stuff is required on alpha (longjmp(3) passes a 'struct osigcontext *' to the current sigreturn(2), instead of the 'ucontext_t *' that sigreturn is supposed to take), add a compile time check to prevent foot shooting there too. Add uniform COMPAT_43 stubs for ia64/sparc64/powerpc. Tested on: i386, alpha, ia64. Compiled on sparc64 (a few days ago). Approved by: re
* Add standards visibility conditionals. Change any uses of sigset_t tomike2002-10-131-4/+8
| | | | struct __sigset to avoid depending on objects from <sys/signal.h>.
* Add kernel support needed for the KSE-aware libpthread:mini2002-09-161-5/+8
| | | | | | | | - Maintain fpu state across signals. - Save and restore FPU state properly in ucontext_t's. Reviewed by: deischen, julian Approved by: -arch
* Use struct __ucontext in prototypes and associated functions instead ofdeischen2002-02-171-0/+5
| | | | | | | | | | ucontext_t. Forward declare struct __ucontext in <sys/signal.h> and remove reliance on <sys/ucontext.h> being included. While I'm here, also hide osigcontext types from userland; suggested by bde. Namespace pollution noticed by: Kevin Day <toasty@shell.dragondata.com>
* style(9) the structure definitions.obrien2001-09-051-2/+2
|
* Make MINSIGSTKSZ machine dependent, and have the sigaltstackmarcel2000-11-091-0/+6
| | | | | | | | | | | | | | | | | | | | | | syscall compare against a variable sv_minsigstksz in struct sysentvec as to properly take the size of the machine- and ABI dependent struct sigframe into account. The SVR4 and iBCS2 modules continue to have a minsigstksz of 8192 to preserve behavior. The real values (if different) are not known at this time. Other ABI modules use the real values. The native MINSIGSTKSZ is now defined as follows: Arch MINSIGSTKSZ ---- ----------- alpha 4096 i386 2048 ia64 12288 Reviewed by: mjacob Suggested by: bde
* Reserve space for FPU state in struct sigcontext. Fix some style bugsmarcel1999-11-121-11/+18
| | | | | | and comments while there. Submitted by: bde
* Re-introduction of sigcontext.marcel1999-10-041-22/+51
| | | | | | | | | | | | | | | | | | | | | | | | | | | struct sigcontext and ucontext_t/mcontext_t are defined in such a way that both (ie struct sigcontext and ucontext_t) can be passed on to sigreturn. The signal handler is still given a ucontext_t for maximum flexibility. For backward compatibility sigreturn restores the state for the alternate signal stack from sigcontext.sc_onstack and not from ucontext_t.uc_stack. A good way to determine which value the application has set and thus which value to use, is still open for discussion. NOTE: This change should only affect those binaries that use sigcontext and/or ucontext_t. In the source tree itself this is only doscmd. Recompilation is required for those applications. This commit also fixes a lot of style bugs without hopefully adding new ones. NOTE: struct sigaltstack.ss_size now has type size_t again. For some reason I changed that into unsigned int. Parts submitted by: bde sigaltstack bug found by: bde
* sigset_t change (part 3 of 5)marcel1999-09-291-27/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | ----------------------------- By introducing a new sigframe so that the signal handler operates on the new siginfo_t and on ucontext_t instead of sigcontext, we now need two version of sendsig and sigreturn. A flag in struct proc determines whether the process expects an old sigframe or a new sigframe. The signal trampoline handles which sigreturn to call. It does this by testing for a magic cookie in the frame. The alpha uses osigreturn to implement longjmp. This means that osigreturn is not only used for compatibility with existing binaries. To handle the new sigset_t, setjmp saves it in sc_reserved (see NOTE). the struct sigframe has been moved from frame.h to sigframe.h to handle the complex header dependencies that was caused by the new sigframe. NOTE: For the i386, the size of jmp_buf has been increased to hold the new sigset_t. On the alpha this has been prevented by using sc_reserved in sigcontext.
* $Id$ -> $FreeBSD$peter1999-08-281-1/+1
|
* VM86 kernel support.dyson1997-08-091-1/+6
| | | | | | | Work done by BSDI, Jonathan Lemon <jlemon@americantv.com>, Mike Smith <msmith@gsoft.com.au>, Sean Eric Fagan <sef@kithrup.com>, and probably alot of others. Submitted by: Jnathan Lemon <jlemon@americantv.com>
* Back out part 1 of the MCFH that changed $Id$ to $FreeBSD$. We are notpeter1997-02-221-1/+1
| | | | ready for it yet.
* Make the long-awaited change from $Id$ to $FreeBSD$jkh1997-01-141-1/+1
| | | | | | | | This will make a number of things easier in the future, as well as (finally!) avoiding the Id-smashing problem which has plagued developers for so long. Boy, I'm glad we're not using sup anymore. This update would have been insane otherwise.
* Fix standards conformance bugs in <signal.h>:bde1995-06-281-6/+8
| | | | | | | | | | | | | | | | | | | | | include/signal.h: There was massive namespace pollution from including <sys/types.h>. POSIX functions were declared even when _ANSI_SOURCE is defined. sys.sys/signal.h: NSIG was declared even if _ANSI_SOURCE or _POSIX_SOURCE is defined. sig_atomic_t wasn't declared if _POSIX_SOURCE is defined. Declare a typedef for signal handling functions and use it to unobfuscate declarations and to avoid half-baked function types that cause unwanted compiler warnings at certain warning levels. Fix confusing comment about SA_RESTART. sys/i386/include/signal.h: This has to be included to get the declaration of sig_atomic_t even when _ANSI_SOURCE is defined, so be more careful about polluting the ANSI namespace. Uniformize idempotency ifdefs.
* Made idempotent.paul1994-08-211-1/+6
| | | | | Reviewed by: Submitted by:
* Added $Id$dg1994-08-021-0/+1
|
* The big 4.4BSD Lite to FreeBSD 2.0.0 (Development) patch.rgrimes1994-05-251-7/+21
| | | | | Reviewed by: Rodney W. Grimes Submitted by: John Dyson and David Greenman
* BSD 4.4 Lite Kernel Sourcesrgrimes1994-05-251-0/+61
OpenPOWER on IntegriCloud