Re: [PATCH] Use ERESTARTNOHAND if poll() is interrupted by a signal

From: Chris Wright
Date: Tue Jul 31 2007 - 13:36:51 EST


* Oleg Nesterov (oleg@xxxxxxxxxx) wrote:
> > I am not sure. This means we restart sys_poll() with the same timeout
> > if there is no pending signal. I think we need ERESTART_RESTARTBLOCK
> > logic.
>
> Forgot to mention, sys_select() can use ERESTARTNOHAND because it
> modifies "struct timeval __user *tvp" before return, but sys_poll()
> gets timeout_msecs by value.

Yeah, you're right. Means sys_poll with STOP/CONT cycles going in
background (and no fds ready) would never return.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/