1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 20:27:34 +00:00

LibC+Kernel: Implement ppoll

ppoll() is similar() to poll(), but it takes its timeout
as timespec instead of as int, and it takes an additional
sigmask parameter.

Change the sys$poll parameters to match ppoll() and implement
poll() in terms of ppoll().
This commit is contained in:
Nico Weber 2020-06-22 11:41:51 -04:00 committed by Andreas Kling
parent 4b19b99b36
commit d2684a8645
5 changed files with 55 additions and 19 deletions

View file

@ -35,6 +35,7 @@
constexpr int syscall_vector = 0x82;
extern "C" {
struct pollfd;
struct timeval;
struct timespec;
struct sockaddr;
@ -273,6 +274,13 @@ struct SC_select_params {
const u32* sigmask;
};
struct SC_poll_params {
struct pollfd* fds;
unsigned nfds;
const struct timespec* timeout;
const u32* sigmask;
};
struct SC_clock_nanosleep_params {
int clock_id;
int flags;