summaryrefslogtreecommitdiff
path: root/libc/sysdeps/linux/common/ioctl.c
blob: d3cc617acae5e511d2f29db9d7d93eed753ac68e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include <stdarg.h>
#include <sys/ioctl.h>

extern int __syscall_ioctl(int fd, int request, void *arg);

/* powerpc has its own special version... */
int ioctl(int fd, unsigned long int request, ...)
{
    void *arg;
    va_list list;

    va_start(list, request);
    arg = va_arg(list, void *);

    va_end(list);
    return __syscall_ioctl(fd, request, arg);
}