[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: rpctrace / libpager / signal preemptor
From: |
Samuel Thibault |
Subject: |
Re: rpctrace / libpager / signal preemptor |
Date: |
Mon, 14 Nov 2016 01:07:40 +0100 |
User-agent: |
Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30) |
Hello,
Brent W. Baccala, on Tue 08 Nov 2016 20:43:29 -1000, wrote:
> _pager_lock_object (p, offset, length, MEMORY_OBJECT_RETURN_NONE, 1,
> - VM_PROT_WRITE, 1);
> + VM_PROT_WRITE, 0);
Applied, thanks!
> Once that's been resolved, then we're back to the problem with signal
> preemptors! libpager/pager-memcpy.c includes the following code:
>
> void fault (int signo, long int sigcode, struct sigcontext *scp)
> {
> assert (scp->sc_error == EKERN_MEMORY_ERROR);
> err = pager_get_error (pager, sigcode - window + offset);
> n -= sigcode - window;
> vm_deallocate (mach_task_self (), window, window_size);
> longjmp (buf, 1);
> }
>
> Since sigcode no longer contains the faulting address (it's in the subcode,
> remember?)
Mmm, no. For legacy signal handlers (i.e. without SA_SIGINFO), the
parameters should still be the sigcode: it's
_hurd_exception2signal_legacy which should be getting called from
sysdeps/mach/hurd/i386/trampoline.c.
Note that there is a
/* XXX what if handler != action->handler (for instance, if a signal
* preemptor took over) ? */
above. I'd say that when handler != action->handler we should assume
it's a legacy handler, and make 'action' point to a default-legacy
sigaction structure, so that it doesn't have SA_SIGINFO, and thus the
legacy parameters will be passeD.
Samuel
- rpctrace / libpager / signal preemptor, Brent W. Baccala, 2016/11/09
- Re: rpctrace / libpager / signal preemptor,
Samuel Thibault <=
- Re: rpctrace / libpager / signal preemptor, Samuel Thibault, 2016/11/16
- Re: rpctrace / libpager / signal preemptor, Samuel Thibault, 2016/11/16
- Re: rpctrace / libpager / signal preemptor, Samuel Thibault, 2016/11/16
- Re: rpctrace / libpager / signal preemptor, Samuel Thibault, 2016/11/20
- Re: rpctrace / libpager / signal preemptor, Samuel Thibault, 2016/11/20
- Re: rpctrace / libpager / signal preemptor, Brent W. Baccala, 2016/11/21
- Re: rpctrace / libpager / signal preemptor, Svante Signell, 2016/11/21
- Re: rpctrace / libpager / signal preemptor, Samuel Thibault, 2016/11/21
- Re: rpctrace / libpager / signal preemptor, Samuel Thibault, 2016/11/21