Deleted Added
full compact
machdep.c (130312) machdep.c (130344)
1/*-
2 * Copyright (c) 2003 Peter Wemm.
3 * Copyright (c) 1992 Terrence R. Lambert.
4 * Copyright (c) 1982, 1987, 1990 The Regents of the University of California.
5 * All rights reserved.
6 *
7 * This code is derived from software contributed to Berkeley by
8 * William Jolitz.

--- 25 unchanged lines hidden (view full) ---

34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * from: @(#)machdep.c 7.4 (Berkeley) 6/3/91
39 */
40
41#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2003 Peter Wemm.
3 * Copyright (c) 1992 Terrence R. Lambert.
4 * Copyright (c) 1982, 1987, 1990 The Regents of the University of California.
5 * All rights reserved.
6 *
7 * This code is derived from software contributed to Berkeley by
8 * William Jolitz.

--- 25 unchanged lines hidden (view full) ---

34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * from: @(#)machdep.c 7.4 (Berkeley) 6/3/91
39 */
40
41#include <sys/cdefs.h>
42__FBSDID("$FreeBSD: head/sys/amd64/amd64/machdep.c 130312 2004-06-10 20:31:00Z jhb $");
42__FBSDID("$FreeBSD: head/sys/amd64/amd64/machdep.c 130344 2004-06-11 11:16:26Z phk $");
43
44#include "opt_atalk.h"
45#include "opt_atpic.h"
46#include "opt_compat.h"
47#include "opt_cpu.h"
48#include "opt_ddb.h"
49#include "opt_inet.h"
50#include "opt_ipx.h"

--- 206 unchanged lines hidden (view full) ---

257 get_fpcontext(td, &sf.sf_uc.uc_mcontext);
258 fpstate_drop(td);
259
260 /* Allocate space for the signal handler context. */
261 if ((td->td_pflags & TDP_ALTSTACK) != 0 && !oonstack &&
262 SIGISMEMBER(psp->ps_sigonstack, sig)) {
263 sp = td->td_sigstk.ss_sp +
264 td->td_sigstk.ss_size - sizeof(struct sigframe);
43
44#include "opt_atalk.h"
45#include "opt_atpic.h"
46#include "opt_compat.h"
47#include "opt_cpu.h"
48#include "opt_ddb.h"
49#include "opt_inet.h"
50#include "opt_ipx.h"

--- 206 unchanged lines hidden (view full) ---

257 get_fpcontext(td, &sf.sf_uc.uc_mcontext);
258 fpstate_drop(td);
259
260 /* Allocate space for the signal handler context. */
261 if ((td->td_pflags & TDP_ALTSTACK) != 0 && !oonstack &&
262 SIGISMEMBER(psp->ps_sigonstack, sig)) {
263 sp = td->td_sigstk.ss_sp +
264 td->td_sigstk.ss_size - sizeof(struct sigframe);
265#if defined(COMPAT_43) || defined(COMPAT_SUNOS)
265#if defined(COMPAT_43)
266 td->td_sigstk.ss_flags |= SS_ONSTACK;
267#endif
268 } else
269 sp = (char *)regs->tf_rsp - sizeof(struct sigframe) - 128;
270 /* Align to 16 bytes. */
271 sfp = (struct sigframe *)((unsigned long)sp & ~0xFul);
272
273 /* Translate the signal if appropriate. */

--- 124 unchanged lines hidden (view full) ---

398 }
399
400 ret = set_fpcontext(td, &ucp->uc_mcontext);
401 if (ret != 0)
402 return (ret);
403 bcopy(&ucp->uc_mcontext.mc_rdi, regs, sizeof(*regs));
404
405 PROC_LOCK(p);
266 td->td_sigstk.ss_flags |= SS_ONSTACK;
267#endif
268 } else
269 sp = (char *)regs->tf_rsp - sizeof(struct sigframe) - 128;
270 /* Align to 16 bytes. */
271 sfp = (struct sigframe *)((unsigned long)sp & ~0xFul);
272
273 /* Translate the signal if appropriate. */

--- 124 unchanged lines hidden (view full) ---

398 }
399
400 ret = set_fpcontext(td, &ucp->uc_mcontext);
401 if (ret != 0)
402 return (ret);
403 bcopy(&ucp->uc_mcontext.mc_rdi, regs, sizeof(*regs));
404
405 PROC_LOCK(p);
406#if defined(COMPAT_43) || defined(COMPAT_SUNOS)
406#if defined(COMPAT_43)
407 if (ucp->uc_mcontext.mc_onstack & 1)
408 td->td_sigstk.ss_flags |= SS_ONSTACK;
409 else
410 td->td_sigstk.ss_flags &= ~SS_ONSTACK;
411#endif
412
413 td->td_sigmask = ucp->uc_sigmask;
414 SIG_CANTMASK(td->td_sigmask);

--- 1411 unchanged lines hidden ---
407 if (ucp->uc_mcontext.mc_onstack & 1)
408 td->td_sigstk.ss_flags |= SS_ONSTACK;
409 else
410 td->td_sigstk.ss_flags &= ~SS_ONSTACK;
411#endif
412
413 td->td_sigmask = ucp->uc_sigmask;
414 SIG_CANTMASK(td->td_sigmask);

--- 1411 unchanged lines hidden ---