diff options
author | Nicholas Noll <nbnoll@eml.cc> | 2021-11-18 17:49:04 -0800 |
---|---|---|
committer | Nicholas Noll <nbnoll@eml.cc> | 2021-11-18 17:49:04 -0800 |
commit | 835dea0eb6333a9ef452881ea073bfe59d14096a (patch) | |
tree | 525c3b4fe8b281813d7234fcc8871c63c627cc19 /sys/src/ioctl.c | |
parent | 5bcc08d92ae9345d6863f555a3dd9ec960e0860f (diff) |
feat: continued filling out system layer
Diffstat (limited to 'sys/src/ioctl.c')
-rw-r--r-- | sys/src/ioctl.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/sys/src/ioctl.c b/sys/src/ioctl.c new file mode 100644 index 0000000..30c7318 --- /dev/null +++ b/sys/src/ioctl.c @@ -0,0 +1,17 @@ +#include "internal.h" +#include <asm/ioctl.h> + +int +sys·ioctl(int fd, int request, ...) +{ + long ret; + void *arg; + va_list ap; + + va_start(ap, request); + arg = va_arg(ap, void*); + va_end(ap); + + ret = syscall(·IoCtl, fd, request, arg); + return error(ret); +} |