Re: PROBLEM: rt_sigsuspend() does not return EINTR on 2.6.16-rc2+

David Woodhouse
2006-03-06T11:30:21Z

On Mon, 2006-03-06 at 22:25 +1100, Paul Mackerras wrote:
> I have been looking at the equivalent code on powerpc. This looks to
> me like we aren't calling do_signal on the way back out of the system
> call to userspace on x86 when the _TIF_RESTORE_SIGMASK thread_info
> flag is set. I had a look at the code in arch/i386/kernel and I can't
> see why we wouldn't be getting to do_signal, but x86 assembly is not
> my strong point.

You can't see it because it's not in assembly -- it's in
do_notify_resume() in signal.c :)

> The fact that userspace is seeing the -ERESTARTNOHAND return value
> from the rt_sigsuspend strongly suggests that we aren't actually
> calling do_signal, though.

That's just because we do the ptrace stop _before_ do_signal now, just
as we already did for all other restartable syscalls. The signal really
is happening -- you can see the sigreturn().

--
dwmw2