MINOR: poller: centralize poll return handling

When returning from the polling syscall, all pollers have a certain
dance to follow, made of wall clock updates, thread harmless updates,
idle time management and sleeping mask updates. Let's have a centralized
function to deal with all of this boring stuff: fd_leaving_poll(), and
make all the pollers use it.
This commit is contained in:
Willy Tarreau
2022-06-22 15:21:34 +02:00
parent bdcd32598f
commit 058b2c1015
7 changed files with 21 additions and 34 deletions

View File

@@ -79,6 +79,7 @@ ssize_t fd_write_frag_line(int fd, size_t maxlen, const struct ist pfx[], size_t
void my_closefrom(int start);
int compute_poll_timeout(int next);
void fd_leaving_poll(int wait_time, int status);
/* disable the specified poller */
void disable_poller(const char *poller_name);