Manpages

NOM

restart_syscall - redémarre un appel système après qu’il a été interrompu par un signal d’arrêt.

SYNOPSIS

int restart_syscall(void);

Note : il n’existe pas d’enveloppe pour cet appel système dans la glibc ; voir NOTES.

DESCRIPTION

L’appel système restart_syscall() est utilisé pour redémarrer certains appels système lorsqu’un processus qui a été arrêté par un signal (par exemple SIGSTOP ou SIGTSTP) est ensuite relancé par un signal SIGCONT. Cet appel système est exclusivement destiné à un usage interne par le noyau.

restart_syscall() is used for restarting only those system calls that, when restarted, should adjust their time-related parameters—namely poll(2) (since Linux 2.6.24), nanosleep(2) (since Linux 2.6), clock_nanosleep(2) (since Linux 2.6), and futex(2), when employed with the FUTEX_WAIT (since Linux 2.6.22) and FUTEX_WAIT_BITSET (since Linux 2.6.31) operations. restart_syscall() restarts the interrupted system call with a time argument that is suitably adjusted to account for the time that has already elapsed (including the time where the process was stopped by a signal). Without the restart_syscall() mechanism, restarting these system calls would not correctly deduct the already elapsed time when the process continued execution.

VALEUR RENVOYÉE

La valeur renvoyée par restart_syscall() est celle renvoyée par l’appel système qui est redémarré.

ERREURS

errno est défini selon l’erreur avec la même valeur que celle définie par l’appel système qui est redémarré par restart_syscall().

VERSIONS

L’appel système restart_syscall() existe depuis Linux 2.6.

CONFORMITÉ

Cet appel système est spécifique à Linux.

NOTES

Il n’y a pas d’enrobage glibc pour cet appel système puisqu’il ne doit être appelé que par le noyau et jamais par une application.

The kernel uses restart_syscall() to ensure that when a system call is restarted after a process has been stopped by a signal and then resumed by SIGCONT, then the time that the process spent in the stopped state is counted against the timeout interval specified in the original system call. In the case of system calls that take a timeout argument and automatically restart after a stop signal plus SIGCONT, but which do not have the restart_syscall() mechanism built in, then, after the process resumes execution, the time that the process spent in the stop state is not counted against the timeout value. Notable examples of system calls that suffer this problem are ppoll(2), select(2), and pselect(2).

From user space, the operation of restart_syscall() is largely invisible: to the process that made the system call that is restarted, it appears as though that system call executed and returned in the usual fashion.

VOIR AUSSI

sigaction(2), sigreturn(2), signal(7)

COLOPHON

Cette page fait partie de la publication 5.07 du projet man-pages Linux. Une description du projet et des instructions pour signaler des anomalies et la dernière version de cette page, peuvent être trouvées à l’adresse https://www.kernel.org/doc/man-pages/.

TRADUCTION

La traduction française de cette page de manuel a été créée par Christophe Blaess <https://www.blaess.fr/christophe/>;, Stéphan Rafin <stephan.rafin [AT] laposte.net>, Thierry Vignaud <tvignaud [AT] mandriva.com>, François Micaux, Alain Portal <aportal [AT] univ-montp2.fr>, Jean-Philippe Guérard <fevrier [AT] tigreraye.org>, Jean-Luc Coulon (f5ibh) <jean-luc.coulon [AT] wanadoo.fr>, Julien Cristau <jcristau [AT] debian.org>, Thomas Huriaux <thomas.huriaux [AT] gmail.com>, Nicolas François <nicolas.francois [AT] centraliens.net>, Florentin Duneau <fduneau [AT] gmail.com>, Simon Paillard <simon.paillard [AT] resel.fr>, Denis Barbier <barbier [AT] debian.org>, David Prévot <david [AT] tilapin.org>, Cédric Boutillier <cedric.boutillier [AT] gmail.com> et Frédéric Hantrais <fhantrais [AT] gmail.com>

Cette traduction est une documentation libre ; veuillez vous reporter à la GNU General Public License version 3 concernant les conditions de copie et de distribution. Il n’y a aucune RESPONSABILITÉ LÉGALE.

Si vous découvrez un bogue dans la traduction de cette page de manuel, veuillez envoyer un message à <debian-l10n-french [AT] lists.org>.