linux_sysvec.c (0b5d5dc3767fcf2f0198f0f9549cb23983e0ee3e) linux_sysvec.c (ba279bcd6d75aa236bcb9ccf11aeb6f51a2f8514)
1/*-
2 * SPDX-License-Identifier: BSD-2-Clause-FreeBSD
3 *
4 * Copyright (c) 1994-1996 Søren Schmidt
5 * All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

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

417 fp = (struct l_rt_sigframe *)regs->tf_esp - 1;
418 mtx_unlock(&psp->ps_mtx);
419
420 /* Build the argument list for the signal handler. */
421 sig = bsd_to_linux_signal(sig);
422
423 bzero(&frame, sizeof(frame));
424
1/*-
2 * SPDX-License-Identifier: BSD-2-Clause-FreeBSD
3 *
4 * Copyright (c) 1994-1996 Søren Schmidt
5 * All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

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

417 fp = (struct l_rt_sigframe *)regs->tf_esp - 1;
418 mtx_unlock(&psp->ps_mtx);
419
420 /* Build the argument list for the signal handler. */
421 sig = bsd_to_linux_signal(sig);
422
423 bzero(&frame, sizeof(frame));
424
425 frame.sf_handler = catcher;
426 frame.sf_sig = sig;
427 frame.sf_siginfo = &fp->sf_si;
428 frame.sf_ucontext = &fp->sf_sc;
429
430 /* Fill in POSIX parts. */
431 siginfo_to_lsiginfo(&ksi->ksi_info, &frame.sf_si, sig);
432
433 /* Build the signal context to be used by sigreturn. */

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

468 */
469 PROC_LOCK(p);
470 sigexit(td, SIGILL);
471 }
472
473 /* Build context to run handler in. */
474 regs->tf_esp = (int)fp;
475 regs->tf_eip = __kernel_rt_sigreturn;
425 frame.sf_sig = sig;
426 frame.sf_siginfo = &fp->sf_si;
427 frame.sf_ucontext = &fp->sf_sc;
428
429 /* Fill in POSIX parts. */
430 siginfo_to_lsiginfo(&ksi->ksi_info, &frame.sf_si, sig);
431
432 /* Build the signal context to be used by sigreturn. */

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

467 */
468 PROC_LOCK(p);
469 sigexit(td, SIGILL);
470 }
471
472 /* Build context to run handler in. */
473 regs->tf_esp = (int)fp;
474 regs->tf_eip = __kernel_rt_sigreturn;
475 regs->tf_edi = catcher;
476 regs->tf_eflags &= ~(PSL_T | PSL_VM | PSL_D);
477 regs->tf_cs = _ucodesel;
478 regs->tf_ds = _udatasel;
479 regs->tf_es = _udatasel;
480 regs->tf_fs = _udatasel;
481 regs->tf_ss = _udatasel;
482 PROC_LOCK(p);
483 mtx_lock(&psp->ps_mtx);

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

527 mtx_unlock(&psp->ps_mtx);
528 PROC_UNLOCK(p);
529
530 /* Build the argument list for the signal handler. */
531 sig = bsd_to_linux_signal(sig);
532
533 bzero(&frame, sizeof(frame));
534
476 regs->tf_eflags &= ~(PSL_T | PSL_VM | PSL_D);
477 regs->tf_cs = _ucodesel;
478 regs->tf_ds = _udatasel;
479 regs->tf_es = _udatasel;
480 regs->tf_fs = _udatasel;
481 regs->tf_ss = _udatasel;
482 PROC_LOCK(p);
483 mtx_lock(&psp->ps_mtx);

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

527 mtx_unlock(&psp->ps_mtx);
528 PROC_UNLOCK(p);
529
530 /* Build the argument list for the signal handler. */
531 sig = bsd_to_linux_signal(sig);
532
533 bzero(&frame, sizeof(frame));
534
535 frame.sf_handler = catcher;
536 frame.sf_sig = sig;
537
538 bsd_to_linux_sigset(mask, &lmask);
539
540 /* Build the signal context to be used by sigreturn. */
541 frame.sf_sc.sc_mask = lmask.__mask;
542 frame.sf_sc.sc_gs = rgs();
543 frame.sf_sc.sc_fs = regs->tf_fs;

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

569 */
570 PROC_LOCK(p);
571 sigexit(td, SIGILL);
572 }
573
574 /* Build context to run handler in. */
575 regs->tf_esp = (int)fp;
576 regs->tf_eip = __kernel_sigreturn;
535 frame.sf_sig = sig;
536
537 bsd_to_linux_sigset(mask, &lmask);
538
539 /* Build the signal context to be used by sigreturn. */
540 frame.sf_sc.sc_mask = lmask.__mask;
541 frame.sf_sc.sc_gs = rgs();
542 frame.sf_sc.sc_fs = regs->tf_fs;

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

568 */
569 PROC_LOCK(p);
570 sigexit(td, SIGILL);
571 }
572
573 /* Build context to run handler in. */
574 regs->tf_esp = (int)fp;
575 regs->tf_eip = __kernel_sigreturn;
576 regs->tf_edi = catcher;
577 regs->tf_eflags &= ~(PSL_T | PSL_VM | PSL_D);
578 regs->tf_cs = _ucodesel;
579 regs->tf_ds = _udatasel;
580 regs->tf_es = _udatasel;
581 regs->tf_fs = _udatasel;
582 regs->tf_ss = _udatasel;
583 PROC_LOCK(p);
584 mtx_lock(&psp->ps_mtx);

--- 596 unchanged lines hidden ---
577 regs->tf_eflags &= ~(PSL_T | PSL_VM | PSL_D);
578 regs->tf_cs = _ucodesel;
579 regs->tf_ds = _udatasel;
580 regs->tf_es = _udatasel;
581 regs->tf_fs = _udatasel;
582 regs->tf_ss = _udatasel;
583 PROC_LOCK(p);
584 mtx_lock(&psp->ps_mtx);

--- 596 unchanged lines hidden ---